Commit Graph

2501 Commits

Author SHA1 Message Date
Andreas Rheinhardt 1be3d8a0cb avcodec/avcodec: Stop including channel_layout.h in avcodec.h
Also include channel_layout.h directly wherever used.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2021-07-22 11:14:31 +02:00
Andreas Rheinhardt 57b5ec6ba7 avcodec/avcodec: Stop including bsf.h in avcodec.h
Also include bsf.h directly wherever it is used.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2021-07-22 11:14:16 +02:00
Anton Khirnov 296dc876ec lavc: fix and extend AVCodecContext.get_format doxy
Remove some incorrect (or at least misleading) statements, such as the
formats being ordered by quality, or the first format being the native
one. Neither of those are true for hardware acceleration, which is the
main use of this callback.
2021-06-26 19:33:42 +02:00
Anton Khirnov 7c9763070d lavc: move av_get_profile_name() from avcodec.h to codec.h 2021-06-10 16:51:44 +02:00
Anton Khirnov bb3648e676 lavc: move av_get_audio_frame_duration2() from avcodec.h to codec_par.h 2021-06-10 16:51:44 +02:00
Anton Khirnov 881db34f6a lavc: move av_get_pcm_codec() from avcodec.h to codec_id.h 2021-06-10 16:51:44 +02:00
Anton Khirnov 2628dff366 lavc: move avcodec_profile_name() from avcodec.h to codec_id.h 2021-06-10 16:51:44 +02:00
Anton Khirnov 000f35125f lavc: move av_get_[exact_]bits_per_sample() to codec_id.h 2021-06-10 16:51:44 +02:00
Anton Khirnov ff0a96046d lavc: move small misc definitions into a separate header
This will allow to avoid #including the entire avcodec.h in some places.
2021-06-10 16:51:44 +02:00
James Almer f44d4f511d avcodec: remove leftover references to AVCodecContext.refcounted_frames
Signed-off-by: James Almer <jamrial@gmail.com>
2021-05-13 22:36:25 -03:00
James Almer 5b5398722e avcodec: be more explicit about the buffer size in get_encode_buffer documentation
Signed-off-by: James Almer <jamrial@gmail.com>
2021-05-07 13:16:14 -03:00
Andreas Rheinhardt 83b6471dcb avcodec/avcodec: Remove unnecessary forward declaration
Forgotten in ba6cada92e.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2021-04-28 01:50:39 +02:00
Andreas Rheinhardt cb3ac722f4 avcodec: Constify AVCodecParserContext.parser
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-04-27 10:43:15 -03:00
Andreas Rheinhardt 7c1f347b18 avcodec: Remove deprecated old encode/decode APIs
Deprecated in commits 7fc329e2dd
and 31f6a4b4b8.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-04-27 10:43:12 -03:00
Andreas Rheinhardt 11bc790893 avcodec: Remove deprecated AVCodecContext.coded_frame
Deprecated in 40cf1bbacc.
(The currently disabled filter vf_mcdeint and vf_uspp were users of
this field; they have not been changed, so that whoever wants to fix
them can see the state of these filters when they were disabled.)

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-04-27 10:43:12 -03:00
Andreas Rheinhardt f0c7fa2c48 avcodec: Switch AVCPBProperties to 64bits
Announced in 2e8b0446c6.
Two FATE-tests needed to be updated because the checksums of
side data containing an AVCPBProperties struct changed.

