summaryrefslogtreecommitdiff
path: root/libavcodec/mjpegenc.h
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2015-03-30 21:05:23 +0200
committerMichael Niedermayer <michaelni@gmx.at>2015-03-30 21:05:23 +0200
commit794e9fb5a649b4489e7369eb846049d4a03f3ff9 (patch)
tree775f1981d407c36b0ebdc8daa61bb3f2c920025d /libavcodec/mjpegenc.h
parent847c0d333b6a195670f5bd64e9f7e5c9cf254cc4 (diff)
parente6e3dcba0c6f11bd7022e2d3b9bcb7b6a09d6c80 (diff)
downloadffmpeg-794e9fb5a649b4489e7369eb846049d4a03f3ff9.tar.gz
Merge commit 'e6e3dcba0c6f11bd7022e2d3b9bcb7b6a09d6c80'
* commit 'e6e3dcba0c6f11bd7022e2d3b9bcb7b6a09d6c80': mjpeg: Move code only used in the encoder(s) to the appropriate header Conflicts: libavcodec/mjpegdec.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/mjpegenc.h')
-rw-r--r--libavcodec/mjpegenc.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/libavcodec/mjpegenc.h b/libavcodec/mjpegenc.h
index 069d43c816..ad2a55425e 100644
--- a/libavcodec/mjpegenc.h
+++ b/libavcodec/mjpegenc.h
@@ -36,6 +36,7 @@
#include <stdint.h>
#include "mpegvideo.h"
+#include "put_bits.h"
typedef struct MJpegContext {
uint8_t huff_size_dc_luminance[12]; //FIXME use array [3] instead of lumi / chrom, for easier addressing
@@ -49,6 +50,12 @@ typedef struct MJpegContext {
uint16_t huff_code_ac_chrominance[256];
} MJpegContext;
+static inline void put_marker(PutBitContext *p, int code)
+{
+ put_bits(p, 8, 0xff);
+ put_bits(p, 8, code);
+}
+
int ff_mjpeg_encode_init(MpegEncContext *s);
void ff_mjpeg_encode_close(MpegEncContext *s);
void ff_mjpeg_encode_mb(MpegEncContext *s, int16_t block[12][64]);