* - decoding: set by lavc\
*/\
AVPanScan *pan_scan;\
-
+ \
+ /**\
+ * tell user application that palette has changed from previous frame.\
+ * - encoding: ??? (no palette-enabled encoder yet)\
+ * - decoding: set by lavc (default 0)\
+ */\
+ int palette_has_changed;\
#define FF_QSCALE_TYPE_MPEG1 0
#define FF_QSCALE_TYPE_MPEG2 1
* - decoding: unused
*/
int lmax;
+
+ /**
+ * Palette control structure
+ * - encoding: ??? (no palette-enabled encoder yet)
+ * - decoding: set by user.
+ */
+ struct AVPaletteControl *palctrl;
} AVCodecContext;
* This structure defines a method for communicating palette changes
* between and demuxer and a decoder.
*/
+#define AVPALETTE_SIZE 256
typedef struct AVPaletteControl {
/* demuxer sets this to 1 to indicate the palette has changed;
* decoder resets to 0 */
int palette_changed;
- /* 256 3-byte RGB palette entries; the components should be
- * formatted in the buffer as "RGBRGB..." and should be scaled to
- * 8 bits if they originally represented 6-bit VGA palette
- * components */
- unsigned char palette[256 * 3];
+ /* 4-byte ARGB palette entries, stored in native byte order; note that
+ * the individual palette components should be on a 8-bit scale; if
+ * the palette data comes from a IBM VGA native format, the component
+ * data is probably 6 bits in size and needs to be scaled */
+ unsigned int palette[AVPALETTE_SIZE];
} AVPaletteControl;