Jump to content

GPU Transcoding (Intel QuickSync and nVidia NVENC)


witteschnitte

Recommended Posts

Hi Pappaq,

 

It's not just you, who are limited on geek funds. I think most of us are dreaming of better gear than we have standing at home. Fortunately, dreaming is free of charge, while we learn from people who invest more time and money than you and me. 

 

There's still hope, until the day we loose the ability to day-dream. 

  • Like 2
Link to comment
Share on other sites

I just saw the price of the 1950x thread-ripper.  :(

It's one wild chip, but so is the price-tag. Waaaaayyyyyyyyyyyyyyyyyyyy out of my budget.  :o

Link to comment
Share on other sites

Possible transcoding or web player issue found:

 

I had a stream in full-screen web player. (not on the same pc as the server, client running win7).

Then I tried going back and changing channel.

It caused the "loading" ring to cycle endlessly (at least beyond my patience) :)

 

It happened in full-screen mode, but after closing the web interface completely, and restarting the session, both worked fine when normal "windowed" mode (not full-screen).

 

Can others please check if they get the same, or if it was just on my setup?

Link to comment
Share on other sites

I was looking at CPUs (cool) and at their prices (not so cool).

 

Compared to my present i7 870k, the Ryzen 1700 or 1700x would be a massive improvement.

 

Interestingly enough, it lseems that viewing TV on the server using Emby Theater uses less CPU than web viewer for the same transcoded live tv.

I can use bitrates in Theater that I couldn't in web viewer without stutter. Hopefullt this is addressed in the next release (the beta notes indicate it might be solved).

Link to comment
Share on other sites

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. :)

Link to comment
Share on other sites

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.

Link to comment
Share on other sites

Jennice

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.net/reviews/tech/amd-ryzen-1800x-and-am4-platform-review/5/

Edited by Jennice
Link to comment
Share on other sites

  • 2 weeks later...
anthonws

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.

Link to comment
Share on other sites

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.

Link to comment
Share on other sites

Jennice

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

Link to comment
Share on other sites

Guest asrequested

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.

Link to comment
Share on other sites

anthonws

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.

Link to comment
Share on other sites

Guest asrequested

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.

Link to comment
Share on other sites

anthonws

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

 

Link to comment
Share on other sites

Guest asrequested

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.

Link to comment
Share on other sites

anthonws

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
Link to comment
Share on other sites

Guest asrequested

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.

  • Like 1
Link to comment
Share on other sites

Waldonnis

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).

  • Like 1
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...