Commit Graph

36 Commits

Author SHA1 Message Date
James Almer b76ff693f6 avfilter/vf_uspp: use av_packet_alloc() to allocate packets
Signed-off-by: James Almer <jamrial@gmail.com>
2021-03-17 15:19:36 -03:00
Andreas Rheinhardt 6e2db67801 avfilter/vf_uspp: Fix leak of packet side data
The uspp filter uses a special option ("no_bitstream") of
the Snow encoder to suppress it from generating output.
The filter therefore did not unref the packet after usage,
believing it to be blank. But this is wrong, as the Snow encoder
attaches quality stats side data to the packet.

Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
2021-03-12 19:05:37 +01:00
Andreas Rheinhardt 0858853241 avfilter/vf_uspp: Fix leak of qp-table on error
Fixes Coverity issue #1473500.

Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
2021-03-12 19:05:11 +01:00
Anton Khirnov c6357311f3 lavfi/vf_uspp: convert to the video_enc_params API 2021-01-01 14:26:09 +01:00
Anton Khirnov e15371061d lavu/mem: move the DECLARE_ALIGNED macro family to mem_internal on next+1 bump
They are not properly namespaced and not intended for public use.
2021-01-01 14:14:57 +01:00
Andreas Rheinhardt 0086432fc7 fftools, libavcodec, libavfilter: Add const to some AVCodec *
The user has no business modifying the underlying AVCodec.

Reviewed-by: Paul B Mahol <onemda@gmail.com>
Reviewed-by: Nicolas George <george@nsup.org>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
2020-09-11 14:42:36 +02:00
Andreas Rheinhardt 8443848dfc avfilter/vf_uspp: Fix potential leak of dict on error
Reviewed-by: Nicolas George <george@nsup.org>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
2020-09-11 14:41:08 +02:00
Anton Khirnov 0d6b4351c6 Remove unnecessary use of avcodec_close().
Replace it with avcodec_free_context() or drop it completely as
appropriate.
2020-06-10 11:31:16 +02:00
Paul B Mahol ed93ed5ee3 avfilter: don't anonymously typedef structs
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2017-05-13 11:39:28 +02:00
Michael Niedermayer 942036e97c avfilter/vf_uspp: Fix currently unused input frame dimensions
Found-by: Nicolas
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-05-10 21:54:31 +02:00
James Almer 963cd953fb avfilter: stop using deprecated codec flags
Signed-off-by: James Almer <jamrial@gmail.com>
2017-03-25 21:37:06 -03:00
Michael Niedermayer e879819e7b avfilter/vf_uspp: Check for encoding failure
Fixes CID1363015

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-07-13 20:16:27 +02:00
Derek Buitenhuis 21f9468402 avutil: Rename FF_CEIL_COMPAT to AV_CEIL_COMPAT
Libav, for some reason, merged this as a public API function. This will
aid in future merges.

A define is left for backwards compat, just in case some person
used it, since it is in a public header.

Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2016-01-27 16:36:46 +00:00
Clément Bœsch b761033e7f avfilter/uspp: use AV_OPT_TYPE_BOOL for use_bframe_qp option 2015-09-09 00:48:03 +02:00
Michael Niedermayer 94d68a41fa Merge commit '7c6eb0a1b7bf1aac7f033a7ec6d8cacc3b5c2615'
* commit '7c6eb0a1b7bf1aac7f033a7ec6d8cacc3b5c2615':
  lavc: AV-prefix all codec flags

