Re: [FFmpeg-devel] [PATCH 1/2] mmaldec: add vc1 decoding support
On Sat, 7 Nov 2015 13:22:48 -0300 James Almerwrote: > On 11/7/2015 1:17 PM, wm4 wrote: > > On Fri, 6 Nov 2015 22:21:55 -0300 > > James Almer wrote: > > > >> On 11/6/2015 12:15 PM, wm4 wrote: > >>> --- > >>> configure | 3 +++ > >>> libavcodec/Makefile| 1 + > >>> libavcodec/allcodecs.c | 2 ++ > >>> libavcodec/mmaldec.c | 12 > >>> 4 files changed, 18 insertions(+) > >>> > >>> diff --git a/configure b/configure > >>> index f770534..8c940a7 100755 > >>> --- a/configure > >>> +++ b/configure > >>> @@ -2516,6 +2516,9 @@ vc1_vdpau_decoder_deps="vdpau" > >>> vc1_vdpau_decoder_select="vc1_decoder" > >>> vc1_vdpau_hwaccel_deps="vdpau" > >>> vc1_vdpau_hwaccel_select="vc1_decoder" > >>> +vc1_mmal_decoder_deps="mmal" > >>> +vc1_mmal_hwaccel_deps="mmal" > >>> +vc1_mmal_decoder_select="vc1video_decoder" > >> > >> vc1_mmal_decoder_select="vc1_decoder" > > > > Fixed locally. Anything else, or can I push? > > > > I can't test it, so if you say it works then go ahead. Maybe the decoder_select shouldn't actually be there in the first place (I really don't get how this holds together), but it does work. Pushed both patches, thanks for the review. ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
Re: [FFmpeg-devel] [PATCH 1/2] mmaldec: add vc1 decoding support
On Fri, 6 Nov 2015 22:21:55 -0300 James Almerwrote: > On 11/6/2015 12:15 PM, wm4 wrote: > > --- > > configure | 3 +++ > > libavcodec/Makefile| 1 + > > libavcodec/allcodecs.c | 2 ++ > > libavcodec/mmaldec.c | 12 > > 4 files changed, 18 insertions(+) > > > > diff --git a/configure b/configure > > index f770534..8c940a7 100755 > > --- a/configure > > +++ b/configure > > @@ -2516,6 +2516,9 @@ vc1_vdpau_decoder_deps="vdpau" > > vc1_vdpau_decoder_select="vc1_decoder" > > vc1_vdpau_hwaccel_deps="vdpau" > > vc1_vdpau_hwaccel_select="vc1_decoder" > > +vc1_mmal_decoder_deps="mmal" > > +vc1_mmal_hwaccel_deps="mmal" > > +vc1_mmal_decoder_select="vc1video_decoder" > > vc1_mmal_decoder_select="vc1_decoder" Fixed locally. Anything else, or can I push? > Also, judging by every other hwaccel, shouldn't you also add a > vc1_mmal_hwaccel_select="vc1_decoder" line? The h264 and mpeg2 mmal ones do not do this either. It probably doesn't make sense to make them selectable, because the hwaccels exist only to make utils.c ff_get_format happy. Selection at build time can be done through the decoder configure options. ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
Re: [FFmpeg-devel] [PATCH 1/2] mmaldec: add vc1 decoding support
On 11/7/2015 1:17 PM, wm4 wrote: > On Fri, 6 Nov 2015 22:21:55 -0300 > James Almerwrote: > >> On 11/6/2015 12:15 PM, wm4 wrote: >>> --- >>> configure | 3 +++ >>> libavcodec/Makefile| 1 + >>> libavcodec/allcodecs.c | 2 ++ >>> libavcodec/mmaldec.c | 12 >>> 4 files changed, 18 insertions(+) >>> >>> diff --git a/configure b/configure >>> index f770534..8c940a7 100755 >>> --- a/configure >>> +++ b/configure >>> @@ -2516,6 +2516,9 @@ vc1_vdpau_decoder_deps="vdpau" >>> vc1_vdpau_decoder_select="vc1_decoder" >>> vc1_vdpau_hwaccel_deps="vdpau" >>> vc1_vdpau_hwaccel_select="vc1_decoder" >>> +vc1_mmal_decoder_deps="mmal" >>> +vc1_mmal_hwaccel_deps="mmal" >>> +vc1_mmal_decoder_select="vc1video_decoder" >> >> vc1_mmal_decoder_select="vc1_decoder" > > Fixed locally. Anything else, or can I push? > I can't test it, so if you say it works then go ahead. >> Also, judging by every other hwaccel, shouldn't you also add a >> vc1_mmal_hwaccel_select="vc1_decoder" line? > > The h264 and mpeg2 mmal ones do not do this either. It probably doesn't > make sense to make them selectable, because the hwaccels exist only to > make utils.c ff_get_format happy. Selection at build time can be done > through the decoder configure options. > ___ > ffmpeg-devel mailing list > ffmpeg-devel@ffmpeg.org > http://ffmpeg.org/mailman/listinfo/ffmpeg-devel > ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
Re: [FFmpeg-devel] [PATCH 1/2] mmaldec: add vc1 decoding support
On 11/6/2015 12:15 PM, wm4 wrote: > --- > configure | 3 +++ > libavcodec/Makefile| 1 + > libavcodec/allcodecs.c | 2 ++ > libavcodec/mmaldec.c | 12 > 4 files changed, 18 insertions(+) > > diff --git a/configure b/configure > index f770534..8c940a7 100755 > --- a/configure > +++ b/configure > @@ -2516,6 +2516,9 @@ vc1_vdpau_decoder_deps="vdpau" > vc1_vdpau_decoder_select="vc1_decoder" > vc1_vdpau_hwaccel_deps="vdpau" > vc1_vdpau_hwaccel_select="vc1_decoder" > +vc1_mmal_decoder_deps="mmal" > +vc1_mmal_hwaccel_deps="mmal" > +vc1_mmal_decoder_select="vc1video_decoder" vc1_mmal_decoder_select="vc1_decoder" Also, judging by every other hwaccel, shouldn't you also add a vc1_mmal_hwaccel_select="vc1_decoder" line? ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
[FFmpeg-devel] [PATCH 1/2] mmaldec: add vc1 decoding support
--- configure | 3 +++ libavcodec/Makefile| 1 + libavcodec/allcodecs.c | 2 ++ libavcodec/mmaldec.c | 12 4 files changed, 18 insertions(+) diff --git a/configure b/configure index f770534..8c940a7 100755 --- a/configure +++ b/configure @@ -2516,6 +2516,9 @@ vc1_vdpau_decoder_deps="vdpau" vc1_vdpau_decoder_select="vc1_decoder" vc1_vdpau_hwaccel_deps="vdpau" vc1_vdpau_hwaccel_select="vc1_decoder" +vc1_mmal_decoder_deps="mmal" +vc1_mmal_hwaccel_deps="mmal" +vc1_mmal_decoder_select="vc1video_decoder" vc1_qsv_hwaccel_deps="libmfx" vc1_qsv_hwaccel_select="qsvdec_vc1" wmv3_crystalhd_decoder_select="crystalhd" diff --git a/libavcodec/Makefile b/libavcodec/Makefile index 67fb72a..c011fd7 100644 --- a/libavcodec/Makefile +++ b/libavcodec/Makefile @@ -534,6 +534,7 @@ OBJS-$(CONFIG_VC1_DECODER) += vc1dec.o vc1_block.o vc1_loopfilter.o vc1dsp.o \ msmpeg4dec.o msmpeg4.o msmpeg4data.o \ wmv2dsp.o +OBJS-$(CONFIG_VC1_MMAL_DECODER)+= mmaldec.o OBJS-$(CONFIG_VC1_QSV_DECODER) += qsvdec_vc1.o OBJS-$(CONFIG_VCR1_DECODER)+= vcr1.o OBJS-$(CONFIG_VMDAUDIO_DECODER)+= vmdaudio.o diff --git a/libavcodec/allcodecs.c b/libavcodec/allcodecs.c index 095f812..efc73d7 100644 --- a/libavcodec/allcodecs.c +++ b/libavcodec/allcodecs.c @@ -108,6 +108,7 @@ void avcodec_register_all(void) REGISTER_HWACCEL(VC1_DXVA2, vc1_dxva2); REGISTER_HWACCEL(VC1_VAAPI, vc1_vaapi); REGISTER_HWACCEL(VC1_VDPAU, vc1_vdpau); +REGISTER_HWACCEL(VC1_MMAL, vc1_mmal); REGISTER_HWACCEL(VC1_QSV, vc1_qsv); REGISTER_HWACCEL(WMV3_D3D11VA, wmv3_d3d11va); REGISTER_HWACCEL(WMV3_DXVA2,wmv3_dxva2); @@ -326,6 +327,7 @@ void avcodec_register_all(void) REGISTER_DECODER(VC1_VDPAU, vc1_vdpau); #endif REGISTER_DECODER(VC1IMAGE, vc1image); +REGISTER_DECODER(VC1_MMAL, vc1_mmal); REGISTER_DECODER(VC1_QSV, vc1_qsv); REGISTER_DECODER(VCR1, vcr1); REGISTER_DECODER(VMDVIDEO, vmdvideo); diff --git a/libavcodec/mmaldec.c b/libavcodec/mmaldec.c index 91fb084..8d74b3f 100644 --- a/libavcodec/mmaldec.c +++ b/libavcodec/mmaldec.c @@ -355,6 +355,10 @@ static av_cold int ffmmal_init_decoder(AVCodecContext *avctx) format_in->encoding = MMAL_ENCODING_MP2V; av_log(avctx, AV_LOG_DEBUG, "Use MMAL MP2V encoding\n"); break; +case AV_CODEC_ID_VC1: +format_in->encoding = MMAL_ENCODING_WVC1; +av_log(avctx, AV_LOG_DEBUG, "Use MMAL WVC1 encoding\n"); +break; case AV_CODEC_ID_H264: default: format_in->encoding = MMAL_ENCODING_H264; @@ -783,6 +787,13 @@ AVHWAccel ff_mpeg2_mmal_hwaccel = { .pix_fmt= AV_PIX_FMT_MMAL, }; +AVHWAccel ff_vc1_mmal_hwaccel = { +.name = "vc1_mmal", +.type = AVMEDIA_TYPE_VIDEO, +.id = AV_CODEC_ID_VC1, +.pix_fmt= AV_PIX_FMT_MMAL, +}; + static const AVOption options[]={ {"extra_buffers", "extra buffers", offsetof(MMALDecodeContext, extra_buffers), AV_OPT_TYPE_INT, {.i64 = 10}, 0, 256, 0}, {NULL} @@ -817,3 +828,4 @@ static const AVOption options[]={ FFMMAL_DEC(h264, AV_CODEC_ID_H264) FFMMAL_DEC(mpeg2, AV_CODEC_ID_MPEG2VIDEO) +FFMMAL_DEC(vc1, AV_CODEC_ID_VC1) -- 2.6.1 ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel