contrib/brl/bbas/vidl2/vidl2_color.h File Reference


Detailed Description

Color space conversions and related functions.

Author:
Matt Leotta
Date:
23 Jan 2006

Definition in file vidl2_color.h.

#include "vidl2_pixel_format.h"
#include <vcl_cstring.h>

Go to the source code of this file.


Classes

struct  vidl2_color_converter< VIDL2_PIXEL_COLOR_RGB, VIDL2_PIXEL_COLOR_RGB >
struct  vidl2_color_converter< VIDL2_PIXEL_COLOR_RGBA, VIDL2_PIXEL_COLOR_RGBA >
struct  vidl2_color_converter< VIDL2_PIXEL_COLOR_RGBA, VIDL2_PIXEL_COLOR_RGB >
struct  vidl2_color_converter< VIDL2_PIXEL_COLOR_RGB, VIDL2_PIXEL_COLOR_RGBA >
struct  vidl2_color_converter< VIDL2_PIXEL_COLOR_YUV, VIDL2_PIXEL_COLOR_YUV >
struct  vidl2_color_converter< VIDL2_PIXEL_COLOR_MONO, VIDL2_PIXEL_COLOR_MONO >
struct  vidl2_color_converter< VIDL2_PIXEL_COLOR_RGB, VIDL2_PIXEL_COLOR_YUV >
struct  vidl2_color_converter< VIDL2_PIXEL_COLOR_RGBA, VIDL2_PIXEL_COLOR_YUV >
struct  vidl2_color_converter< VIDL2_PIXEL_COLOR_YUV, VIDL2_PIXEL_COLOR_RGB >
struct  vidl2_color_converter< VIDL2_PIXEL_COLOR_YUV, VIDL2_PIXEL_COLOR_RGBA >
struct  vidl2_color_converter< VIDL2_PIXEL_COLOR_YUV, VIDL2_PIXEL_COLOR_MONO >
struct  vidl2_color_converter< VIDL2_PIXEL_COLOR_MONO, VIDL2_PIXEL_COLOR_YUV >
struct  vidl2_color_converter< VIDL2_PIXEL_COLOR_RGB, VIDL2_PIXEL_COLOR_MONO >
struct  vidl2_color_converter< VIDL2_PIXEL_COLOR_RGBA, VIDL2_PIXEL_COLOR_MONO >
struct  vidl2_color_converter< VIDL2_PIXEL_COLOR_MONO, VIDL2_PIXEL_COLOR_RGB >
struct  vidl2_color_converter< VIDL2_PIXEL_COLOR_MONO, VIDL2_PIXEL_COLOR_RGBA >
struct  vidl2_color_component< FMT >
 Component color encoding. More...
struct  vidl2_color_component< VIDL2_PIXEL_FORMAT_BGR_24 >
struct  vidl2_color_component< VIDL2_PIXEL_FORMAT_RGB_555 >
struct  vidl2_color_component< VIDL2_PIXEL_FORMAT_RGB_565 >
struct  vidl2_color_component< VIDL2_PIXEL_FORMAT_UYV_444 >

Typedefs

typedef void(*) vidl2_color_conv_fptr (const vxl_byte *in, vxl_byte *out)
 Define the function pointer for pixel format conversion functions.

Functions

template<class outT>
void vidl2_color_convert_yuv2rgb (vxl_byte y, vxl_byte u, vxl_byte v, outT &r, outT &g, outT &b)
VCL_DEFINE_SPECIALIZATION void vidl2_color_convert_yuv2rgb (vxl_byte y, vxl_byte u, vxl_byte v, vxl_byte &r, vxl_byte &g, vxl_byte &b)
 faster integer-based conversion from YUV to RGB.
template<class outT>
void vidl2_color_convert_rgb2yuv (vxl_byte r, vxl_byte g, vxl_byte b, outT &y, outT &u, outT &v)
VCL_DEFINE_SPECIALIZATION void vidl2_color_convert_rgb2yuv (vxl_byte r, vxl_byte g, vxl_byte b, vxl_byte &y, vxl_byte &u, vxl_byte &v)
 faster integer-based conversion from RGB to YUV.
vidl2_color_conv_fptr vidl2_color_converter_func (vidl2_pixel_color in_C, unsigned in_bpp, vidl2_pixel_color out_C, unsigned out_bpp)
 Returns a color conversion function based on runtime values.

Typedef Documentation

typedef void(*) vidl2_color_conv_fptr(const vxl_byte *in, vxl_byte *out)

Define the function pointer for pixel format conversion functions.

Definition at line 93 of file vidl2_color.h.


Function Documentation

VCL_DEFINE_SPECIALIZATION void vidl2_color_convert_rgb2yuv ( vxl_byte  r,
vxl_byte  g,
vxl_byte  b,
vxl_byte &  y,
vxl_byte &  u,
vxl_byte &  v 
) [inline]

faster integer-based conversion from RGB to YUV.

Based on conversion used in libdc1394

Definition at line 73 of file vidl2_color.h.

template<class outT>
void vidl2_color_convert_rgb2yuv ( vxl_byte  r,
vxl_byte  g,
vxl_byte  b,
outT &  y,
outT &  u,
outT &  v 
) [inline]

Definition at line 58 of file vidl2_color.h.

VCL_DEFINE_SPECIALIZATION void vidl2_color_convert_yuv2rgb ( vxl_byte  y,
vxl_byte  u,
vxl_byte  v,
vxl_byte &  r,
vxl_byte &  g,
vxl_byte &  b 
) [inline]

faster integer-based conversion from YUV to RGB.

Based on conversion used in libdc1394

Definition at line 40 of file vidl2_color.h.

template<class outT>
void vidl2_color_convert_yuv2rgb ( vxl_byte  y,
vxl_byte  u,
vxl_byte  v,
outT &  r,
outT &  g,
outT &  b 
) [inline]

Definition at line 25 of file vidl2_color.h.

vidl2_color_conv_fptr vidl2_color_converter_func ( vidl2_pixel_color  in_C,
unsigned  in_bpp,
vidl2_pixel_color  out_C,
unsigned  out_bpp 
)

Returns a color conversion function based on runtime values.

The function returned is always a vidl2_color_conv_fptr which converts const vxl_byte* to vxl_byte*. Some of these function may actually reinterpret the data as other types (i.e. bool* or vxl_uint_16*) via reinterpret_cast

Definition at line 32 of file vidl2_color.cxx.


Generated on Wed Dec 3 05:21:03 2008 for contrib/brl/bbas/vidl2 by  doxygen 1.5.1