]> git.sesse.net Git - ffmpeg/commitdiff
dnxhd: Add avpriv_dnxhd_get_frame_size()
authorMichael Niedermayer <michaelni@gmx.at>
Fri, 4 Jan 2013 20:18:21 +0000 (21:18 +0100)
committerMichael Niedermayer <michaelni@gmx.at>
Sun, 6 Jan 2013 12:58:46 +0000 (13:58 +0100)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libavcodec/dnxhddata.c
libavcodec/dnxhddata.h

index 9e2e014b43d4f22a39148ee236707eb8d6b9e58b..c433d9d13e255840aff58dbb76fa6020d217ad08 100644 (file)
@@ -1027,6 +1027,14 @@ int ff_dnxhd_get_cid_table(int cid)
     return -1;
 }
 
+int avpriv_dnxhd_get_frame_size(int cid)
+{
+    int i = ff_dnxhd_get_cid_table(cid);
+    if (i<0)
+        return i;
+    return ff_dnxhd_cid_table[i].frame_size;
+}
+
 int ff_dnxhd_find_cid(AVCodecContext *avctx, int bit_depth)
 {
     int i, j;
index 01c3f58fd944b8c8ca3f29a247ce184d685a8f09..f1a6ec7a8ff671260294ee3f52fc1806a7a8e1db 100644 (file)
@@ -50,4 +50,6 @@ extern av_export const CIDEntry ff_dnxhd_cid_table[];
 int ff_dnxhd_get_cid_table(int cid);
 int ff_dnxhd_find_cid(AVCodecContext *avctx, int bit_depth);
 
+int avpriv_dnxhd_get_frame_size(int cid);
+
 #endif /* AVCODEC_DNXHDDATA_H */