]> git.sesse.net Git - ffmpeg/blobdiff - libavformat/qtpalette.h
AAC encoder: various fixes in M/S coding
[ffmpeg] / libavformat / qtpalette.h
index 7d6802f73c6d5add5b1e6e77a6ef5f9f748a01c3..b2bd3600c5392a31d5c4c2f3235c460b01171a3b 100644 (file)
 #ifndef AVFORMAT_QTPALETTE_H
 #define AVFORMAT_QTPALETTE_H
 
-#include <inttypes.h>
+#include <stdint.h>
+#include "avformat.h"
+
+static const uint8_t ff_qt_default_palette_2[2 * 3] = {
+  0xFF, 0xFF, 0xFF,
+  0x00, 0x00, 0x00
+};
 
 static const uint8_t ff_qt_default_palette_4[4 * 3] = {
   0x93, 0x65, 0x5E,
@@ -310,4 +316,15 @@ static const uint8_t ff_qt_default_palette_256[256 * 3] = {
   /* 255, 0xFF */  0x00, 0x00, 0x00
 };
 
+/**
+ * Retrieve the palette (or "color table" in QuickTime terms), either
+ * from the video sample description, or from the default Macintosh
+ * palette.
+ *
+ * The file offset of the AVIOContext pointed to by the 'pb' variable
+ * should be the start of the video sample description (the sample
+ * description size and the data format).
+ */
+int ff_get_qtpalette(int codec_id, AVIOContext *pb, uint32_t *palette);
+
 #endif /* AVFORMAT_QTPALETTE_H */