| Commit message (Collapse) | Author | Age |
|
|
|
| |
Signed-off-by: Diego Biurrun <diego@biurrun.de>
|
| |
|
|
|
|
| |
It is always equal to nb_slice_ctx.
|
|
|
|
|
| |
This is more correct and avoids wasting space when frame threading is
used.
|
|
|
|
|
| |
This limit is now unnecessary, we can easily support an arbitrary number
of threads.
|
|
|
|
|
|
|
|
|
|
|
|
| |
In such a case, decode the MBs in parallel without the loop filter, then
execute the filter serially.
The ref2frm array was previously moved to H264SliceContext. That was
incorrect, since it applies to all the slices and should properly be in
H264Context (it did not actually break decoding, since this distinction
only becomes relevant with slice threading and deblocking_filter=1,
which was not implemented before this commit). The ref2frm array is thus
moved back to H264Context.
|
|
|
|
|
| |
It is not used for anything internally, just exported in the output
frames. So remove the indirection and set it directly in frame_start().
|
| |
|
|
|
|
| |
It is no longer called from outside the h264 decoder.
|
|
|
|
|
|
| |
It is always unconditionally initialized in decode_postinit() and then
immediately used in one place further below. All the other places where
it is accessed are just useless fluff.
|
|
|
|
| |
This comment used to apply to code that was removed.
|
| |
|
|
|
|
| |
This will allow decoupling the parser from the decoder.
|
|
|
|
|
| |
Make the SEI parsing independent of the H264Context, to allow
decoupling the parser from the decoder.
|
|
|
|
| |
This will allow decoupling the parser from the decoder.
|
|
|
|
|
|
|
|
|
| |
Make the SPS/PPS parsing independent of the H264Context, to allow
decoupling the parser from the decoder. The change is modelled after the
one done earlier for HEVC.
Move the dequant buffers to the PPS to avoid complex checks whether they
changed and an expensive copy for frame threads.
|
|
|
|
| |
This will allow decoupling the parser from the decoder.
|
|
|
|
| |
It is no longer necessary after 741b494fa8cd28a7d096349bac183893c236e3f9
|
|
|
|
|
| |
It has nothing to do with the reference count and so does not belong in
this function.
|
|
|
|
| |
Remove now unused ff_h264_decode_nal().
|
| |
|
| |
|
|
|
|
|
|
| |
Instead of handling the problem inside NAL decoding code, add a higher
level wrapper function. This should be more robust against future
changes (and easier to read).
|
|
|
|
| |
It is shared with svq3.
|
| |
|
|
|
|
| |
This will allow decoupling the parser from the decoder.
|
|
|
|
|
| |
The profiles are a property of the codec, so it makes sense to export
them through AVCodecDescriptors, not just the codec implementations.
|
|
|
|
|
|
|
|
|
|
|
| |
Fall back to maximum DPB size if the level is unknown.
This should be more spec-compliant and does not depend on the caller
setting has_b_frames before opening the decoder.
The old behaviour, when the delay is supplied by the caller setting
has_b_frames, can still be obtained by setting strict_std_compliance
below normal.
|
|
|
|
|
|
|
| |
This makes the h.264 decoder threadsafe to initialize.
Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
|
|
|
|
|
|
|
| |
There is not much reason to generate such a small table at runtime.
Signed-off-by: Derek Buitenhuis <derekb@vimeo.com>
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
|
|
|
|
| |
Partially amends 9469370fb32679352e66826daf77bdd2e6f067b5
|
|
|
|
|
|
| |
And report why it fails.
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
|
|
|
|
|
|
|
|
|
| |
When skip_frame is set to _NONKEY the decoder skips everything except intra
slices, which breaks frames that consist of an intra field together with any
other field type; half the frame becomes garbage. This patch fixes the issue by
letting non-intra slices through if they're part of a keyframe.
Signed-off-by: Anton Khirnov <anton@khirnov.net>
|
|
|
|
| |
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
|
|
|
|
|
|
| |
Express bitfields more simply.
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
|
|
|
|
|
|
| |
Convert doxygen to multiline and express bitfields more simply.
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
|
|
|
|
| |
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
|
|
|
|
|
|
| |
Partially based on code by Marton Balint and Kieran Kunhya.
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
|
|
|
|
|
|
| |
finish_setup()
Should fix a large number of possible races with frame threading.
|
| |
|
|
|
|
|
| |
It now has a fixed size and is initialized only once, so there is no
point in allocating it separately.
|
| |
|
|
|
|
|
| |
It does not logically belong in free_tables(), since it's not allocated
in alloc_tables() and its size has nothing to do with the frame size.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
That function currently does two things -- reinitializing the DSP
contexts and setting low_delay based on the SPS values.
The former more appropriately belongs in h264_slice_header_init(), while
the latter only really makes sense in decode_slice_header().
The third call to ff_h264_set_parameter_from_sps(), done immediately
after parsing a new SPS, appears to serve no useful purpose, so it is
just dropped.
Also, drop now unneeded H264Context.cur_chroma_format_idc.
|
|
|
|
|
|
|
|
|
|
| |
Currently, the DPB is initialized in alloc_tables() and uninitialized in
free_tables(), but those functions manage frame size-dependent
variables, so DPB management does not logically belong in there.
Since we want the init/uninit to happen exactly once per the context
lifetime, init_context()/free_context() are the proper place for this
code.
|
|
|
|
| |
It is only set, but never used for anything.
|
|
|
|
| |
It is not needed anymore since switching to refcounted frames.
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
The generic code copies the main context's private data to all the
others. However that is quite dangerous, as it might end up copying some
pointers that are or will become invalid.
Since everything we actually need will be copied later in
update_thread_context(), it's safest to zero the private data in
init_thread_copy(), so it works the same way as init for the main
context.
|
| |
|