Jump to content


Photo

GPU Transcoding (Intel QuickSync and nVidia NVENC)

GPU quicksync transcoding hardware acceleration

  • Please log in to reply
1453 replies to this topic

#1281 Doofus ONLINE  

Doofus

    Advanced Member

  • Members
  • 12242 posts
  • Local time: 09:16 AM

Posted 29 September 2017 - 08:07 PM

Since the Ryzen is fairly new you should compare it to the new i9's. :blink:


Mo munee but seems comparative in performance.

http://cpu.userbench...920X/3936vs3934

#1282 Jennice OFFLINE  

Jennice

    Advanced Member

  • Members
  • 269 posts
  • Local time: 05:16 PM

Posted 30 September 2017 - 01:40 AM

Well, I tried to compare math-per-money.

 

Here in Denmark, the Ryzen 1700 is approximately the same price as the i7-7700, and the 1700x roughly costs the same as i7-7700k.

 

On average, Ryzen 1700 and i7-7700 seem comparable for gaming ans various tasks. But for raw math power like transcoding, the Ryzen seems significantly faster.

 

That's around my budget range, given that I also need all the rest of a pc.

 

Speaking of which...the Ryzen doesn't have iGPU. The cost of a low'ish end GPU should be added, to make a fair comparison and build budget.

Then again, a fanless GT710 card IS very cheap. It's crap by todays standards, but I just need it to install the pc and start Emby server. :)



#1283 Jennice OFFLINE  

Jennice

    Advanced Member

  • Members
  • 269 posts
  • Local time: 05:16 PM

Posted 30 September 2017 - 01:42 AM

Are there any Ryzen 7 users who can confirm that Emby / ffmpeg actually utilizes all the cores and the CPU math power for transcoding?



#1284 pappaq OFFLINE  

pappaq

    Advanced Member

  • Members
  • 77 posts
  • Local time: 06:16 PM

Posted 02 October 2017 - 08:54 AM

Are there any Ryzen 7 users who can confirm that Emby / ffmpeg actually utilizes all the cores and the CPU math power for transcoding?

I don't know, why it shouldn't.



#1285 Jennice OFFLINE  

Jennice

    Advanced Member

  • Members
  • 269 posts
  • Local time: 05:16 PM

Posted 02 October 2017 - 09:49 AM

I don't know, why it shouldn't.

 

Inspired by this forum, I looked a comparative tests between intel and AMD, and in some graphics tool tests, it seemed that the rendering packages didn't use all cores/threads, as they did on intel chips. Therefore I am interested in any real-life use scenarios with Ryzen and ffmpeg.

 

This test doesn't seem to like Ryzen compared to intel in the ffmpeg driven test:

https://www.bit-tech...tform-review/5/


Edited by Jennice, 02 October 2017 - 09:53 AM.


#1286 pappaq OFFLINE  

pappaq

    Advanced Member

  • Members
  • 77 posts
  • Local time: 06:16 PM

Posted 02 October 2017 - 02:17 PM

Has anyone a Xeon 1230v1 and could give some intel about the transcoding performance?



#1287 Doofus ONLINE  

Doofus

    Advanced Member

  • Members
  • 12242 posts
  • Local time: 09:16 AM

Posted 02 October 2017 - 03:15 PM

Has anyone a Xeon 1230v1 and could give some intel about the transcoding performance?


You may want to ask that here, as you're not asking about nvenc or quicsync

https://emby.media/c...ocessing/page-1
  • pappaq likes this

#1288 anthonws OFFLINE  

anthonws

    Advanced Member

  • Members
  • 51 posts
  • Local time: 05:16 PM

Posted 17 October 2017 - 07:39 AM

Is anyone using a dual GPU setup?

 

I'm currently using a Nvidia GTX 760 as the main GPU and also have enabled the Intel HD 4600. When selecting "Intel Quick Sync" I cannot transcode media.

 

Looking into ffmep transcode logs there's the following error:

 

"[AVHWDeviceContext @ 0000000004acf280] Error setting child device handle: -16".

 

