home *** CD-ROM | disk | FTP | other *** search
/ Geek 6 / Geek-006.iso / linux / video / xmovie-1.5.3.tar.gz / xmovie-1.5.3.tar / xmovie-1.5.3 / guicast / vframe.inc < prev   
Text File  |  2000-11-29  |  1KB  |  55 lines

  1. #ifndef VFRAME_INC
  2. #define VFRAME_INC
  3.  
  4.  
  5. // Size of a channel in the VPixel color model
  6.  
  7. //#define VWORD unsigned short int
  8. #define VWORD unsigned char
  9.  
  10. // maximum value of a channel in the VPixel color model
  11. //#define VMAX 65535
  12. #define VMAX 255
  13.  
  14.  
  15. // The maximum value is also used to determine the bit shifting to convert from
  16. // unsigned char to VWORD.
  17. // Get compiler warnings if bitshift is defined because >> can't take 0
  18. // as an argument.
  19. // 65535 forces bit shift of 8
  20. // 255 disables bit shift
  21.  
  22. // Color models used by VFrame
  23.  
  24. #define VFRAME_YUV420  7
  25. #define VFRAME_COMPRESSED 1  // Compressed data only
  26.  
  27. #define VFRAME_RGB565  3
  28. #define VFRAME_RGB8880 10
  29. #define VFRAME_RGB888  9
  30. #define VFRAME_BGR8880 6
  31. #define VFRAME_BGR888  5
  32. #define VFRAME_RGBA8888 10    // Format for widgets
  33. #define VFRAME_VPIXEL 10      // RGB VPixel
  34. #define VFRAME_VPIXELYUV 14   // YUV VPixel
  35.  
  36. class VFrame;
  37.  
  38. typedef struct 
  39. {
  40.     VWORD r;
  41.     VWORD g;
  42.     VWORD b;
  43.     VWORD a;
  44. } VPixel;
  45.  
  46. typedef struct
  47. {
  48.     VWORD y;
  49.     VWORD u;
  50.     VWORD v;
  51.     VWORD a;
  52. } VPixelYUV;
  53.  
  54. #endif
  55.