Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ xil_color_convert(3) — SunOS 5.6

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

xil_colorspace_get_by_name(3)

xil_set_colorspace(3)

xil_black_generation(3)

xil_color_convert(3)

NAME

xil_color_convert − converts an image from one color space to another

SYNOPSIS

#include <xil/xil.h>

void xil_color_convert (XilImage src,

XilImage dst);

DESCRIPTION

This function converts the data in the source image from the source image’s color space to the destination image’s color space. The color space is an attribute of each image.  src is the source image’s handle.  dst is the destination image’s handle.  Neither the source nor the destination image can be a NULL image or have a NULL color space. This function does not support the XIL_FLOAT data type. 

ERRORS

For a complete list of XIL error messages by number, consult Appendix B of the XIL Programmer’s Guide. 

EXAMPLES

Converts the data in src from ycc601 colorspace to data in dst in rgblinear colorspace:

XilSystemState State;
XilColorspace cspace1, cspace2;
XilImage src, dst;
cspace1 = xil_colorspace_get_by_name(State, "ycc601");
xil_set_colorspace(src, cspace1);
cspace2 = xil_colorspace_get_by_name(State, "rgblinear");
xil_set_colorspace(dst, cspace2);
xil_color_convert(src, dst);

NOTES

The source and destination images must be the same data type.  The number of bands in an image must match its color space.  In-place operations can be done by creating a child image consisting of the whole image and then assigning a different color space to the child image. 

SEE ALSO

xil_colorspace_get_by_name(3), xil_set_colorspace(3), xil_black_generation(3). 
 

SunOS 5.6  —  Last change: 09 June 1993

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026