buffer_size has also been switched to 64bits because it is a bitsize.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-04-27 10:43:07 -03:00
Andreas Rheinhardt f34521266e avcodec/parser: Remove deprecated av_parser_change
Deprecated in 9a07c1332c.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-04-27 10:43:07 -03:00
Andreas Rheinhardt e3d993fab0 avcodec/vaapi: Remove old and deprecated VAAPI context and header
Deprecated in 851960f6f8.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-04-27 10:43:06 -03:00
Andreas Rheinhardt eb6ea948ed avcodec: Remove deprecated VBV delay field
Deprecated in 2507b5dd67.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-04-27 10:43:05 -03:00
Andreas Rheinhardt 4a66fe1588 avcodec/imgconvert: Remove deprecated parts of pixel format API
Deprecated in 617e866e25 and
2a54ae9df8.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-04-27 10:43:04 -03:00
Andreas Rheinhardt d947464ad4 avcodec: Remove deprecated AVPicture API
Deprecated in a17a766190.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-04-27 10:43:04 -03:00
Andreas Rheinhardt bc9dca5c95 avcodec/options: Remove deprecated avcodec_copy_context
Deprecated in 5f30ac2779.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-04-27 10:43:04 -03:00
Andreas Rheinhardt ff8f9fcbe5 avcodec: Remove deprecated avcodec_get_context_defaults3
Deprecated in 04fc8e24a0.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-04-27 10:43:04 -03:00
Andreas Rheinhardt 1f63665ca5 avcodec: Remove deprecated ASS with inline timing
Deprecated in 22ebbda637.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-04-27 10:43:04 -03:00
Andreas Rheinhardt cb172ae9ab avcodec/mpegvideo_enc: Remove deprecated RTP-callback
Deprecated in 462a54e229.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-04-27 10:43:04 -03:00
Andreas Rheinhardt d6cb7bf599 avcodec: Remove deprecated avcodec_get_chroma_sub_sample
Effectively deprecated in 2c800eb737.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-04-27 10:43:03 -03:00
Andreas Rheinhardt f581433e8b avcodec: Remove remnants of user-visiable HW acceleration API
Disabled and deprecated in 3536a3efb9.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-04-27 10:43:03 -03:00
Andreas Rheinhardt e8fdb0db16 avcodec: Remove lock manager API
Deprecated in a04c2c707d.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-04-27 10:43:03 -03:00
Andreas Rheinhardt d1d8a81874 avcodec: Remove deprecated av_codec_get_tag_string
Deprecated in f156d35321.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-04-27 10:43:03 -03:00
Andreas Rheinhardt 23bb78d2ea avcodec: Remove unneeded getters and setters
Deprecated in c4131a0613.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-04-27 10:43:02 -03:00
Andreas Rheinhardt d85c41b572 avcodec: Remove private options from AVCodecContext
Several options that were too codec-specific were deprecated between
0e6c853221 and
0e9c4fe254.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-04-27 10:43:02 -03:00
Andreas Rheinhardt 78ce00428f avcodec: Remove deprecated coder type options
Deprecated in be00ec832c.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-04-27 10:43:01 -03:00
Andreas Rheinhardt 6cf0cb8935 avcodec: Remove deprecated stat-bits fields
Deprecated in 16216b713f.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-04-27 10:43:00 -03:00
Andreas Rheinhardt df6b44182e avcodec, avformat: Remove AVPacket.convergence_duration
Deprecated in 948f3c19a8.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-04-27 10:43:00 -03:00
Andreas Rheinhardt 26ca5ebd7b avcodec: Remove sidedata-only-packet cruft
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-04-27 10:42:59 -03:00
Andreas Rheinhardt 0f247986ad avcodec, avformat: Remove old BSF API
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-04-27 10:42:59 -03:00
Andreas Rheinhardt 4b2be3f8d4 avcodec: Remove AVCodec, AVParser and AVBitStreamFilter next API
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-04-27 10:42:58 -03:00
James Almer 1af4885014 avcodec: add a mention about get_encode_buffer in the old encode API doxy
Direct users to the callback that should be used to keep supporting user
provided buffers with the new encode API.

Reviewed-by: Anton Khirnov <anton@khirnov.net>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-03-14 13:37:01 -03:00
James Almer 6e7e3a3820 avcodec: add a get_encode_buffer() callback to AVCodecContext
This callback is functionally the same as get_buffer2() is for decoders, and
implements for the new encode API the functionality of the old encode API had
where the user could provide their own buffers.

