summaryrefslogtreecommitdiff
path: root/libswscale/swscale.h
diff options
context:
space:
mode:
authorReinhard Tartler <siretart@tauware.de>2010-06-01 19:35:16 +0000
committerReinhard Tartler <siretart@tauware.de>2010-06-01 19:35:16 +0000
commit2b991422f8fd6865bd5d0069a3f91827a4e6016e (patch)
tree3d9ebeffbe27eaaaf2c5c630646bddd5914ad86a /libswscale/swscale.h
parent73404a44c1aa647c48bb8d91e1ed51824e8f3376 (diff)
deprecate palette8topacked32 in favor of public API functions sws_convertPalette8ToPacked32 and -24
additionallym deprecate palette8torgb16 and its bgr variant without replacement. These functions are not meant to be used by applications. Discussed at: http://comments.gmane.org/gmane.comp.video.ffmpeg.devel/109340 Originally committed as revision 31301 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale
Diffstat (limited to 'libswscale/swscale.h')
-rw-r--r--libswscale/swscale.h27
1 files changed, 26 insertions, 1 deletions
diff --git a/libswscale/swscale.h b/libswscale/swscale.h
index f6e0ccfd48..5a9f97c5fe 100644
--- a/libswscale/swscale.h
+++ b/libswscale/swscale.h
@@ -30,7 +30,7 @@
#include "libavutil/avutil.h"
#define LIBSWSCALE_VERSION_MAJOR 0
-#define LIBSWSCALE_VERSION_MINOR 10
+#define LIBSWSCALE_VERSION_MINOR 11
#define LIBSWSCALE_VERSION_MICRO 0
#define LIBSWSCALE_VERSION_INT AV_VERSION_INT(LIBSWSCALE_VERSION_MAJOR, \
@@ -303,4 +303,29 @@ struct SwsContext *sws_getCachedContext(struct SwsContext *context,
int flags, SwsFilter *srcFilter,
SwsFilter *dstFilter, const double *param);
+/**
+ * Converts an 8bit paletted frame into a frame with a color depth of 32-bits.
+ *
+ * The output frame will have the same packed format as the palette.
+ *
+ * @param src source frame buffer
+ * @param dst destination frame buffer
+ * @param num_pixels number of pixels to convert
+ * @param palette array with [256] entries, which must match color arrangement (RGB or BGR) of src
+ */
+void sws_convertPalette8ToPacked32(const uint8_t *src, uint8_t *dst, long num_pixels, const uint8_t *palette);
+
+/**
+ * Converts an 8bit paletted frame into a frame with a color depth of 24 bits.
+ *
+ * With the palette format "ABCD", the destination frame ends up with the format "ABC".
+ *
+ * @param src source frame buffer
+ * @param dst destination frame buffer
+ * @param num_pixels number of pixels to convert
+ * @param palette array with [256] entries, which must match color arrangement (RGB or BGR) of src
+ */
+void sws_convertPalette8ToPacked24(const uint8_t *src, uint8_t *dst, long num_pixels, const uint8_t *palette);
+
+
#endif /* SWSCALE_SWSCALE_H */