00001
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029 #ifndef _GAN_IMAGE_RGBAS_UINT10_H
00030 #define _GAN_IMAGE_RGBAS_UINT10_H
00031
00032 #define GAN_PIXEL struct Gan_RGBASPixel_ui10
00033 #define GAN_PIXEL_FORMAT RGBA colour
00034 #define GAN_PIXEL_TYPE gan_uint16
00035 #define GAN_IMTYPE ui10
00036 #define GAN_IMAGE_FORM_GEN gan_image_form_gen_rgbas_ui10
00037 #define GAN_IMAGE_SET_GEN gan_image_set_gen_rgbas_ui10
00038 #define GAN_IMAGE_ALLOC gan_image_alloc_rgbas_ui10
00039 #define GAN_IMAGE_ALLOC_DATA gan_image_alloc_data_rgbas_ui10
00040 #define GAN_IMAGE_FORM gan_image_form_rgbas_ui10
00041 #define GAN_IMAGE_FORM_DATA gan_image_form_data_rgbas_ui10
00042 #define GAN_IMAGE_SET gan_image_set_rgbas_ui10
00043 #define GAN_IMAGE_SET_PIX gan_image_set_pix_rgbas_ui10
00044 #define GAN_IMAGE_GET_PIX gan_image_get_pix_rgbas_ui10
00045 #define GAN_IMAGE_GET_PIXPTR gan_image_get_pixptr_rgbas_ui10
00046 #define GAN_IMAGE_GET_PIXARR gan_image_get_pixarr_rgbas_ui10
00047 #define GAN_IMAGE_FILL_CONST gan_image_fill_const_rgbas_ui10
00048 #define GAN_IMAGE_GET_ACTIVE_SUBWINDOW gan_image_get_active_subwindow_rgbas_ui10
00049 #define GAN_IMAGE_MASK_WINDOW gan_image_mask_window_rgbas_ui10
00050 #define GAN_IMAGE_CLEAR_WINDOW gan_image_clear_window_rgbas_ui10
00051 #define GAN_IMAGE_GET_MINIMUM_PIXEL gan_image_get_minimum_pixel_rgbas_ui10
00052 #define GAN_IMAGE_GET_MAXIMUM_PIXEL gan_image_get_maximum_pixel_rgbas_ui10
00053
00067
00068
00069
00070
00071
00072
00073
00074
00075
00076
00077
00078
00079
00080
00081
00082 #include <stdlib.h>
00083 #include <gandalf/common/misc_defs.h>
00084 #include <gandalf/image/image_defs.h>
00085
00091 #ifdef __cplusplus
00092 extern "C" {
00093 #endif
00094
00095
00104 struct Gan_Image *gan_image_set_gen_rgbas_ui10 ( Gan_Image *img,
00105 unsigned long height,
00106 unsigned long width,
00107 unsigned long stride,
00108 Gan_Bool alloc_pix_data );
00109
00122 struct Gan_Image *gan_image_form_gen_rgbas_ui10 ( Gan_Image *img,
00123 unsigned long height,
00124 unsigned long width,
00125 unsigned long stride,
00126 Gan_Bool alloc_pix_data,
00127 struct Gan_RGBASPixel_ui10 *pix_data,
00128 size_t pix_data_size,
00129 struct Gan_RGBASPixel_ui10 **row_data,
00130 size_t row_data_size );
00131
00150 Gan_Bool gan_image_get_active_subwindow_rgbas_ui10 ( const Gan_Image *image,
00151 Gan_ImageWindow *subwin );
00156 #ifndef NDEBUG
00157
00168 struct Gan_RGBASPixel_ui10 *gan_image_get_pixptr_rgbas_ui10 ( const Gan_Image *img,
00169 unsigned row, unsigned col );
00170
00177 struct Gan_RGBASPixel_ui10 **gan_image_get_pixarr_rgbas_ui10 ( const Gan_Image *img );
00178
00182 #endif
00183
00193 Gan_Bool gan_image_mask_window_rgbas_ui10 ( Gan_Image *pImage,
00194 unsigned r0, unsigned c0,
00195 unsigned height, unsigned width );
00196
00201 Gan_Bool gan_image_clear_window_rgbas_ui10 ( Gan_Image *pImage,
00202 unsigned r0, unsigned c0,
00203 unsigned height, unsigned width );
00208 #if defined(GAN_IMAGE_GET_MINIMUM_PIXEL)
00209
00213 Gan_Bool gan_image_get_minimum_pixel_rgbas_ui10 ( const Gan_Image *pImage,
00214 const Gan_Image *pMask,
00215 gan_uint16 *minval );
00216 Gan_Bool gan_image_get_maximum_pixel_rgbas_ui10 ( const Gan_Image *pImage,
00217 const Gan_Image *pMask,
00218 gan_uint16 *maxval );
00222 #endif
00223
00224
00225
00226
00242 Gan_Image *gan_image_alloc_rgbas_ui10 ( unsigned long height, unsigned long width );
00243
00256 Gan_Image *gan_image_form_rgbas_ui10 ( Gan_Image *img,
00257 unsigned long height, unsigned long width );
00258
00275 Gan_Image *gan_image_alloc_data_rgbas_ui10 ( unsigned long height,
00276 unsigned long width,
00277 unsigned long stride,
00278 struct Gan_RGBASPixel_ui10 *pix_data, size_t pix_data_size,
00279 struct Gan_RGBASPixel_ui10 **row_data, size_t row_data_size );
00280
00298 Gan_Image *gan_image_form_data_rgbas_ui10 ( Gan_Image *img,
00299 unsigned long height,
00300 unsigned long width,
00301 unsigned long stride,
00302 struct Gan_RGBASPixel_ui10 *pix_data, size_t pix_data_size,
00303 struct Gan_RGBASPixel_ui10 **row_data, size_t row_data_size );
00304
00324 Gan_Image *gan_image_set_rgbas_ui10 ( Gan_Image *img,
00325 unsigned long height, unsigned long width );
00326
00343 Gan_Bool gan_image_set_pix_rgbas_ui10 ( Gan_Image *img, unsigned row, unsigned col,
00344 struct Gan_RGBASPixel_ui10 *pix );
00345
00352 struct Gan_RGBASPixel_ui10 gan_image_get_pix_rgbas_ui10 ( const Gan_Image *img, unsigned row, unsigned col );
00353
00370 Gan_Bool gan_image_fill_const_rgbas_ui10 ( Gan_Image *img, struct Gan_RGBASPixel_ui10 *pix );
00371
00377 #ifdef __cplusplus
00378 }
00379 #endif
00380
00381 #undef GAN_PIXEL
00382 #undef GAN_PIXEL_FORMAT
00383 #undef GAN_PIXEL_TYPE
00384 #undef GAN_IMTYPE
00385 #undef GAN_IMAGE_FORM_GEN
00386 #undef GAN_IMAGE_SET_GEN
00387 #undef GAN_IMAGE_ALLOC
00388 #undef GAN_IMAGE_ALLOC_DATA
00389 #undef GAN_IMAGE_FORM
00390 #undef GAN_IMAGE_FORM_DATA
00391 #undef GAN_IMAGE_SET
00392 #undef GAN_IMAGE_SET_PIX
00393 #undef GAN_IMAGE_GET_PIX
00394 #undef GAN_IMAGE_GET_PIXPTR
00395 #undef GAN_IMAGE_GET_PIXARR
00396 #undef GAN_IMAGE_FILL_CONST
00397 #undef GAN_IMAGE_GET_ACTIVE_SUBWINDOW
00398 #undef GAN_IMAGE_MASK_WINDOW
00399 #undef GAN_IMAGE_CLEAR_WINDOW
00400 #undef GAN_IMAGE_GET_MINIMUM_PIXEL
00401 #undef GAN_IMAGE_GET_MAXIMUM_PIXEL
00402 #undef GAN_IMAGE_PIXEL_MIN_VAL
00403 #undef GAN_IMAGE_PIXEL_MAX_VAL
00404 #undef GAN_IMAGE_PIXEL_ZERO_VAL
00405
00411 #endif