QMedical Command Reference
![]() |
![]() ![]() |
QMed_GetImageInfo(imageRef; imageWidth; imageHeight; imageDepth; pixelType):error | |||
![]() |
imageRef | Longint | Reference to the image |
![]() |
imageWidth | Longint | Image width |
![]() |
imageHeight | Longint | Image height |
![]() |
imageDepth | Longint | Image depth |
![]() |
pixelType | String4 | Pixel type |
![]() |
error | Longint | Error result |
Returns information about the current frame of an image. If the specified image contains multiple frames, the returned information pertains to the current frame.
The image is specified by imageRef. If imageRef is not a valid image, error qmed_paramErr is returned.
Parameters imageWidth and imageHeight receive the image width and height in pixels.
Parameter imageDepth receives the image depth. For images with RGB pixels, imageDepth can take the following values:
Black and white images 1
Color images 2, 8, 16, 24, 32
Grayscale images 34 (2 bit), 36 (4-bit), 40 (8-bit)
For images with special pixel types, imageDepth receives the bit-per-pixel of the image.
Parameter pixelType receives the pixel type of the image. This is an empty string for RGB images, or a 4-character code identifying a special pixel type. For example, 16-bit grayscale pixels are identified by "b16g".
Example
`Get image characteristics C_LONGINT($error) C_LONGINT($width;$height) C_LONGINT($depth) C_STRING(4;$pixelType) C_LONGINT(gImageRef) $error:=QMed_GetImageInfo (gImageRef;$width;$height;$depth;$pixelType) If ($error # qmed_noErr) `Handle the error End if |