Files
ffmpeg/libavcodec
Andreas Rheinhardt 1cf238d3bf avcodec/cbs: Factor out common code for writing units
All cbs-functions to write units share a common pattern:
1. They check whether they have a write buffer (that is used to store
the unit's data until the needed size becomes known after writing the
unit when a dedicated buffer will be allocated).
2. They use this buffer for a PutBitContext.
3. The (codec-specific) writing takes place through the PutBitContext.
4. The return value is checked. AVERROR(ENOSPC) here always indicates
that the buffer was too small and leads to a reallocation of said
buffer.
5. The final buffer will be allocated and the data copied.

This commit factors this common code out in a single function in cbs.c.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
(cherry picked from commit 7c92eaace2)
2019-12-31 16:57:37 -03:00
..
2019-12-31 19:51:57 +01:00
2019-06-12 20:06:20 +10:00
2018-10-15 01:19:45 +02:00
2018-08-08 00:13:13 +05:30
2019-06-26 21:25:10 +02:00
2018-07-18 13:59:25 +02:00
2019-06-12 20:06:20 +10:00
2019-09-04 20:26:35 +02:00
2019-04-21 19:43:14 +02:00
2019-05-06 23:58:34 +02:00
2019-12-31 19:51:57 +01:00
2018-12-23 15:30:13 +01:00
2018-12-10 11:19:36 +01:00
2018-09-23 15:25:50 +02:00
2018-12-20 18:40:41 +08:00
2019-01-16 01:29:18 +01:00
2019-06-29 19:22:19 +02:00
2019-07-01 13:24:57 +08:00
2019-09-04 20:26:35 +02:00
2019-12-31 19:51:56 +01:00
2019-09-02 13:53:08 -07:00
2019-03-31 23:35:00 +02:00
2018-12-23 15:30:13 +01:00
2018-12-01 19:41:48 +01:00
2019-12-31 19:51:56 +01:00
2019-01-12 17:16:47 +01:00
2019-05-07 11:00:19 +08:00
2019-04-03 23:00:15 +08:00
2018-12-03 23:34:05 +01:00
2019-09-04 20:26:35 +02:00
2018-11-18 22:59:29 +01:00
2019-12-31 19:51:57 +01:00
2019-07-08 09:38:03 +02:00
2019-12-31 19:51:56 +01:00
2018-09-08 21:21:50 +02:00
2019-12-31 19:51:56 +01:00
2018-12-31 02:37:08 +01:00
2019-12-31 19:51:57 +01:00
2019-06-12 20:06:20 +10:00
2019-12-31 19:51:56 +01:00
2019-09-04 20:26:35 +02:00
2019-09-04 20:26:35 +02:00
2019-08-05 19:34:33 +02:00
2019-05-02 15:36:16 +02:00
2019-05-02 15:36:16 +02:00