This commit resets any bands marked as M/S or IS upon encoding a frame.
This is needed because the arrays may contain some residual information
upon allocation on startup and because there isn't any mechanism to
reset the arrays once the frame has been encoded.
Reviewed-by: Claudio Freire <klaussfreire@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
There were some mistakes in the code for M/S stereo, this commit fixes them.
The start variable was not being reset for every window and every access to
the coefficients was incorrect as well. This fixes that by properly
addressing the coefficients using both windows and setting the start on every window to zero.
Reviewed-by: Claudio Freire <klaussfreire@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit modifies 02dbed6 to use band->active_lines to better gauge how much information is contained within a single band and thus allow the perceptual noise subsitution to more accurately determine which bands to code as noise. The spread[w+g] used before this patch behaved more like a low-pass filter for PNS band_types, which could mistakingly mark some low frequency bands as noise.
Reviewed-by: Claudio Freire <klaussfreire@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* commit '80f955c90867561dcce769216bc497e13281eb38':
vda: Check the correct pointer for buffer allocation
Merged-by: Michael Niedermayer <michaelni@gmx.at>
The loop always needs at least 8 bytes for chunk_type and chunk_size.
If fewer are left, bytestream2_get_le32 just returns 0 without
reading any bytes, leading to an infinite loop.
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Every chunk needs at least 8 bytes for chunk_type and chunk_size.
Prevent a possible infinite loop.
CC: libav-stable@libav.org
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
They are used by dnxhd and mpegvideo_enc exclusively, move them to codec
private options instead.
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
More than 32 bits can't be stored in an integer and get_bits should not
be used with more than 25 bits.
Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
Now ff_qsv_init_internal_session() is able
to find appropriate display handle under linux using VAAPI.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This also simplifies the code
Fixes: signal_sigabrt_7ffff6ac8cc9_2943_cov_3588637614_mss2_speech.wmv
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* commit '9eec23b8a7fd0f91827bbc3ed0792c39a8cc9a8a':
g2meet: use av_ceil_log2 instead of a custom function
Merged-by: Michael Niedermayer <michaelni@gmx.at>
This patch adds MSA (MIPS-SIMD-Arch) optimizations for mpegvideo functions in new file mpegvideo_msa.c
Signed-off-by: Shivraj Patil <shivraj.patil@imgtec.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* commit '3f872c9bfa8ee1032058cfa48068b5a73ef27b5e':
lavc: Add missing API guard to dtg_active_format option
Merged-by: Michael Niedermayer <michaelni@gmx.at>
Fixes out of array access
Fixes: signal_sigsegv_3670fc0_2818_cov_2307326154_moon.mux
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
ELS and ePIC decoder courtesy of Maxim Poliakovski,
cleanup and integration by Diego Biurrun.
Signed-off-by: Diego Biurrun <diego@biurrun.de>
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
This is the first part of the fix for ticket #4370.
Reviewed-by: Michael Niedermayer <michaelni@gmx.at>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
* commit '271ce76d317c5432e151216cf23f12b77ed6cb7e':
h264: Parse registered data SEI message and AFD value
Conflicts:
libavcodec/h264.c
libavcodec/h264.h
libavcodec/h264_sei.c
libavcodec/version.h
See: d6e9566949
See: 22291c372f
Merged-by: Michael Niedermayer <michaelni@gmx.at>
* commit '3e3056f2a020dd77efdf379dbd4c06a65b4a499a':
h264: Allow stream and container cropping at the same time
Conflicts:
libavcodec/h264_slice.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>