Martin Schitter: > This is a second attempt to contribute the corrected code of an > AVID DNxUncompressed / SMTPE RDD 50 decoder. > > Thanks > Martin > > --- > Changelog | 1 + > doc/general_contents.texi | 1 + > libavcodec/Makefile | 1 + > libavcodec/allcodecs.c | 1 + > libavcodec/codec_desc.c | 7 + > libavcodec/codec_id.h | 1 + > libavcodec/dnxucdec.c | 495 ++++++++++++++++++++++++++++++++++++++ > libavcodec/parsers.c | 1 + > libavcodec/version.c | 2 +- > libavcodec/version.h | 2 +- > libavformat/mxf.c | 1 + > libavformat/mxfdec.c | 21 ++ > 12 files changed, 532 insertions(+), 2 deletions(-) > create mode 100644 libavcodec/dnxucdec.c
> > diff --git a/libavcodec/codec_id.h b/libavcodec/codec_id.h > index 0ab1e34..27b229b 100644 > --- a/libavcodec/codec_id.h > +++ b/libavcodec/codec_id.h > @@ -321,6 +321,7 @@ enum AVCodecID { > AV_CODEC_ID_EVC, > AV_CODEC_ID_RTV1, > AV_CODEC_ID_VMIX, > + AV_CODEC_ID_DNXUC, > AV_CODEC_ID_LEAD, > > /* various PCM "codecs" */ > diff --git a/libavcodec/dnxucdec.c b/libavcodec/dnxucdec.c > new file mode 100644 > index 0000000..502e736 > --- /dev/null > +++ b/libavcodec/dnxucdec.c > + > +const AVCodecParser ff_dnxuc_parser = { > + .codec_ids = { AV_CODEC_ID_DNXUC }, > + .priv_data_size = sizeof(DNxUcParseContext), > + .parser_parse = dnxuc_parse, > +}; > + > +const FFCodec ff_dnxuc_decoder = { > + .p.name = "dnxuc", > + CODEC_LONG_NAME()"DNxUncompressed (SMPTE RDD 50)", This shouldn't even compile. > + .p.type = AVMEDIA_TYPE_VIDEO, > + .p.id = AV_CODEC_ID_DNXUC, > + .init = dnxuc_decode_init, > + FF_CODEC_DECODE_CB(dnxuc_decode_frame), > + .p.capabilities = AV_CODEC_CAP_FRAME_THREADS, > +}; > \ No newline at end of file This should be fixed. > diff --git a/libavcodec/version.c b/libavcodec/version.c > index 27f9432..c3b576a 100644 > --- a/libavcodec/version.c > +++ b/libavcodec/version.c > @@ -31,7 +31,7 @@ const char av_codec_ffversion[] = "FFmpeg version " > FFMPEG_VERSION; > > unsigned avcodec_version(void) > { > - static_assert(AV_CODEC_ID_LEAD == 269 && > + static_assert(AV_CODEC_ID_LEAD == 270 && > AV_CODEC_ID_PCM_SGA == 65572 && > AV_CODEC_ID_ADPCM_XMD == 69683 && > AV_CODEC_ID_CBD2_DPCM == 81928 && This is by definition the wrong fix. Instead you should do as the assert message tells you: Don't insert your new ID in the middle of the list. Didn't look closely at the rest (but it already seems like there are many issues). - Andreas _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".