[FFmpeg-user] Error:Impossible to convert between the formats supported by the filter..

tasos tasoss at trigonongroup.com
Tue Jul 25 00:57:28 EEST 2017


Hello and thanks for replying.
Your information is very useful and i thank you!
My colleague uses an older version of ffmpeg and the specific 
combination (including pix_fmt)
> ffmpeg -y -hwaccel cuvid    -c:v h264_cuvid
works without any errors.That was my question.I thought i was doing
something wrong or whatever.So i suppose that something has changed
from his version until mine(git latest).
So i have removed -pix_fmt yuv420p and everything works fine.
I also would like to search about the hwdownload option you have entered.
I don't want to change the pixel format(i don't know why you have 
thought about it).

Is this the correct way to go?
> ffmpeg -y -hwaccel cuvid -c:v h264_cuvid -deint 1 -vsync 1 -timeout 
> 999999 -i foo \
> -map 0:v -c:v h264_nvenc -preset slow -profile:v high -b:v 1300k  -map 
> 0:a:0 -c:a libfdk_aac -ac 2 -b:a 64k -strict experimental  \
> -f flv bar

Thanks again for your reply it was very useful and answered my question :)

On 7/25/2017 12:11 AM, James Girotti wrote:
> On Mon, Jul 24, 2017 at 11:15 AM, tasos <tasoss at trigonongroup.com> wrote:
>
>> Hello.
>> I'm using
>>
>>> ffmpeg -y  -c:v h264_cuvid -deint 1 -vsync 1 -timeout 999999 -i foo \
>>> -map 0:v -c:v h264_nvenc -preset slow -profile:v high -b:v 1300k -pix_fmt
>>> yuv420p -map 0:a -c:a libfdk_aac \
>>> -ac 2 -b:a 64k -strict experimental -f mpegts foobar
>>>
>> and everything works fine.
>> When i add -hwaccel cuvid
>>
>> ffmpeg -y -hwaccel cuvid     -c:v h264_cuvid ...... the same as above
>> I get
>>
>>> Impossible to convert between the formats supported by the filter
>>> 'Parsed_null_0' and the filter 'auto_scaler_0'
>>> Error reinitializing filters!
>>> Failed to inject frame into filter network: Function not implemented
>>> Error while processing the decoded data for stream #0:4
>>>
> I have run into the same many times trying to do stuff with nvenc and
> hwaccel. You're trying to apply a software filter, but you're telling
> ffmpeg to do everything in hardware (-hwaccel), so it cannot apply the
> filter hence the error. Doesn't matter though, as from what I can tell
> nvenc will not change pixel formats for you. Your source is yuv420p, output
> will be yuv420p. If you want to change output pixel format to yuv444p, you
> could do something like:
>
> ffmpeg -hwaccel cuvid -c:v h264_cuvid -i foo -c:v h264_nvenc -preset slow
> -profile:v high444p \
> -vf "hwdownload,format=nv12,format=yuv444p,hwupload_cuda" -an -f mpegts
> ./foobar.ts
>
> This would do the pixel format conversion in software (you could do the
> same for any software filter you might want to use). Nvenc then outputs in
> yuv444p pixel format.
>
> Of course if you convert to anything but yuv420p, then decoding with cuvid
> will not work because only yuv420p is supported in hardware.
> https://developer.nvidia.com/nvidia-video-codec-sdk#NVDECFeatures
>
> HTH,
> -James
> _______________________________________________
> ffmpeg-user mailing list
> ffmpeg-user at ffmpeg.org
> http://ffmpeg.org/mailman/listinfo/ffmpeg-user
>
> To unsubscribe, visit link above, or email
> ffmpeg-user-request at ffmpeg.org with subject "unsubscribe".




More information about the ffmpeg-user mailing list