Conflicts:
	doc/examples/muxing.c
	ffmpeg.c
	ffmpeg_opt.c
	ffplay.c
	libavcodec/aacdec.c
	libavcodec/aacenc.c
	libavcodec/ac3dec.c
	libavcodec/ac3enc_float.c
	libavcodec/atrac1.c
	libavcodec/atrac3.c
	libavcodec/atrac3plusdec.c
	libavcodec/dcadec.c
	libavcodec/ffv1enc.c
	libavcodec/h264.c
	libavcodec/h264_loopfilter.c
	libavcodec/h264_mb.c
	libavcodec/imc.c
	libavcodec/libmp3lame.c
	libavcodec/libtheoraenc.c
	libavcodec/libtwolame.c
	libavcodec/libvpxenc.c
	libavcodec/libxavs.c
	libavcodec/libxvid.c
	libavcodec/mpeg12dec.c
	libavcodec/mpeg12enc.c
	libavcodec/mpegaudiodec_template.c
	libavcodec/mpegvideo.c
	libavcodec/mpegvideo_enc.c
	libavcodec/mpegvideo_motion.c
	libavcodec/nellymoserdec.c
	libavcodec/nellymoserenc.c
	libavcodec/nvenc.c
	libavcodec/on2avc.c
	libavcodec/options_table.h
	libavcodec/opus_celt.c
	libavcodec/pngenc.c
	libavcodec/ra288.c
	libavcodec/ratecontrol.c
	libavcodec/twinvq.c
	libavcodec/vc1_block.c
	libavcodec/vc1_loopfilter.c
	libavcodec/vc1_mc.c
	libavcodec/vc1dec.c
	libavcodec/vorbisdec.c
	libavcodec/vp3.c
	libavcodec/wma.c
	libavcodec/wmaprodec.c
	libavcodec/x86/hpeldsp_init.c
	libavcodec/x86/me_cmp_init.c

Merged-by: Michael Niedermayer <michael@niedermayer.cc>
2015-07-27 22:10:35 +02:00
Paul B Mahol a0854c084e avfilter: handle error in query_formats() in bunch of filters
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2015-04-08 13:05:06 +00:00
Michael Niedermayer 0f16dfda50 Replace PixelFormats which sneaked in over time or where forgotten by AVPixelFormats
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-18 01:18:40 +01:00
Michael Niedermayer fd048e690b avfilter/vf_uspp: fix gop_size
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-01-25 15:58:28 +01:00
Michael Niedermayer 49456ed606 avfilter/vf_uspp: Use FF_CEIL_RSHIFT() correct rounding of odd w/h
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-01-25 15:58:18 +01:00
Stefano Sabatini 57ede2a507 lavfi: use ff_norm_qscale(), factorize 2015-01-13 13:12:58 +01:00
Michael Niedermayer eb465b8c56 avfilter/vf_uspp: clear AVPacket to not leave uninitialized memory
Fixes CID1260707

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-30 15:15:36 +01:00
Michael Niedermayer 341bd6ec6a avfilter/vf_uspp: use av_malloc_array()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-23 22:52:56 +01:00
Michael Niedermayer 609a73b6ff avfilter/vf_uspp: fix gray pixfmt handling
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-13 17:16:49 +01:00
Michael Niedermayer 3dd5f7aaa0 avfilter/vf_uspp: fix used chroma subsampling factors
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-13 16:54:13 +01:00
Michael Niedermayer 354fda7698 avfilter/vf_uspp: fix used pix_fmt
Found-by: carl
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-13 16:38:44 +01:00
Michael Niedermayer 792a5004a1 avfilter/vf_uspp: Add grayscale support
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-13 05:48:28 +01:00
Michael Niedermayer b898c49ba1 avfilter/vf_uspp: assert that the qp_type is valid
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-13 05:48:28 +01:00
Michael Niedermayer e07c82688e avfilter/vf_uspp: fix integer overflow in intermediate
Fixes Ticket3596

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-12 04:28:34 +01:00
Michael Niedermayer 13c3a97bf1 avfilter/vf_uspp: remove YUV 411/422/440
snow doesnt support 422/411/440 currently, so these do not work yet

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-12 02:00:31 +01:00
Michael Niedermayer e1540cdf07 avfilter/vf_uspp: use the average QP instead of QP[0]
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-12 02:00:31 +01:00
Michael Niedermayer 5172782352 avfilter/vf_uspp: The qp array width is qp_stride not stride/16
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-12 02:00:04 +01:00
Michael Niedermayer d2d8ac24b8 avfilter/vf_uspp: Allocate qp storage after qp_stride is known
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-12 02:00:04 +01:00
Clément Bœsch e93abe1f40 avfilter/uspp: use AVFILTER_DEFINE_CLASS() 2014-12-12 01:52:19 +01:00
Clément Bœsch 397859c4a8 avfilter/uspp: make src const in store_slice_c() 2014-12-12 01:45:29 +01:00
Clément Bœsch 73d88109c0 avfilter/uspp: misc style fixes 2014-12-12 01:42:25 +01:00
Arwa Arif 100fc395b6 lavfi: USPP Filter
Previous version reviewed by: Stefano Sabatini <stefasab@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-12 01:03:44 +01:00