IM: Logical Arithmetic Operations

IM - An Imaging Tool

Logical Arithmetic Operations
[Image Processing]


Detailed Description

Logical binary math operations for images.
See im_process_pon.h


Enumerations

enum  imLogicOp { IM_BIT_AND, IM_BIT_OR, IM_BIT_XOR }

Functions

void imProcessBitwiseOp (const imImage *src_image1, const imImage *src_image2, imImage *dst_image, int op)
void imProcessBitwiseNot (const imImage *src_image, imImage *dst_image)
void imProcessBitMask (const imImage *src_image, imImage *dst_image, unsigned char mask, int op)
void imProcessBitPlane (const imImage *src_image, imImage *dst_image, int plane, int reset)

Enumeration Type Documentation

enum imLogicOp
 

Logical Operations.

Enumerator:
IM_BIT_AND  and = a & b
IM_BIT_OR  or = a | b
IM_BIT_XOR  xor = ~(a | b)
00228                {
00229   IM_BIT_AND,   /**< and  =   a & b   */
00230   IM_BIT_OR,    /**< or   =   a | b   */
00231   IM_BIT_XOR    /**< xor  = ~(a | b)  */
00232 };


Function Documentation

void imProcessBitwiseOp const imImage src_image1,
const imImage src_image2,
imImage dst_image,
int  op
 

Apply a logical operation.
Images must have data type IM_BYTE, IM_USHORT or IM_INT. Can be done in place.

void imProcessBitwiseNot const imImage src_image,
imImage dst_image
 

Apply a logical NOT operation.
Images must have data type IM_BYTE, IM_USHORT or IM_INT. Can be done in place.

void imProcessBitMask const imImage src_image,
imImage dst_image,
unsigned char  mask,
int  op
 

Apply a bit mask.
The same as imProcessBitwiseOp but the second image is replaced by a fixed mask.
Images must have data type IM_BYTE. It is valid only for AND, OR and XOR. Can be done in place.

void imProcessBitPlane const imImage src_image,
imImage dst_image,
int  plane,
int  reset
 

Extract or Reset a bit plane. For ex: 000X0000 or XXX0XXXX (plane=3).
Images must have data type IM_BYTE. Can be done in place.