Pylon::IImage#
Usable to access image properties and image buffer.
#include <pylon/Image.h>
Inherited by Pylon::CGrabResultImageT< GrabResultT >, Pylon::IReusableImage
Public Functions#
Name | |
---|---|
virtual | ~IImage() =0 Ensure proper destruction by using a virtual destructor. |
virtual bool | IsValid() const =0 Can be used to check whether an image is valid. |
virtual EPixelType | GetPixelType() const =0 Get the current pixel type. |
virtual uint32_t | GetWidth() const =0 Get the current number of columns in pixels. |
virtual uint32_t | GetHeight() const =0 Get the current number of rows. |
virtual size_t | GetPaddingX() const =0 Get the number of extra data bytes at the end of each row. |
virtual EImageOrientation | GetOrientation() const =0 Get the vertical orientation of the image in memory. |
virtual void * | GetBuffer() =0 Get the pointer to the buffer. |
virtual const void * | GetBuffer() const =0 Get the pointer to the buffer containing the image. |
virtual size_t | GetImageSize() const =0 Get the size of the image in bytes. |
virtual bool | IsUnique() const =0 Indicates that the referenced buffer is only referenced by this image. |
virtual bool | GetStride(size_t & strideBytes) const =0 Get the stride in bytes. |
Public Functions Documentation#
function ~IImage#
Ensure proper destruction by using a virtual destructor.
function IsValid#
Can be used to check whether an image is valid.
Return: Returns false if the image is invalid.
Error Safety:
Does not throw C++ exceptions.
Reimplemented by: Pylon::CGrabResultImageT::IsValid, Pylon::CPylonBitmapImage::IsValid, Pylon::CPylonImage::IsValid
function GetPixelType#
Get the current pixel type.
Return: Returns the pixel type or PixelType_Undefined if the image is invalid.
Error Safety:
Does not throw C++ exceptions.
Reimplemented by: Pylon::CGrabResultImageT::GetPixelType, Pylon::CPylonBitmapImage::GetPixelType, Pylon::CPylonImage::GetPixelType
function GetWidth#
Get the current number of columns in pixels.
Return: Returns the current number of columns in pixels or 0 if the image is invalid.
Error Safety:
Does not throw C++ exceptions.
Reimplemented by: Pylon::CGrabResultImageT::GetWidth, Pylon::CPylonBitmapImage::GetWidth, Pylon::CPylonImage::GetWidth
function GetHeight#
Get the current number of rows.
Return: Returns the current number of rows or 0 if the image is invalid.
Error Safety:
Does not throw C++ exceptions.
Reimplemented by: Pylon::CGrabResultImageT::GetHeight, Pylon::CPylonBitmapImage::GetHeight, Pylon::CPylonImage::GetHeight
function GetPaddingX#
Get the number of extra data bytes at the end of each row.
Return: Returns the number of extra data bytes at the end of each row or 0 if the image is invalid.
Error Safety:
Does not throw C++ exceptions.
Reimplemented by: Pylon::CGrabResultImageT::GetPaddingX, Pylon::CPylonBitmapImage::GetPaddingX, Pylon::CPylonImage::GetPaddingX
function GetOrientation#
Get the vertical orientation of the image in memory.
Return: Returns the orientation of the image or ImageOrientation_TopDown if the image is invalid.
Error Safety:
Does not throw C++ exceptions.
Reimplemented by: Pylon::CGrabResultImageT::GetOrientation, Pylon::CPylonBitmapImage::GetOrientation, Pylon::CPylonImage::GetOrientation
function GetBuffer#
Get the pointer to the buffer.
Return: Returns the pointer to the used buffer or NULL if the image is invalid.
Error Safety:
Does not throw C++ exceptions.
Reimplemented by: Pylon::CGrabResultImageT::GetBuffer, Pylon::CPylonBitmapImage::GetBuffer, Pylon::CPylonImage::GetBuffer
function GetBuffer#
Get the pointer to the buffer containing the image.
Return: Returns the pointer to the used buffer or NULL if the image is invalid.
Error Safety:
Does not throw C++ exceptions.
Reimplemented by: Pylon::CGrabResultImageT::GetBuffer, Pylon::CPylonBitmapImage::GetBuffer, Pylon::CPylonImage::GetBuffer
The buffer is at least as large as the value returned by GetImageSize().
function GetImageSize#
Get the size of the image in bytes.
Return: Returns the size of the image in bytes or 0 if the image is invalid.
Error Safety:
Does not throw C++ exceptions.
Reimplemented by: Pylon::CGrabResultImageT::GetImageSize, Pylon::CPylonBitmapImage::GetImageSize, Pylon::CPylonImage::GetImageSize
function IsUnique#
Indicates that the referenced buffer is only referenced by this image.
Return: Returns true if the referenced buffer is only referenced by this image. Returns false if the image is invalid.
Error Safety:
Does not throw C++ exceptions.
Reimplemented by: Pylon::CGrabResultImageT::IsUnique, Pylon::CPylonBitmapImage::IsUnique, Pylon::CPylonImage::IsUnique
function GetStride#
Get the stride in bytes.
Parameters:
- strideBytes The stride in byte if it can be computed.
Return: Returns true if the stride can be computed.
Error Safety:
Does not throw C++ exceptions.
Reimplemented by: Pylon::CGrabResultImageT::GetStride, Pylon::CPylonBitmapImage::GetStride, Pylon::CPylonImage::GetStride
The stride in bytes can not be computed for packed image format when the stride is not byte aligned. See also Pylon::IsPacked(). The stride in bytes can not be computed if the image is invalid.