summaryrefslogtreecommitdiff
path: root/libavcodec
diff options
context:
space:
mode:
Diffstat (limited to 'libavcodec')
-rw-r--r--libavcodec/dirac.c1
-rw-r--r--libavcodec/dirac.h6
-rw-r--r--libavcodec/diracdec.c3
3 files changed, 9 insertions, 1 deletions
diff --git a/libavcodec/dirac.c b/libavcodec/dirac.c
index aa82dd9854..fd6e869194 100644
--- a/libavcodec/dirac.c
+++ b/libavcodec/dirac.c
@@ -294,6 +294,7 @@ static int parse_source_parameters(AVCodecContext *avctx, GetBitContext *gb,
/* [DIRAC_STD] 10. Sequence Header. sequence_header() */
int avpriv_dirac_parse_sequence_header(AVCodecContext *avctx, GetBitContext *gb,
dirac_source_params *source,
+ DiracVersionInfo *version,
int *bit_depth)
{
unsigned version_major;
diff --git a/libavcodec/dirac.h b/libavcodec/dirac.h
index 14653f1dc2..6852e82d7f 100644
--- a/libavcodec/dirac.h
+++ b/libavcodec/dirac.h
@@ -34,6 +34,11 @@
#include "avcodec.h"
#include "get_bits.h"
+typedef struct DiracVersionInfo {
+ int major;
+ int minor;
+} DiracVersionInfo;
+
typedef struct dirac_source_params {
unsigned width;
unsigned height;
@@ -56,6 +61,7 @@ typedef struct dirac_source_params {
int avpriv_dirac_parse_sequence_header(AVCodecContext *avctx, GetBitContext *gb,
dirac_source_params *source,
+ DiracVersionInfo *version,
int *bit_depth);
#endif /* AVCODEC_DIRAC_H */
diff --git a/libavcodec/diracdec.c b/libavcodec/diracdec.c
index efd2ebd46f..83547eb7ed 100644
--- a/libavcodec/diracdec.c
+++ b/libavcodec/diracdec.c
@@ -140,6 +140,7 @@ typedef struct DiracContext {
MpegvideoEncDSPContext mpvencdsp;
VideoDSPContext vdsp;
DiracDSPContext diracdsp;
+ DiracVersionInfo version;
GetBitContext gb;
dirac_source_params source;
int seen_sequence_header;
@@ -1914,7 +1915,7 @@ static int dirac_decode_data_unit(AVCodecContext *avctx, const uint8_t *buf, int
/* [DIRAC_STD] 10. Sequence header */
ret = avpriv_dirac_parse_sequence_header(avctx, &s->gb, &s->source,
- &s->bit_depth);
+ &s->version, &s->bit_depth);
if (ret < 0)
return ret;