get_image_pointer3get_image_pointer3GetImagePointer3GetImagePointer3get_image_pointer3get_image_pointer3
Short description
get_image_pointer3get_image_pointer3GetImagePointer3GetImagePointer3get_image_pointer3get_image_pointer3 โ Access the pointers of a colored image.
Signature
get_image_pointer3( image ImageRGB, out pointer PointerRed, out pointer PointerGreen, out pointer PointerBlue, out string Type, out extent.x Width, out extent.y Height )get_image_pointer3( ImageRGB : : : PointerRed, PointerGreen, PointerBlue, Type, Width, Height )void GetImagePointer3( const HObject& ImageRGB, HTuple* PointerRed, HTuple* PointerGreen, HTuple* PointerBlue, HTuple* Type, HTuple* Width, HTuple* Height )static void HOperatorSet.GetImagePointer3( HObject imageRGB, out HTuple pointerRed, out HTuple pointerGreen, out HTuple pointerBlue, out HTuple type, out HTuple width, out HTuple height )def get_image_pointer3( image_rgb: HObject ) -> Tuple[Sequence[int], Sequence[int], Sequence[int], Sequence[str], Sequence[int], Sequence[int]]
def get_image_pointer3_s( image_rgb: HObject ) -> Tuple[int, int, int, str, int, int]Herror get_image_pointer3( const Hobject ImageRGB, Hlong* PointerRed, Hlong* PointerGreen, Hlong* PointerBlue, char* Type, Hlong* Width, Hlong* Height )
Herror T_get_image_pointer3( const Hobject ImageRGB, Htuple* PointerRed, Htuple* PointerGreen, Htuple* PointerBlue, Htuple* Type, Htuple* Width, Htuple* Height )
void HImage::GetImagePointer3( HTuple* PointerRed, HTuple* PointerGreen, HTuple* PointerBlue, HTuple* Type, HTuple* Width, HTuple* Height ) const
void HImage::GetImagePointer3( void** PointerRed, void** PointerGreen, void** PointerBlue, HString* Type, Hlong* Width, Hlong* Height ) const
void HImage.GetImagePointer3( out HTuple pointerRed, out HTuple pointerGreen, out HTuple pointerBlue, out HTuple type, out HTuple width, out HTuple height )
void HImage.GetImagePointer3( out IntPtr pointerRed, out IntPtr pointerGreen, out IntPtr pointerBlue, out string type, out int width, out int height )
Description
The operator get_image_pointer3GetImagePointer3 returns a C pointer to
the three channels of a colored image (ImageRGBimageRGBimage_rgb).
Additionally the image type (Typetypetype = โbyteโ, โint2โ,โfloatโ etc.)
and the image size (Widthwidthwidth and Heightheightheight) are returned.
Consequently a direct access to the image data in the
HALCON database from the HALCON host language via the pointer is possible.
An image is stored in HALCON as a vector of image lines.
The image types โcomplexโ and โvector_typeโ are handled in a specific way.
In particular, โcomplexโ images are interleaved, i.e., the real and the
imaginary parts are alternating, whereas โvector_fieldโ images consist of
two matrices, one for the rows and one for the columns, which are stored in
the HALCON database one after the other.
The three channels must have the same pixel type and the same size.
Attention
Only one image can be passed.
The operator get_image_pointer3GetImagePointer3 should only be used for entry
into newly created images, since otherwise the gray values of other images
might be overwritten (see relational structure).
Execution information
-
Multithreading type: reentrant (runs in parallel with non-exclusive operators).
-
Multithreading scope: global (may be called from any thread).
-
Processed without parallelization.
Parameters
ImageRGBimageRGBimage_rgb (input_object) multichannel-image(-array) โ object (byte / direction / cyclic / int1 / int2 / uint2 / int4 / int8 / real / complex / vector_field)object (byte / direction / cyclic / int1 / int2 / uint2 / int4 / int8 / real / complex / vector_field)HObject (byte / direction / cyclic / int1 / int2 / uint2 / int4 / int8 / real / complex / vector_field)HImage (byte / direction / cyclic / int1 / int2 / uint2 / int4 / int8 / real / complex / vector_field)HObject (byte / direction / cyclic / int1 / int2 / uint2 / int4 / int8 / real / complex / vector_field)Hobject (byte / direction / cyclic / int1 / int2 / uint2 / int4 / int8 / real / complex / vector_field)
Input image.
PointerRedpointerRedpointer_red (output_control) pointer(-array) โ (integer)(integer)HTuple (Hlong)HTuple (IntPtr)Sequence[int]Htuple (Hlong)
Pointer to the pixels of the first channel.
PointerGreenpointerGreenpointer_green (output_control) pointer(-array) โ (integer)(integer)HTuple (Hlong)HTuple (IntPtr)Sequence[int]Htuple (Hlong)
Pointer to the pixels of the second channel.
PointerBluepointerBluepointer_blue (output_control) pointer(-array) โ (integer)(integer)HTuple (Hlong)HTuple (IntPtr)Sequence[int]Htuple (Hlong)
Pointer to the pixels of the third channel.
Typetypetype (output_control) string(-array) โ (string)(string)HTuple (HString)HTuple (string)Sequence[str]Htuple (char*)
Type of image.
List of values: 'byte', 'complex', 'cyclic', 'direction', 'int1', 'int2', 'int4', 'int8', 'real', 'uint2', 'vector_field_absolute', 'vector_field_relative'"byte", "complex", "cyclic", "direction", "int1", "int2", "int4", "int8", "real", "uint2", "vector_field_absolute", "vector_field_relative"
Widthwidthwidth (output_control) extent.x(-array) โ (integer)(integer)HTuple (Hlong)HTuple (int / long)Sequence[int]Htuple (Hlong)
Width of image.
Heightheightheight (output_control) extent.y(-array) โ (integer)(integer)HTuple (Hlong)HTuple (int / long)Sequence[int]Htuple (Hlong)
Height of image.
Result
The operator get_image_pointer3GetImagePointer3 returns the value 2 (H_MSG_TRUE) if
exactly one image is passed.
The behavior in case of empty input (no input images available) is set via
the operator set_system('no_object_result',<Result>).
If necessary an exception is raised.
Combinations with other operators
Combinations
Possible predecessors
read_imageReadImage
Alternatives
set_grayvalSetGrayval, get_grayvalGetGrayval, get_image_pointer1GetImagePointer1
See also
paint_regionPaintRegion, paint_grayPaintGray
Module
Foundation