Main Page | Modules | Class List | File List | Class Members | File Members

image_gla_uint8.h

Go to the documentation of this file.
00001 
00014 /* This library is free software; you can redistribute it and/or
00015    modify it under the terms of the GNU Lesser General Public
00016    License as published by the Free Software Foundation; either
00017    version 2.1 of the License, or (at your option) any later version.
00018 
00019    This library is distributed in the hope that it will be useful,
00020    but WITHOUT ANY WARRANTY; without even the implied warranty of
00021    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00022    Lesser General Public License for more details.
00023 
00024    You should have received a copy of the GNU Lesser General Public
00025    License along with this library; if not, write to the Free Software
00026    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00027 */
00028 
00029 #ifndef _GAN_IMAGE_GLA_UINT8_H
00030 #define _GAN_IMAGE_GLA_UINT8_H
00031 
00032 #include <gandalf/common/misc_defs.h>
00033 
00034 
00035 
00036 #define GAN_PIXEL Gan_GLAPixel_ui8
00037 #define GAN_PIXEL_FORMAT grey-level alpha
00038 #define GAN_PIXEL_TYPE 8-bit unsigned integer
00039 
00040 #define GAN_IMAGE_FORM_GEN gan_image_form_gen_gla_ui8
00041 #define GAN_IMAGE_SET_GEN gan_image_set_gen_gla_ui8
00042 #define GAN_IMAGE_ALLOC gan_image_alloc_gla_ui8
00043 #define GAN_IMAGE_ALLOC_DATA gan_image_alloc_data_gla_ui8
00044 #define GAN_IMAGE_FORM gan_image_form_gla_ui8
00045 #define GAN_IMAGE_FORM_DATA gan_image_form_data_gla_ui8
00046 #define GAN_IMAGE_SET gan_image_set_gla_ui8
00047 #define GAN_IMAGE_SET_PIX gan_image_set_pix_gla_ui8
00048 #define GAN_IMAGE_GET_PIX gan_image_get_pix_gla_ui8
00049 #define GAN_IMAGE_GET_PIXPTR gan_image_get_pixptr_gla_ui8
00050 #define GAN_IMAGE_GET_PIXARR gan_image_get_pixarr_gla_ui8
00051 #define GAN_IMAGE_FILL_CONST gan_image_fill_const_gla_ui8
00052 #define GAN_IMAGE_GET_ACTIVE_SUBWINDOW gan_image_get_active_subwindow_gla_ui8
00053 #define GAN_IMAGE_MASK_WINDOW gan_image_mask_window_gla_ui8
00054 #define GAN_IMAGE_CLEAR_WINDOW gan_image_clear_window_gla_ui8
00055 
00069 /* This library is free software; you can redistribute it and/or
00070    modify it under the terms of the GNU Lesser General Public
00071    License as published by the Free Software Foundation; either
00072    version 2.1 of the License, or (at your option) any later version.
00073 
00074    This library is distributed in the hope that it will be useful,
00075    but WITHOUT ANY WARRANTY; without even the implied warranty of
00076    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00077    Lesser General Public License for more details.
00078 
00079    You should have received a copy of the GNU Lesser General Public
00080    License along with this library; if not, write to the Free Software
00081    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00082 */
00083 
00084 #include <stdlib.h>
00085 #include <gandalf/common/misc_defs.h>
00086 #include <gandalf/image/image_defs.h>
00087 
00093 #ifdef __cplusplus
00094 extern "C" {
00095 #endif
00096 
00097 
00106  struct Gan_Image *gan_image_set_gen_gla_ui8 ( Gan_Image *img,
00107                                       unsigned long height,
00108                                       unsigned long width,
00109                                       unsigned long stride,
00110                                       Gan_Bool alloc_pix_data );
00111 
00124  struct Gan_Image *gan_image_form_gen_gla_ui8 ( Gan_Image *img,
00125                                        unsigned long height,
00126                                        unsigned long width,
00127                                        unsigned long stride,
00128                                        Gan_Bool alloc_pix_data,
00129                                        Gan_GLAPixel_ui8  *pix_data,
00130                                        size_t      pix_data_size,
00131                                        Gan_GLAPixel_ui8 **row_data,
00132                                        size_t      row_data_size );
00133 
00152  Gan_Bool gan_image_get_active_subwindow_gla_ui8 ( const Gan_Image *image,
00153                                           Gan_ImageWindow *subwin );
00158 #ifndef NDEBUG
00159 
00170  Gan_GLAPixel_ui8 *gan_image_get_pixptr_gla_ui8 ( const Gan_Image *img,
00171                                   unsigned row, unsigned col );
00172 
00179  Gan_GLAPixel_ui8 **gan_image_get_pixarr_gla_ui8 ( const Gan_Image *img );
00180 
00184 #endif /* #ifndef NDEBUG */
00185 
00195  Gan_Bool gan_image_mask_window_gla_ui8 ( Gan_Image *pImage,
00196                                  unsigned r0,     unsigned c0,
00197                                  unsigned height, unsigned width );
00198 
00203  Gan_Bool gan_image_clear_window_gla_ui8 ( Gan_Image *pImage,
00204                                   unsigned r0,     unsigned c0,
00205                                   unsigned height, unsigned width );
00210 #if defined(GAN_IMAGE_GET_MINIMUM_PIXEL)
00211 
00215  Gan_Bool GAN_IMAGE_GET_MINIMUM_PIXEL ( const Gan_Image *pImage,
00216                                        const Gan_Image *pMask,
00217                                        8-bit unsigned *minval );
00218  Gan_Bool GAN_IMAGE_GET_MAXIMUM_PIXEL ( const Gan_Image *pImage,
00219                                        const Gan_Image *pMask,
00220                                        8-bit unsigned *maxval );
00224 #endif /* defined(GAN_IMAGE_GET_MINIMUM_PIXEL) */
00225 
00226 /* declarations of macros defined in individual header files */
00227 
00228 
00244  Gan_Image *gan_image_alloc_gla_ui8 ( unsigned long height, unsigned long width );
00245 
00258  Gan_Image *gan_image_form_gla_ui8 ( Gan_Image *img,
00259                             unsigned long height, unsigned long width );
00260 
00277  Gan_Image *gan_image_alloc_data_gla_ui8 ( unsigned long height,
00278                                   unsigned long width,
00279                                   unsigned long stride,
00280                                   Gan_GLAPixel_ui8  *pix_data, size_t pix_data_size,
00281                                   Gan_GLAPixel_ui8 **row_data, size_t row_data_size );
00282 
00300  Gan_Image *gan_image_form_data_gla_ui8 ( Gan_Image *img,
00301                                  unsigned long height,
00302                                  unsigned long width,
00303                                  unsigned long stride,
00304                                  Gan_GLAPixel_ui8  *pix_data, size_t pix_data_size,
00305                                  Gan_GLAPixel_ui8 **row_data, size_t row_data_size );
00306 
00326  Gan_Image *gan_image_set_gla_ui8 ( Gan_Image *img,
00327                            unsigned long height, unsigned long width );
00328 
00345  Gan_Bool gan_image_set_pix_gla_ui8 ( Gan_Image *img, unsigned row, unsigned col,
00346                              Gan_GLAPixel_ui8 *pix );
00347 
00354  Gan_GLAPixel_ui8 gan_image_get_pix_gla_ui8 ( const Gan_Image *img, unsigned row, unsigned col );
00355 
00372  Gan_Bool gan_image_fill_const_gla_ui8 ( Gan_Image *img, Gan_GLAPixel_ui8 *pix );
00373 
00379 #ifdef __cplusplus
00380 }
00381 #endif
00382 
00383 #undef GAN_PIXEL
00384 #undef GAN_PIXEL_FORMAT
00385 #undef GAN_PIXEL_TYPE
00386 #undef GAN_IMTYPE
00387 #undef GAN_IMAGE_FORM_GEN
00388 #undef GAN_IMAGE_SET_GEN
00389 #undef GAN_IMAGE_ALLOC
00390 #undef GAN_IMAGE_ALLOC_DATA
00391 #undef GAN_IMAGE_FORM
00392 #undef GAN_IMAGE_FORM_DATA
00393 #undef GAN_IMAGE_SET
00394 #undef GAN_IMAGE_SET_PIX
00395 #undef GAN_IMAGE_GET_PIX
00396 #undef GAN_IMAGE_GET_PIXPTR
00397 #undef GAN_IMAGE_GET_PIXARR
00398 #undef GAN_IMAGE_FILL_CONST
00399 #undef GAN_IMAGE_GET_ACTIVE_SUBWINDOW
00400 #undef GAN_IMAGE_MASK_WINDOW
00401 #undef GAN_IMAGE_CLEAR_WINDOW
00402 #undef GAN_IMAGE_GET_MINIMUM_PIXEL
00403 #undef GAN_IMAGE_GET_MAXIMUM_PIXEL
00404 #undef GAN_IMAGE_PIXEL_MIN_VAL
00405 #undef GAN_IMAGE_PIXEL_MAX_VAL
00406 #undef GAN_IMAGE_PIXEL_ZERO_VAL
00407 
00414 #endif /* #ifndef _GAN_IMAGE_GLA_UINT8_H */

Generated on Fri Mar 17 12:44:47 2006 by  doxygen 1.3.9.1