Jump to content


Photo

H.264 and H.265 transcoding with NVDEC results in green video


  • Please log in to reply
37 replies to this topic

#1 IkeTaylor11 OFFLINE  

IkeTaylor11

    Advanced Member

  • Members
  • 282 posts
  • Local time: 12:11 PM

Posted 09 March 2019 - 02:47 PM

Running beta 4.1.0.13 on a windows server with a GTX 1060 6GB video card. 

 

When transcoding using NVDEC for H.264 and H.265 I am getting green video on playback. If I change transcoding to use DX11VA the video plays fine. 

 

I have attached a video to show whats happening. Let me know what you want for logs. 

Attached Files



#2 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 124007 posts
  • Local time: 01:11 PM

Posted 09 March 2019 - 03:29 PM

Can you install the latest Nvidia drivers and then reboot your machine? Thanks.

#3 IkeTaylor11 OFFLINE  

IkeTaylor11

    Advanced Member

  • Members
  • 282 posts
  • Local time: 12:11 PM

Posted 09 March 2019 - 03:32 PM

Can you install the latest Nvidia drivers and then reboot your machine? Thanks.


Already one the latest version.

419.35 released on 3/5/19


Sent from my iPhone using Tapatalk

#4 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 124007 posts
  • Local time: 01:11 PM

Posted 10 March 2019 - 04:14 PM

Ok, please attach the ffmpeg log from this, thanks.



#5 IkeTaylor11 OFFLINE  

IkeTaylor11

    Advanced Member

  • Members
  • 282 posts
  • Local time: 12:11 PM

Posted 10 March 2019 - 05:36 PM

Ok, please attach the ffmpeg log from this, thanks.

Ok i have attached 2 transcode logs. The green_video_playback log is the one from yesterday where I was getting green video during playback. The software_encode file is from today. I can't get hardware transcoding to work at all today. Its failing and reverting back to software transcoding. I haven't changed anything and have tried rebooting my pc and emby. 

Attached Files



#6 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 124007 posts
  • Local time: 01:11 PM

Posted 10 March 2019 - 05:41 PM

Ok, we'll see what @softworkz thinks. Thanks.



#7 softworkz OFFLINE  

softworkz

    Advanced Member

  • Developers
  • 1274 posts
  • Local time: 07:11 PM

Posted 11 March 2019 - 04:53 PM

Does it work when you disable subtitles?



#8 IkeTaylor11 OFFLINE  

IkeTaylor11

    Advanced Member

  • Members
  • 282 posts
  • Local time: 12:11 PM

Posted 11 March 2019 - 06:35 PM

Does it work when you disable subtitles?

with subtitles on i get full NVDEC transcoding, but the video is green. If I disable subtitles then transcoding cant use NVDEC, it fails and uses software HEVC transcoding. But, with the subtitles off the video looks like it is supposed to. With DX11VA transcoding and subtitles on playback is fine as well. 

 

Seems something is broken with the NVDEC transcoding at the moment. 



#9 densma OFFLINE  

densma

    Advanced Member

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

Posted 13 March 2019 - 09:31 AM

any fix to this? still having same issue and its like nobody cares about it. i see many threads on green video. All the new changes from 4.1.0.8  messed up HW transcoding. I opened  my thread and no more response from emby team. same issue with 4.1.0.14



#10 cayars OFFLINE  

cayars

    Advanced Member

  • Alpha Testers
  • 2705 posts
  • Local time: 01:11 PM

Posted 13 March 2019 - 10:38 AM

Not sure what you mean, nobody cares about it. If you read the forums you'll see this is mentioned and @softworkz has made changes. He is using the beta channel as appropriate to try new HW things and to get things ironed out so that everything works correctly before release of these new things.

The combinations of all these settings needed to work for Intel, AMD & Nvidia is quite a bit and the decision tree logic has got to be tweaked for all the new support he's adding. HW transcoding code is very actively being worked on.

#11 IkeTaylor11 OFFLINE  

IkeTaylor11

    Advanced Member

  • Members
  • 282 posts
  • Local time: 12:11 PM

Posted 14 March 2019 - 09:43 AM

@softworkz I noticed the latest beta has an update for DXVA but not NVDEC. Will you be addressing that issue I am having in the next beta or will I need to continue using DXVA in the long term? 



#12 softworkz OFFLINE  

softworkz

    Advanced Member

  • Developers
  • 1274 posts
  • Local time: 07:11 PM

Posted 16 March 2019 - 10:23 PM

@softworkz I noticed the latest beta has an update for DXVA but not NVDEC. Will you be addressing that issue I am having in the next beta or will I need to continue using DXVA in the long term? 

 

No need to worry- this will be addressed eventually. Due to our recent progress in the area of hw acceleration support, we have approached a level of complexity that there's a need to refactor some of our internal logic to be able to deal with that.

 

Please keep in mind that this is the beta channel. I'd know about at least 2 ways to get this fixed instantly, where one would be  a step back and the other one sidewards at least.

But we want to move forward following a new (and hopefully bettter) way, even if it might be a little painful at the beginning...


  • TomTiddler and IkeTaylor11 like this

#13 RanmaCanada ONLINE  

RanmaCanada

    Advanced Member

  • Members
  • 258 posts
  • Local time: 01:11 PM

Posted 17 March 2019 - 12:41 PM

No need to worry- this will be addressed eventually. Due to our recent progress in the area of hw acceleration support, we have approached a level of complexity that there's a need to refactor some of our internal logic to be able to deal with that.

 

Please keep in mind that this is the beta channel. I'd know about at least 2 ways to get this fixed instantly, where one would be  a step back and the other one sidewards at least.

But we want to move forward following a new (and hopefully bettter) way, even if it might be a little painful at the beginning...

Well those of us using beta know there will be pain :)  Again this is a great reason as to why everyone should have devices that direct play haha.

 

Your hard work is greatly appreciated, and when it's fixed, it's fixed.



#14 IkeTaylor11 OFFLINE  

IkeTaylor11

    Advanced Member

  • Members
  • 282 posts
  • Local time: 12:11 PM

Posted 17 March 2019 - 12:47 PM

Well those of us using beta know there will be pain :) Again this is a great reason as to why everyone should have devices that direct play haha.

Your hard work is greatly appreciated, and when it's fixed, it's fixed.


Can’t direct play 4K 10bit over the internet to 3 different uses with a 20Mbps upload speed. No choice but to transcode.

And I brought it up in case the issue wasn’t known.


Sent from my iPhone using Tapatalk

#15 RanmaCanada ONLINE  

RanmaCanada

    Advanced Member

  • Members
  • 258 posts
  • Local time: 01:11 PM

Posted 17 March 2019 - 05:50 PM

Can’t direct play 4K 10bit over the internet to 3 different uses with a 20Mbps upload speed. No choice but to transcode.

And I brought it up in case the issue wasn’t known.


Sent from my iPhone using Tapatalk

The go the other route, either get PSA encodes 4k rips..which is piracy, or tell them to buy hard drives!  I am finding that with 4k streaming, only local works well, and over the internet has serious issues with buffering.  I have 200mbit, and I can't even stream a 4k movie to my friend who lives 5 minutes away and they have 600mbit service.  Every 5 minutes it buffers and buffers.  They spent $100 bucks on a 4TB portable HD, and problem is now solved. :)  I will be doing this with everyone who wants access to my 4k, as it makes life easier for everyone.  Not everyone has 4k capable TVs in my user list.  They want to play the game, pay the price :)

 

Yes I know this is not ideal, but seriously, we have to make our own solutions for these types of problems.  Besides, transcoding 4k makes it look like a bandwidth starved piece of crap haha, not to mention the tone mapping problems.



#16 IkeTaylor11 OFFLINE  

IkeTaylor11

    Advanced Member

  • Members
  • 282 posts
  • Local time: 12:11 PM

Posted 17 March 2019 - 05:58 PM

The go the other route, either get PSA encodes 4k rips..which is piracy, or tell them to buy hard drives! I am finding that with 4k streaming, only local works well, and over the internet has serious issues with buffering. I have 200mbit, and I can't even stream a 4k movie to my friend who lives 5 minutes away and they have 600mbit service. Every 5 minutes it buffers and buffers. They spent $100 bucks on a 4TB portable HD, and problem is now solved. :) I will be doing this with everyone who wants access to my 4k, as it makes life easier for everyone. Not everyone has 4k capable TVs in my user list. They want to play the game, pay the price :)

Yes I know this is not ideal, but seriously, we have to make our own solutions for these types of problems. Besides, transcoding 4k makes it look like a bandwidth starved piece of crap haha, not to mention the tone mapping problems.


Sounds like you need to invest in better equipment. I have no issues transcoding 4K using software or even DXVA. The issue is with NDVEC which is why this thread is open. Unless you have something to add to this particular issue it’s best you start a different thread for your issue.


Sent from my iPhone using Tapatalk

#17 softworkz OFFLINE  

softworkz

    Advanced Member

  • Developers
  • 1274 posts
  • Local time: 07:11 PM

Posted 18 March 2019 - 10:09 PM

Thanks for your patience!

 

