[FFmpeg-devel] [PATCH v2] lavfi: add nlmeans CUDA filter

Timo Rothenpieler timo at rothenpieler.org
Sat Sep 4 13:42:57 EEST 2021


On 04.09.2021 22:03, Dylan Fernando wrote:
> On Thu, Sep 2, 2021 at 4:25 PM Timo Rothenpieler <timo at rothenpieler.org>
> wrote:
> 
>> On 02.09.2021 15:32, Timo Rothenpieler wrote:
>>> On 02.09.2021 19:50, Dylan Fernando wrote:
>>>> I want to add support for the other formats, but I'm not sure how to
>> find
>>>> video files to test it out. I tried looking through
>>>> https://samples.ffmpeg.org/, but I'm not sure which files on there are
>>>> the
>>>> formats im looking for (AV_PIX_FMT_YUV420P, AV_PIX_FMT_YUV444P,
>>>> AV_PIX_FMT_P010, AV_PIX_FMT_P016, AV_PIX_FMT_YUV444P16).
>>>
>>> Just slap a format_cuda filter in front and convert to the desired
>> format.
>>> For RGB formats, which it doesn't support right now, just use
>>> format,hwupload_cuda.
>>
>> sorry, scale_cuda or format+hwupload
>> _______________________________________________
>> ffmpeg-devel mailing list
>> ffmpeg-devel at ffmpeg.org
>> https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
>>
>> To unsubscribe, visit link above, or email
>> ffmpeg-devel-request at ffmpeg.org with subject "unsubscribe".
>>
> 
> Thanks, I have yuv420p and yuv444p working now.
> 
> For P010, I tried using:
> ffmpeg -loglevel debug -v verbose -hwaccel cuda -hwaccel_output_format cuda
> -i noise.mp4 -vf format=p010,hwupload,nlmeans_cuda=20,hwdownload nlmeans.mp4
> 
> and I get:
> [Parsed_format_0 @ 0x558bf0ff6bc0] auto-inserting filter 'auto_scale_0'
> between the filter 'graph 0 input from stream 0:0' and the filter
> 'Parsed_format_0'
> Impossible to convert between the formats supported by the filter 'graph 0
> input from stream 0:0' and the filter 'auto_scale_0'
> 
> Segmentation fault (core dumped)

you're trying to hwupload something that already is uploaded by the decoder.
Either use scale_cuda for the conversion, or don't have the decoder 
output CUDA frames.

The segfault is a bit unexpected though. Can you get a backtrace?
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 4494 bytes
Desc: S/MIME Cryptographic Signature
URL: <https://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20210904/71a54a38/attachment.bin>


More information about the ffmpeg-devel mailing list