Is this supported?

 

Cheers,

anthonws.



#1289 libnc OFFLINE  

libnc

    Member

  • Members
  • 11 posts
  • Local time: 06:16 PM

Posted 22 October 2017 - 12:22 PM

Did you have a build and a general architecture supportin quick sync?
I suppose not.



#1290 lorac OFFLINE  

lorac

    Advanced Member

  • Members
  • 409 posts
  • Local time: 09:16 AM
  • LocationVancouver, Canada

Posted 22 October 2017 - 03:04 PM

For QSV you'd need your monitor to be connected to the Intel GPU. There may be workarounds. Perhaps try booting with the Intel GPU, confirm it is working, swap GPU and see if it still works.



#1291 Jennice OFFLINE  

Jennice

    Advanced Member

  • Members
  • 269 posts
  • Local time: 05:16 PM

Posted 23 October 2017 - 12:45 AM

Hmmm... If true, that might explain why I didn't see any advantage from trying QS video transcode on my i7-3770k.

The monitor is on my GTX 970 GPU.

 

I don't see why a connected monitor would make a difference for transcode (for remote streaming) though?

 

Jennice



#1292 Doofus ONLINE  

Doofus

    Advanced Member

  • Members
  • 12242 posts
  • Local time: 09:16 AM

Posted 23 October 2017 - 01:35 AM

For QSV you'd need your monitor to be connected to the Intel GPU. There may be workarounds. Perhaps try booting with the Intel GPU, confirm it is working, swap GPU and see if it still works.

 

For server QS transcoding, you don't need to do that. Some of these guys run a headless server and use QuickSync. I've tested, and can confirm that Luke has worked his magic, and it doesn't require a display.



#1293 anthonws OFFLINE  

anthonws

    Advanced Member

  • Members
  • 51 posts
  • Local time: 05:16 PM

Posted 23 October 2017 - 03:31 AM

Did you have a build and a general architecture supportin quick sync?
I suppose not.

 

Yes. I've tested Quick Sync before in my setup, and it works.

 

For QSV you'd need your monitor to be connected to the Intel GPU. There may be workarounds. Perhaps try booting with the Intel GPU, confirm it is working, swap GPU and see if it still works.

 

That might explain things. Although I am able to use Intel iGPU to other things like Hyper-V Hypervisor (RemoteFX).

 

For server QS transcoding, you don't need to do that. Some of these guys run a headless server and use QuickSync. I've tested, and can confirm that Luke has worked his magic, and it doesn't require a display.

 

That might be the case where there's only 1 GPU. Not sure when there's 2 GPUs and Intel iGPU is not connected to a display.

 

I can run more tests, but the error log that I shared seems pretty obvious to me.

 

Cheers,

anthonws.



#1294 Doofus ONLINE  

Doofus

    Advanced Member

  • Members
  • 12242 posts
  • Local time: 09:16 AM

Posted 23 October 2017 - 01:44 PM

Being able to have two different GPUs will be dependent on your motherboard, I would think. I doubt that you can do it. I've not seen a case where it's been achieved.

#1295 anthonws OFFLINE  

anthonws

    Advanced Member

  • Members
  • 51 posts
  • Local time: 05:16 PM

Posted 23 October 2017 - 02:14 PM

Being able to have two different GPUs will be dependent on your motherboard, I would think. I doubt that you can do it. I've not seen a case where it's been achieved.

 

I can. I am doing it right now. That is not the point.

 

My OS is capable of using both GPU's, hence the question regarding Emby support.

 

59ee317a1bb9b_two_gpus.png

 



#1296 Doofus ONLINE  

Doofus

    Advanced Member

  • Members
  • 12242 posts
  • Local time: 09:16 AM

Posted 23 October 2017 - 02:23 PM

Ah, well then I don't know. I think Luke may be the one to answer that. I will add that your iGPU isn't capable of much. Ffmpeg may also not be supporting it very much.

Well done, though.

#1297 anthonws OFFLINE  

