aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/common.h
diff options
context:
space:
mode:
authorAlex Beregszaszi <alex@rtfs.hu>2002-05-07 17:55:02 +0000
committerAlex Beregszaszi <alex@rtfs.hu>2002-05-07 17:55:02 +0000
commita69b930cd36503d80e7362f91493e306cd800aca (patch)
tree2fd8d915d27be65afe71a94ecb4edfcbec8d4da8 /libavcodec/common.h
parent723106b279d9d78f5966f32bedfa33b88a702f69 (diff)
downloadffmpeg-a69b930cd36503d80e7362f91493e306cd800aca.tar.gz
clamp intra matrix to 8bit for mjpeg (workaround for qscale>=25)
Originally committed as revision 451 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/common.h')
-rw-r--r--libavcodec/common.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/libavcodec/common.h b/libavcodec/common.h
index 815ca29009..38379a4cfc 100644
--- a/libavcodec/common.h
+++ b/libavcodec/common.h
@@ -902,4 +902,6 @@ void *av_mallocz(int size);
/* math */
int ff_gcd(int a, int b);
+#define CLAMP_TO_8BIT(d) ((d > 0xff) ? 0xff : (d < 0) ? 0 : d)
+
#endif