Click or drag to resize

IMcRegionAccessPutPixel Method

Read a single pixel from an image.

Namespace:  MediaCy.IQL.Engine
Assembly:  MediaCy.IQL.Engine (in MediaCy.IQL.Engine.dll) Version: 10.0.6912.0
Syntax
VB
Function PutPixel ( 
	vPixel As Object,
	x As Integer,
	y As Integer
) As Integer

Parameters

vPixel
Type: SystemObject
VARIANT : A VARIANT containing the new pixel value. The type and number of values in vPixel depends on the type and number of channels of the McRegionAccess. These parameters are defined during the creation of the McRegionAccess via IMcImage.CreateRegionAccess. See GetPixel for more information.
x
Type: SystemInt32
long : The x-location of the pixel. 0 indicates a pixel along the edge of the McRegionAccess.
y
Type: SystemInt32
long : The y-location of the pixel. 0 indicates a pixel along the first line of the McRegionAccess.

Return Value

Type: Int32
long - the number of values returned in pvPixel: One value per channel in the McRegionAccess. The number channels in the McRegionAccess is determined by the channel argument of McImage.CreateRegionAccess as well as the McImageType.
Remarks
The x and y coordinates are relative to the McRegionAccess ROI, not the image. The pixel values returned are in the requested color model, which may differ from the image's native color model. If different, the pixel values will be converted back into the native color model and the image will be modified.
See Also