set_grayval ( Image : : Row, Column, Grayval : )

Set single gray values in an image.

set_grayval sets the gray values of the input image Image at the positions (Row,Column) to the values specified by Grayval. The number of values in Grayval must match the number of points passed to the operator.


Attention

The operator set_grayval produces quite some overhead. Typically, it is used to set single gray values of an image. It is not suitable for programming image processing operations such as filters. In this case it is more useful to use the procedure get_image_pointer1 and to directly use the C or C++ interface for integrating own procedures.


Parameters

Image (input_object)
image -> object : byte / direction / cyclic / int1 / int2 / uint2 / int4 / real
Image to be modified.

Row (input_control)
point.y(-array) -> integer
Row coordinates of the pixels to be modified.
Default value: 0
Suggested values: 0, 10, 50, 127, 255, 511
Typical range of values: 0 <= Row
Restriction: (0 <= Row) && (Row < height(Image))

Column (input_control)
point.x(-array) -> integer
Column coordinates of the pixels to be modified.
Default value: 0
Suggested values: 0, 10, 50, 127, 255, 511
Typical range of values: 0 <= Column
Restriction: (0 <= Column) && (Column < width(Image))

Grayval (input_control)
grayval(-array) -> real / integer
Gray values to be used.
Default value: 255.0
Suggested values: 0.0, 1.0, 10.0, 128.0, 255.0


Result

set_grayval returns 2 (H_MSG_TRUE) if all parameters are correct. If the input is empty the behavior can be set via set_system(::'no_object_result',<Result>:). If necessary, an exception is raised.


Parallelization Information

set_grayval is reentrant and processed without parallelization.


Possible Predecessors

read_image, get_image_pointer1, gen_image_proto, gen_image1


Alternatives

get_image_pointer1, paint_gray, paint_region


See also

get_grayval, gen_image_const, gen_image1, gen_image_proto


Module

Foundation



Copyright © 1996-2008 MVTec Software GmbH