anthonws

    Advanced Member

  • Members
  • 51 posts
  • Local time: 05:16 PM

Posted 23 October 2017 - 02:33 PM

Ah, well then I don't know. I think Luke may be the one to answer that. I will add that your iGPU isn't capable of much. Ffmpeg may also not be supporting it very much.

Well done, though.

 

My iGPU supports VideoDecode just fine. I've used it in the past with Plex and Emby.

 

The problem is most definitely related to the fact that since it's not the main GPU, ffmpeg cannot "see it" or request it. Thus the "[AVHWDeviceContext @ 0000000004acf280] Error setting child device handle: -16".

 

My intention was simple: workload segregation. Although it's my NAS/Hyper-V/Media server, it's also the machine I'm using for Web/Labs/Tests/Casual Gaming, which means that UI rendering is targeting GPU 1 (Nvidia). That's why I would like to offload to GPU 0 (Intel) for Transcoding.

 

Since I can use GPU 0 (Intel) in Hyper-V for Remote FX, I'm sure there's a way to actually open a handle to that device. Not sure is if ffmpeg and/or Emby are built to handle these type of scenarios.

 

Cheers,

anthonws.

 

Edit:

 

Could it be that the issue is due to the handle being created through D3D9 API/DevManager? And since DirectX only reports the main GPU, attached to the HDMI monitor, it cannot open that handle? 


Edited by anthonws, 23 October 2017 - 02:48 PM.


#1298 Doofus ONLINE  

Doofus

    Advanced Member

  • Members
  • 12242 posts
  • Local time: 09:16 AM

Posted 23 October 2017 - 02:48 PM

I didn't say it couldn't do anything, just that it can't do much. And decoding isn't the problem you'd have, it would be encoding. It can't do much even if you could get Ffmpeg to see it. I used to have one of those. It's too old, now. Tech has moved on. I think you're going down a rabbit hole, to find something that would cause you even more problems. Others on here with the same iGPU have reported problems and have disabled it.
  • anthonws likes this

#1299 Waldonnis OFFLINE  

Waldonnis

    Advanced Member

  • Members
  • 652 posts
  • Local time: 12:16 PM

Posted 29 October 2017 - 03:54 PM

Could it be that the issue is due to the handle being created through D3D9 API/DevManager? And since DirectX only reports the main GPU, attached to the HDMI monitor, it cannot open that handle? 

 

The handle is being created via d3d9 (or d3d11va).  In fact, I've been digging again into why using qsv for both decoding and encoding causes the encoder to swap to hybrid (software) encoding speeds.  So far, it seems that ffmpeg is using dxva2 or vaapi for qsv decoding, so specifying the input decoder specifically as a _qsv variant on a multi-GPU system may not "work" (since the context may be created for the dGPU's dxva2 device instead of the iGPU's).  It seems the only reliable way out of hybrid encoding hell is to use the dxva2 hwaccel, but that never seemed to work right with Emby.

 

I have only done a cursory look at the init code, so I may be wrong about that, but it explains ffmpeg's odd behaviour on my system (GTX-970 is primary card, iGPU connected to a television or dummy display depending on the day).  I'm not sure how it would behave in a VM situation, since I just don't know how much the various VM implementations expose driver- and hardware-wise.  In a non-VM setup, it's entirely possible to use qsv even when the iGPU is not connected as long as it's a recognised device by Windows (usually just need to "detect" monitors to create a dummy display and specify that it's connected to the iGPU; lots of various how-tos around the net about how to do that for Handbrake, but the same applies here).


  • anthonws likes this

#1300 Doofus ONLINE  

Doofus

    Advanced Member

  • Members
  • 12242 posts
  • Local time: 09:16 AM

Posted 29 October 2017 - 04:18 PM

I'm not sure if this is applicable, but we've just discovered that dxva2 no longer works in mpv. It's apparently not used much, anymore. It's being retired.

 

https://github.com/m...fc77a5a7a0f0b29


  • anthonws likes this





Also tagged with one or more of these keywords: GPU, quicksync, transcoding, hardware acceleration

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users