Reviewed-by: Lynne <dev@lynne.ee>
Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Reviewed-by: Mark Thompson <sw@jkqxz.net>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-03-12 19:49:08 -03:00
Anton Khirnov 54e5d21aca lavc: clarify thread_safe_callbacks doxy
State explicitly when this field will be removed and how to access it in
a forward compatible way.
2021-03-08 11:34:54 +01:00
Andreas Rheinhardt 136dd5b592 avcodec/avcodec: Don't suggest calling deprecated avcodec_register_all()
Despite avcodec_register and avcodec_register_all being deprecated,
their documentation still said that one of them has to be called
before doing anything else. Clarify this confusing situation.

Furthermore, don't use avcodec_register_all in sample code for
a non-deprecated function.

Reviewed-by: mypopy@gmail.com <mypopy@gmail.com>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
2021-03-08 02:42:20 +01:00
Andreas Rheinhardt dc20b27802 avcodec/parser: Schedule av_parser_change for removal
Originally deprecated in 748c2fca7e,
publically deprecated in 9a07c1332c
(merged into FFmpeg in 1885ffb03d).

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
2021-03-06 09:33:42 +01:00
Jan Ekström a0eec776b6 avcodec: enable usage of err_recognition for encoders
Enables the usage of such values as AV_EF_EXPLODE in encoders, which
can be useful in cases such as subtitle encoders where they have the
responsibility to validate the correctness of an incoming ASS dialog line.

Signed-off-by: Jan Ekström <jan.ekstrom@24i.com>
2021-03-05 19:45:00 +02:00
James Almer dd9227e48f avcodec/options: deprecate avcodec_get_frame_class()
AVFrame hasn't been a struct defined in libavcodec for a decade now, when
it was moved to libavutil.

Found-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-02-27 11:23:42 -03:00
Andreas Rheinhardt 169259d9a3 avcodec: Add missing FF_API define for libavcodec pix fmt API
avcodec_find_best_pix_fmt2 has been deprecated and replaced by
avcodec_find_best_pix_fmt_of_2 in 2a54ae9df8.
avcodec_find_best_pix_fmt_of_2 and avcodec_get_pix_fmt_loss meanwhile
were deprecated in 617e866e25 when these
functions were de facto moved to libavutil; this has been mentioned in
APIchanges in f7a1c5e4d2. Yet the
attribute_deprecated was never set for the latter two functions and they
were not wrapped in an FF_API define. This commit does this.

Reviewed-by: Paul B Mahol <onemda@gmail.com>
Reviewed-by: James Almer <jamrial@gmail.com>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
2021-02-26 18:29:45 +01:00
Andreas Rheinhardt e4524270f4 avcodec/avcodec: Add missing deprecation to AVCodecParser.next
The whole old next API has been deprecated in commit
7e8eba2d87, yet deprecating the next
pointer has been forgotten (the next pointers of other structures are
below the public API delimiter, but such a delimiter doesn't exist for
AVCodecParser).

Reviewed-by: James Almer <jamrial@gmail.com>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
2021-02-25 21:51:11 +01:00
James Almer e96ea80e85 avcodec: unschedule removing some functions with FF_API_COPY_CONTEXT
These functions were never deprecated. The merge from commit 6988cf2969
included them by mistake.

Found-by: mkver
Signed-off-by: James Almer <jamrial@gmail.com>
2021-02-25 17:35:13 -03:00
James Almer 7b30dad3a6 avcodec: remove pointless lowres deprecation wrappers
Neither the feature, public fields, or AVOptions were ever truly deprecated,
nor will have been removed if this FF_API_ define was left in place, so
get rid of it as it's misleading.

Signed-off-by: James Almer <jamrial@gmail.com>
2021-02-22 20:50:15 -03:00
Anton Khirnov 9e30859cb6 lavc: shedule old encoding/decoding API for removal
It has been deprecated for 4 years and certain new codecs do not work
with it.

Also include AVCodecContext.refcounted_frames, as it has no effect with
the new API.
2021-01-26 17:05:58 +01:00
James Almer 56709ca8aa avcodec: deprecate AVCodecContext.debug_mv
It's been unused for almost three years now.

Signed-off-by: James Almer <jamrial@gmail.com>
2021-01-25 19:31:04 -03:00