Commit graph

7 commits

Author SHA1 Message Date
Andreas Rheinhardt
1d66a122df avcodec/avcodec: Deprecate AV_INPUT_BUFFER_MIN_SIZE
It used to be used with preallocated packet buffers with
the old encode API, but said API is no more and therefore
there is no reason for this to be public any more.
So deprecate it and use an internal replacement
for the encoders using it as an upper bound for the
size of their headers.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2024-02-21 00:24:44 +01:00
Andreas Rheinhardt
9c471c76cb avcodec/msrleenc: Constify pointers for frame->data
Encoders (usually) have no business modifying frame->data
(which need not be writable), so they should use the appropriate
pointers.

Reviewed-by: Tomas Härdin <git@haerdin.se>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2023-07-17 16:23:26 +02:00
Andreas Rheinhardt
3cb0bd06a8 avcodec/msrleenc: Check frame allocations/references
Also allocate the AVFrame during init and use av_frame_replace()
to replace it later.

Reviewed-by: Tomas Härdin <git@haerdin.se>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2023-07-17 16:23:18 +02:00
Andreas Rheinhardt
66449f8c6b avcodec/msrleenc: Remove useless private class
A private class for an encoder without options is useless.

Reviewed-by: Tomas Härdin <git@haerdin.se>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2023-07-17 16:23:12 +02:00
Andreas Rheinhardt
3c642af8e0 avcodec/msrleenc: Check allocation
Fixes Coverity issue #1538297.

Reviewed-by: Tomas Härdin <git@haerdin.se>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2023-07-17 16:23:07 +02:00
Andreas Rheinhardt
a054ceb4e2 avcodec/msrleenc: Replace stray \r by \n
Reviewed-by: Tomas Härdin <git@haerdin.se>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2023-07-17 16:18:18 +02:00
Tomas Härdin
8e53233f68 lavc/msrleenc: Add msrle encoder
Keyframes are marked automagically
2023-06-20 14:37:52 +02:00