[FFmpeg-devel] [PATCH] lavc: deprecate avcodec_dct, av_fft, av_dct, av_rdft and av_mdct

James Almer jamrial at gmail.com
Sat Feb 18 15:58:46 EET 2023


On 2/18/2023 10:45 AM, Lynne wrote:
> Feb 18, 2023, 14:32 by jamrial at gmail.com:
> 
>> On 2/18/2023 9:49 AM, Lynne wrote:
>>
>>> Feb 17, 2023, 19:45 by dev at lynne.ee:
>>>
>>>> Feb 17, 2023, 18:08 by jamrial at gmail.com:
>>>>
>>>>> On 2/17/2023 1:54 PM, Lynne wrote:
>>>>>
>>>>>> This reverts commit 26cb36f35746fe6ef53688b119852bfa6d555f62.
>>>>>>
>>>>>> All filters and all codecs (except wmavoice) have been ported for the
>>>>>> lavu/tx API.
>>>>>>
>>>>>> The noise should be minimal.
>>>>>>
>>>>>
>>>>> It isn't. I'm getting more than two thousand lines of warnings after applying this patch from
>>>>>
>>>>> libavfilter/vf_spp.c
>>>>> libavfilter/x86/vf_spp.c
>>>>> libavcodec/asvenc.c
>>>>> libavcodec/avdct.c
>>>>> libavcodec/avfft.c
>>>>> libavcodec/dct.c
>>>>> libavcodec/fdctdsp.c
>>>>> libavcodec/fft_float.c
>>>>> libavcodec/fft_init_table.c
>>>>> libavcodec/idctdsp.c
>>>>> libavcodec/jfdctfst.c
>>>>> libavcodec/jfdctint.c
>>>>> libavcodec/jrevdct.c
>>>>> libavcodec/mpegaudiodsp.c
>>>>> libavcodec/mpegvideo_enc.c
>>>>> libavcodec/rdft.c
>>>>> libavcodec/wmavoice.c
>>>>> libavcodec/x86/dct_init.c
>>>>> libavcodec/x86/fft_init.c
>>>>> libavcodec/x86/mpegvideoenc.c
>>>>>
>>>>> It's not just wmavoice, there's also mpeg and jpeg stuff, and one filter. For the actual fft/dct/rdft/mdct source files, you should use the deprecation warning pragmas to silence them, but the other modules need to be ported.
>>>>> This patch is also missing the schedule FF_API deprecation wrapper.
>>>>>
>>>>
>>>> Is the noise acceptable if I just deprecate the functions?
>>>> It wasn't before, but it should be much less now.
>>>>
>>>
>>> Version 2 attached.
>>> Deprecates only the init functions (which must always be used, therefore
>>> the entire API is deprecated).
>>>
>>
>> You should deprecate all the functions, not just the init ones, even if the rest depend on them. And add a "@deprecated use AVTXContext from libavutil/tx.h" line or similar in the doxy for at least the init or alloc functions to point library users to the replacement API.
>>
> 
> Fair enough, deprecated all functions, added disable/enable warnings to tests
> and vf_spp, and added the doxy note.
> Attached v3.

vf_spp should be ported to tx, not the avdct functions silenced. You're 
just scheduling a compilation failure as is.

What is the plan for the internal version of all this lavc code? Is it 
going to be removed and wmavoice/mpegaudiodsp/etc ported to tx? Because 
it depends on structs defined in the public headers you're scheduling to 
be removed.


More information about the ffmpeg-devel mailing list