The green video appearance when doing (graphical) subtitle burn-in should be fixed in the next beta (preliminary at least).

 

Please check and report back...

 

Thanks.


  • cayars likes this

#18 IkeTaylor11 OFFLINE  

IkeTaylor11

    Advanced Member

  • Members
  • 282 posts
  • Local time: 12:11 PM

Posted 18 March 2019 - 10:12 PM

Thanks for your patience!

The green video appearance when doing (graphical) subtitle burn-in should be fixed in the next beta (preliminary at least).

Please check and report back...

Thanks.


Ok I will let you know. The other part of the issue is 10bit media I believe. Most of my 4K is 10bit and the NVDEC decoders fails to software. I think I read somewhere that you guys don’t support 10bit transcoding yet. Is that true? If so, will that be coming in the near future as well?


Sent from my iPhone using Tapatalk

#19 cayars OFFLINE  

cayars

    Advanced Member

  • Alpha Testers
  • 2705 posts
  • Local time: 01:11 PM

Posted 18 March 2019 - 11:02 PM

Ok I will let you know. The other part of the issue is 10bit media I believe. Most of my 4K is 10bit and the NVDEC decoders fails to software. I think I read somewhere that you guys don’t support 10bit transcoding yet. Is that true? If so, will that be coming in the near future as well?


Sent from my iPhone using Tapatalk

 

I'll save softworkz from having to answer this since he gave a thorough explanation over here:

https://emby.media/c...stion/?p=717393


  • softworkz likes this

#20 softworkz OFFLINE  

softworkz

    Advanced Member

  • Developers
  • 1274 posts
  • Local time: 07:11 PM

Posted 18 March 2019 - 11:02 PM

I'm reposting here what I've written in another thread:

Let me put it like that: 10bit videos are neither unsupported nor explicitly supported.
 
There are several levels of support when you try to play a 10 bit video:

  • For hardware decoding, it's usually just the more recent models that support HEVB 10 bit decoding
  • Generally, decoding itself isn't a problem, because at least it will be done in software
  • All decoders will produce a 10bit uncompressed video stream internally for further processing
  • But from then on, there are several ways how this can end
    • If there's some processing to be done (scaling, deinterlacing, subtitle burn-in), the video
      MAY or MAY NOT be automatically converted to 8bit colors (which is not a good thing, see below, "washed-out-colors")
      (that depends on the individual filters  being used for this and whether they can handle 10 bit or not)
      .
    • When it comes to encoding then, the video will have either
      • 8 bit => All encoders will be able to handle that, but the colors have been clipped to 8bit and will often appear as "washed-out"".
        .
      • 10 bit => What happens here depends on the selected encoder. Generally, only the more recent graphics hardware supports 10bit encoding
  • If the encoder doesn't support it, it will fail
  • This is a rough description of the current state.
    Please note, that many hardware accelerations are supporting HEVC decoding but not encoding.
     
     
    "Washed-out-Colors"
     
    When converting 10 bit colors to 8 bit colors, it's obvious that some information will get lost. 
    The whole point off using HDR is to be able to increase the dynamic range of color values.
     
    But all this does only make sense if  you really own some display that is capable of displaying HDR videos.
     
    If you don't - don't acquire HDR videos at all.
    Of course in general, it's a good idea to acquire content in the best possible format, but in case of HDR it will be a constant source of trouble (unless you really require that) 
     
    Because:
    • On the fly color conversions will just truncate or dither.
      The result will be a lot worse than the originally released 8 bit version.
      .
    • The "right" way to handle 10 bit > 8 bit color conversion is to use a "tone-mapping filter.
      As opposed to the simple "truncate/drop" conversion, this will dynamically determine the required color range projections based on the relative and time-local intensity.
      .
    • Most hardware accelerations don't offer a tone-mapping.filter.
      That means, for doing tone mapping, we'll need to copy the video data back from the hw decoder to system memory, execute the tone-mapping on the CPU and afterwards transfer everything back to GPU memory again.
    Conclusion: We're constantly improving this, but at the moment I wouldn't recommend acquiring 10 bit color videos unless you really want/need it.
     
     
    I hope I won't be misunderstood, though: It's not that Emby doesn't support it or won't  support it.
    • Next step will be to properly support simple (truncating) conversions.
      .
    • Then we will try to manage tone-mapping as good as possible
    But even at that point:
    • 8bit converted results may be worse than the original 8 bit material
      .
    • Transcodings will require CPU resources and cannot be performed by the graphics hardware alone
    Again: Use 10 bit videos only when you have a specific reason. Don't assume that it would be better. In most cases it's worse instead.

  • cayars likes this




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users