Anton Khirnov
b13fc1e344
h264: do not pass H264Context to h264_slice_header_parse()
...
This should make it more clear that this function does not need any
decoder-global state other than the parameter sets.
9 years ago
Anton Khirnov
996f13413b
h264: fix warnings in fill_filter_caches_inter()
...
The code does some weird casting to a 2-dimensional sub-array of
ref2frm. This is not necessary, since only one dimension is needed
there.
9 years ago
Anton Khirnov
bc7f426851
h264: drop tests whether the codec id is AV_CODEC_ID_H264
...
Those are unused remnants of the old SVQ3 code.
9 years ago
Anton Khirnov
8281cd5cb8
h264_cabac: drop an always true condition
9 years ago
Anton Khirnov
5c2fb561d9
h264: add H264_ prefix to the NAL unit types
...
This will prevent conflicts e.g. in code that deals with both h264 and
hevc.
9 years ago
Anton Khirnov
1cf2f3d334
h264_sei: drop an unnecessary h264dec.h include
...
The code does not depend on the h264 decoder anymore and only needs
information from h264_ps
9 years ago
Anton Khirnov
b24dafe105
lavc: drop unnecessary h264dec.h includes
9 years ago
Anton Khirnov
70b1dcef2d
h264: tighten the valid range for ref_frame_count
...
This field (which the spec calls max_num_ref_frames) must be less than
or equal to MaxDpbFrames, which is at most 16.
9 years ago
Anton Khirnov
f638b67e57
h264: move the parameter set definitions to a new header file
...
The PS parsing code is independent from the decoder, so it makes more
sense for it to have its own separate header.
9 years ago
Anton Khirnov
4e2f621248
svq3: stop using H264Picture
...
The SVQ3 decoder has been decoupled from the H.264 decoder, so it can
now use its own data type.
9 years ago
Anton Khirnov
251cbb4400
h264: create a new header for common h264 definitions
...
Move the NAL unit types into it. This will allow to stop including the
whole decoder-specific h264dec.h in some code that is unrelated to the
decoder and only needs some enum values.
9 years ago
Anton Khirnov
9df889a5f1
h264: rename h264.[ch] to h264dec.[ch]
...
This is more consistent with the naming of other decoders.
9 years ago
Anton Khirnov
f651c6a259
h264: factor out setting frame properties / side data
...
Right now this code is mixed with selecting the next output frame. Move
it to a separate function called from h264_field_start(), which is a
more appropriate place for this.
9 years ago
Anton Khirnov
19446dc5ff
h264: drop unused NAL_FF_IGNORE
9 years ago
Anton Khirnov
bcd91f1644
h264: move a per-field block from decode_slice_header() to field_start()
...
This is a more appropriate place for it.
9 years ago
Anton Khirnov
17e7c03e12
h264: only allow ending a field/starting a new one before finish_setup()
...
Doing this after ff_thread_finish_setup() is called is invalid and can
conflict with reads from the other thread.
9 years ago
Anton Khirnov
debca90863
h264: store {curr,max}_pic_num in the per-slice context
...
While the value of those variables will be constant for the whole frame,
they are only used in two functions called from slice header decoding.
Moving them to the per-slice context allows us to make the H264Context
passed to slice_header_parse() constant.
9 years ago
Anton Khirnov
f966498e43
h264: decode the poc values from the slice header into the per-slice context
...
Copy them into the decoder-global context in field_start(). This avoids
modifying the decoder-global context during bitstream parsing.
9 years ago
Anton Khirnov
54dd9b1cdd
h264: set mb_aff_frame in frame_start()
...
Avoid unnecessary modification of the decoder-global state in per-slice
code.
9 years ago
Anton Khirnov
8d36932c8d
h264: move the block starting a new field out of slice_header_parse()
...
There is no bitstream parsing in that block and messing with
decoder-global state is not something that belongs into header parsing.
Nothing else in this function depends on the value of current_slice,
except for two validity checks. Those checks are also moved out of
slice_header_parse().
9 years ago
Anton Khirnov
b25cd7540e
h264: pass a H2645NAL to slice header decoding
...
Replace the decoder-global nal_unit_type/nal_ref_idc variables with the
per-NAL ones. The decoder-global ones still cannot be removed because
they are used by hwaccels.
9 years ago
Clément Bœsch
26cfafa52d
lavc/h264_slice: mark ref2frm as const pointers
9 years ago
Paul B Mahol
470cd0c5fe
Add TrueMotion 2.0 Real Time decoder
...
Signed-off-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
9 years ago
Paul B Mahol
d78fd2fa21
Add MagicYUV decoder
...
Signed-off-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
9 years ago
Matthieu Bouron
0ea58059d6
lavc/h264_ps: add ff_h264_ps_uninit and use it
9 years ago
Carl Eugen Hoyos
dcdf69561f
lavc/audiotoolboxdec: Forward extradata for QDMC and QDM2.
...
Fixes audiotoolbox decoding of QDMC and QDM2.
9 years ago
Clément Bœsch
38a2d9aeec
lavc/h264_parser: replace AVCodecContext with logging ctx in scan_mmco_reset()
9 years ago
Clément Bœsch
4fdea02d68
lavc/h264: add a logging ctx to ff_h264_pred_weight_table()
9 years ago
Matthieu Bouron
432891a96e
lavc/mediacodecdec{,_h264}: set FF_CODEC_CAP_SETS_PKT_DTS capability
...
And sets frames pkt_dts to AV_NOPTS_VALUE as we do not want lavc/utils
to overwrite the field with incorrect values as the decoder is
asynchronous.
9 years ago
Dan Dennedy
b8d754c5d0
lavc/videotoolbox: Fix videotoolbox compile error on OS X 10.8.
...
Fixes error:
libavcodec/videotoolbox.c:511:18: error: implicit declaration of function
'CMVideoFormatDescriptionCreateFromH264ParameterSets' is invalid in C99
This was added in 10.9:
https://developer.apple.com/reference/coremedia/1489818-cmvideoformatdescriptioncreatefr?language=objc
9 years ago
Clément Bœsch
fd1d84bcf6
lavc/magicyuv: fix undefined behaviour introduced in 8a135a55b
...
Order of evaluation of parameters in C is not defined.
9 years ago
James Almer
5f5a97dc3d
avcodec/qsvenc_h264: declare the QSVEncContext variable before using it
...
Should fix compilation.
Regression introduced by commit 63adb3602d
Signed-off-by: James Almer <jamrial@gmail.com>
9 years ago
Clément Bœsch
34ec084b84
lavc/h264: move history parsing variable to H264ParseContext
...
This makes h264_find_frame_end() not depend on H264Context anymore.
9 years ago
Clément Bœsch
48ea5433c8
lavc/h264_parser: pass logctx to h264_find_frame_end()
...
This helps removing the H264Context from the H264ParseContext.
9 years ago
Paul B Mahol
8a135a55b3
avcodec/magicyuv: check dimensions
...
Signed-off-by: Paul B Mahol <onemda@gmail.com>
9 years ago
Andrey Turkin
63adb3602d
libavcodec: factor out SEI generation for A53 captions
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
9 years ago
Clément Bœsch
b51d5c99b8
lavc/h264_parse: remove tabs introduced in a2922b5d
9 years ago
Jerome Martinez
ec9f04423b
ffv1: Error out on unsupported format
...
Transparency is supported only by YUV and within specific bit depths.
9 years ago
James Almer
403a53c60e
avcodec/ffv1enc: silence warning about deprecated coded_frame
...
Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: James Almer <jamrial@gmail.com>
9 years ago
Michael Niedermayer
4efbeadadc
avcodec/snow: Document BlockNode
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
9 years ago
Michael Niedermayer
737f06577c
avcodec/snow: Remove unused function
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
9 years ago
Clément Bœsch
6cb550e933
lavc/videotoolbox: remove config_info maximum capacity
...
In case of extradata, config_info will contain two entries instead of
one.
9 years ago
Clément Bœsch
6fd58eba1c
lavc/videotoolbox: CFRelease() session
...
"When you are done with a decompression session you created, call
VTDecompressionSessionInvalidate to tear it down and then CFRelease to
release your object reference."
9 years ago
Vittorio Giovara
187d719760
h264: Support AV_PKT_DATA_NEW_EXTRADATA
9 years ago
Vittorio Giovara
75872d77d2
lavc: Document AV_PKT_DATA_NEW_EXTRADATA
9 years ago
Steve Lhomme
193a421994
d3d11va: don't keep the context lock while waiting for a frame
...
also fixes a deadlock found by Денис Кулаков <kudesnik33ra@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
9 years ago
Rick Kern
8b069b1cd5
lavc/videotoolboxenc: remove unnecessary logging
...
Signed-off-by: Rick Kern <kernrj@gmail.com>
9 years ago
Rick Kern
8e47a99f57
lavc/videotoolbox: fix H.264 hwaccel init issue
...
Fixes VTDecompressionSessionCreate() error.
Signed-off-by: Rick Kern <kernrj@gmail.com>
9 years ago
Rick Kern
143685a42b
lavc/audiotoolboxenc: fix dropped frames on iOS
...
AudioConverterFillComplexBuffer() doesn't always call its callback. A frame
queue is used to prevent skipped audio samples.
Signed-off-by: Rick Kern <kernrj@gmail.com>
9 years ago
James Almer
94011f994a
avodec/h264dec: fix compilation with -DTRACE
...
Signed-off-by: James Almer <jamrial@gmail.com>
9 years ago