summaryrefslogtreecommitdiff
path: root/libavcodec/vp9_metadata_bsf.c
Commit message (Collapse)AuthorAge
* avcodec.h: split bitstream filters API into its own headerAnton Khirnov2020-05-22
|
* lavc: rename bsf.h to bsf_internal.hAnton Khirnov2020-05-22
| | | | This will allow adding a public header named bsf.h
* vp9_metadata: Improve spec-compliance and warningsAndreas Rheinhardt2019-07-28
| | | | | | | | | | | | | | | | | | The earlier version had three deficits: 1. It allowed to set the stream to RGB although this is not allowed when the profile is 0 or 2. 2. If it set the stream to RGB, then it did not automatically set the range to full range; the result was that one got a warning every time a frame with color_config element was processed if the frame originally had TV range and the user didn't explicitly choose PC range. Now one gets only one warning in such a situation. 3. Intra-only frames in profile 0 are automatically BT.601, but if the user wished another color space, he was not informed about his wishes being unfulfillable. The commit also improves the documentation about this. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* vp9_metadata: Avoid allocations and copies of packet structuresAndreas Rheinhardt2019-07-07
| | | | | | | | | | | This commit changes vp9_metadata to (a) use ff_bsf_get_packet_ref instead of ff_bsf_get_packet (thereby avoiding one malloc and free per filtered packet) and (b) to use only one packet structure at all, thereby avoiding a call to av_packet_copy_props. (b) has been made possible by the recent changes to ff_cbs_write_packet. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* libavcodec/cbs: Stop needlessly reallocating the units arrayAndreas Rheinhardt2019-02-25
| | | | | | | | | | | | | | | | | Currently, a fragment's unit array is constantly reallocated during splitting of a packet. This commit changes this: One can keep the units array by distinguishing between the number of allocated and the number of valid units in the units array. The more units a packet is split into, the bigger the benefit. So MPEG-2 benefits the most; for a video coming from an NTSC-DVD (usually 32 units per frame) the average cost of cbs_insert_unit (for a single unit) went down from 6717 decicycles to 450 decicycles (based upon 10 runs with 4194304 runs each); if each packet consists of only one unit, it went down from 2425 to 448; for a H.264 video where most packets contain nine units, it went from 4431 to 450. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@googlemail.com>
* lavc: Add VP9 metadata bitstream filterMark Thompson2018-05-02
Can adjust the colour information.