[FFmpeg-user] FFMPEG GPU Flags being confused.

Jamie Whittingham jamie.whittingham at gmail.com
Mon Mar 25 12:35:43 EET 2019


Hi everyone. First time caller, long time listener. (always wanted to say
that - such a 90s kid lol)

I'm decoding, then encoding a .ts stream (please see the following command)

/root/ffmpeg_sources/ffmpeg/ffmpeg -hide_banner -hwaccel cuvid -i '
http://server/file.ts' -s 1280x720 -c:a aac -tune zerolatency -c:v
h264_nvenc -b:v 1600k -gpu 1 -f flv rtmp://localhost/show/test_stream

Now this works really nicely however the GPU 0 AND GPU 1 are being used.

As you can see I set "-gpu 1" for the decode and then again for the encode
but it still uses both GPUs

Screenshot = /root/ffmpeg_sources/ffmpeg/ffmpeg -hide_banner -hwaccel cuvid
-i 'http://iptv.genexnetworks.net:10810/live/jamie/M!mi1372/107.ts' -s
1280x720 -c:a aac -tune zerolatency -c:v h264_nvenc -b:v 1600k -gpu 1 -f
flv rtmp://localhost/show/sony_crime_sd

I just removed the -gpu flag from the encode and it ignore the -gpu before
the imput flag.

Only setting -gpu 1 for the encode option and NOT giving a gpu for the
decode results in decode on gpu 0 and encode on gpu 1

Could someone please point me in the right direction please so only 1 GPU
is used.

If I dont use the gpu flag then it defaults to gpu0 and doesnt touch gpu1.

thanks
*Jamie Whittingham*
CTO | Lead Programmer - Genex Networks LLC
UK Office ☎ +44 7399 973949
jamie at genexnetworks.net
www.genexnetworks.net


More information about the ffmpeg-user mailing list