home *** CD-ROM | disk | FTP | other *** search
/ HPAVC / HPAVC CD-ROM.iso / pc / MCASM.RAR / MC_ASM.EXE / WROX_ASM / CH12 / COMMON / FORMCONV.H < prev    next >
Encoding:
C/C++ Source or Header  |  1994-09-24  |  2.1 KB  |  59 lines

  1. #ifndef FORMCONV_H
  2. #define FORMCONV_H
  3. #include "common.h"
  4. #include "grfile.h"
  5.  
  6. /*
  7. * The headers of various routines that convert image forms
  8. * from one to another
  9. * All of them work with a single line of image.
  10. *
  11. *  And one important note!!!
  12. *  YOU MUST reserve one extra byte in destination line,
  13. *  (please, forgive me) some procedures tends to write to this byte
  14. *
  15. * Written by E. Podvoysky  & Kiselev J. CZ 1994.
  16. */
  17.  
  18. /*  see image form descriptions in grfile.h */
  19.  
  20. void invert_order(BYTE *source,BYTE *dest,int width);
  21.  
  22. void mono2row(BYTE *source,BYTE *dest,BYTE whitecolor,int width);
  23. void monoGIF2mono(BYTE *source,BYTE *dest,int width);
  24. void mono2GIFmono(BYTE *source,BYTE *dest,int width);
  25. void mono2mono(BYTE *source,BYTE *dest,int width);
  26. void mono2RGB24(BYTE *source,BYTE *dest,int width);
  27. void gray2byte(BYTE *source,BYTE *dest,int width);
  28. void col2562byte(BYTE *source,BYTE *dest,int width);
  29.  
  30. void col16A2col16B(BYTE *source,BYTE *dest,int width);
  31.     // beware - writes one excessive byte to dest if width is odd
  32. void col16B2col16A(BYTE *source,BYTE *dest,int width);
  33.  
  34. void col16plane2col16B(BYTE *source,BYTE *dest,int width);
  35. void col16B2col16plane(BYTE *source,BYTE *dest,int width);
  36. void palette2gray(BGRpalette source,BGRpalette dest);
  37.  
  38. void mono2RGBlines(BYTE *source, BYTE *dest,int width);
  39. void byte2RGBlines(BYTE *source, BYTE *dest,int width, BGRpalette pal);
  40. void paletted2gray(BYTE *source, BYTE *dest,int width, BGRpalette graypal);
  41.  
  42.  
  43. void BGR2RGBlines(BYTE *source, BYTE *dest, int width);
  44. void RGB15_2RGBlines(BYTE *source, BYTE *dest, int width);
  45. void RGB16_2RGBlines(BYTE *source, BYTE *dest, int width);
  46. void BGRA32_2RGBlines(BYTE *source, BYTE *dest, int width);
  47. void RGBplanes2RGBlines(BYTE *source, BYTE *dest, int width);
  48.  
  49. void RGBlines2BGR(BYTE *source, BYTE *dest, int width);
  50. void RGBlines2RGB15(BYTE *source, BYTE *dest, int width);
  51. void RGBlines2BGRA32(BYTE *source, BYTE *dest, int width);
  52. void RGBlines2gray(BYTE *source, BYTE *dest, int width);
  53.  
  54. typedef void (*getRGBlines)(BYTE *source, BYTE *dest, int width);
  55. getRGBlines getRGBproc(image_type source_type, image_extention_type source_ext);
  56.  
  57.  
  58. #endif
  59.