Jump to content

Quick Sync crashes ffmpeg


Ceth

Recommended Posts

babgvant

If I understand what you are saying, QSTranscode can't do fallback if QS hardware doesn't exist?  If that's the case, it would only be a matter of allowing the user to choose the QS profile (hardware) or the ffmpeg profile (generic) when configuring Emby server.  This is how it is set up now, except with QSV specific parameters sent to ffmpeg.

 

QSTranscode can decode QS unsupported video codecs using ffmpeg, but it will only VPP & encode using QS HW. The problem is that you need to build all the logic into Emby to know what formats are supported by which transcoder. Obviously this is possible, but with all the other development objectives around it's probably not the best use of resources with better support for QS in ffmpeg finally materializing.

Link to comment
Share on other sites

Sorry if this sounds naive, but couldn't you set up a QSV profile to use ffmpeg to decode (with whatever QSV options it supports) and then pipe the output through to QSTranscode for encoding?  That way, no special logic is required:  it always use ffmpeg for decode, and it always uses QSTranscode for encode.

 

Whereas the generic profile would only use ffmpeg from start to finish?

Link to comment
Share on other sites

babgvant

Piping decoded frames from ffmpeg to QSTranscode (if it supported this) would require a GPU->system RAM copy so you'd loose most of the benefit from using QSTranscode in the first place.

 

Either way, Emby would have to be altered to branch internally to do it different ways for different content. If we hit a deadend with ffmpeg progress it might make sense to do something like this, but for now it's better to wait and add value in other ways than to try to rig up a Goldberg Machine that will only work on Windows and could need to be ripped out in the future.

 

If I find the time to add non-QS encoding support (VP8 at minimum), it might also make sense to revisit this.

Link to comment
Share on other sites

QSTranscode can decode QS unsupported video codecs using ffmpeg, but it will only VPP & encode using QS HW. The problem is that you need to build all the logic into Emby to know what formats are supported by which transcoder. Obviously this is possible, but with all the other development objectives around it's probably not the best use of resources with better support for QS in ffmpeg finally materializing.

Ah we want you to duplicate ffmpeg ;)

 

But seriously maybe there are one or two specific use cases for QSTranscode. LiveTV from the HDHomerun. is a known enity and comes to mind.

 

I don't know if it is worth the effort for just a couple of transcode profiles, but it is a thought.

 

Thanks again for your work so far. Just so I understand the piece from Ffmpeg we need is the 264 encode.

 

Stream mapping:

  Stream #0:0 -> #0:0 (mpeg2video (mpeg2_qsv) -> h264 (libx264))

  Stream #0:1 -> #0:1 (ac3 (native) -> ac3 (native))

 

Can the audio just be a "copy" or does that mess things up?

 

Thanks

Edited by Vicpa
Link to comment
Share on other sites

babgvant
But seriously maybe there are one or two specific use cases for QSTranscode. LiveTV from the HDHomerun. is a known enity and comes to mind.

 

I don't know if it is worth the effort for just a couple of transcode profiles, but it is a thought.

 

Thanks again for your work so far. Just so I understand the piece from Ffmpeg we need is the 264 encode.

 

Stream mapping:

  Stream #0:0 -> #0:0 (mpeg2video (mpeg2_qsv) -> h264 (libx264))

  Stream #0:1 -> #0:1 (ac3 (native) -> ac3 (native))

 

Can the audio just be a "copy" or does that mess things up?

 

Thanks

 

Ffmpeg currently supports QSV encode and decode, the problem is that it has a deadlock issue when VPP is introduced (I've bugged this and AFAIK they are looking into it). Once that is fixed, while it won't be as efficient as QSTranscode for this sort of thing, it should be good enough.

 

That reminds me. I need to bug @@Luke about a patch I submitted to do stream detection on Live TV streams (QSV won't work for LiveTV in the UK otherwise).

  • Like 1
Link to comment
Share on other sites

babgvant

we already probe live tv for the built-in emby tv

 

Interesting. I'll have another look, when I was messing around with this it wasn't (and was forcing a MPG2 profile).

Link to comment
Share on other sites

babgvant

Hi

 

No clue what vpp is, but is this it?

 

Re: [FFmpeg-devel] [PATCH] Added QSV based VPP filter

 

Awesome!

 

Video Post Processing: basically any processing that changes the decoded frames before rendering. The most important are deinterlacing and scaling (resizing the image), but it can also include sharpening (bleh) or altering the color profile (blehx2).

  • Like 1
Link to comment
Share on other sites

Bigjohns97

we already probe live tv for the built-in emby tv

Since this is mostly what i use transcode for, I guess it's time to "upgrade" from my ceton to an HDHR

Link to comment
Share on other sites

I would just like to say I was getting the [h264_qsv @ 00000000004f6ee0] Error initializing an internal MFX session. I checked the registry and the Dispatch key was present.

 

I then downloaded the Intel Media SDK from the Intel site and installed it but still got the problem. However, I noticed the path in the Dispatch key had not been changed to the install location of the new Media SDK. I changed this and it now works.

 

Not sure if this was the correct thing to do, but hopefully it might help!

 

EDIT: I realised the error in this. The Indie Media SDK only include the software version of the driver, not the hardware. So by pointing at the new file I was pointing at the software one. So whilst this work, you don't actually get any benefit of the hardware driver. Sorry! Also explains why I didn't really see any improvement...

Edited by mattm
  • Like 2
Link to comment
Share on other sites

  • 3 weeks later...
wehavetogoback

Could VLC be an alternative?  The 32 Bit version supports Quick Sync, and just about every format imaginable.

i'm surprised that even all this time, there is no momentum towards proper quicksync transcoding support for android compatible stuff.

Iphones have had airvideo hd working perfectly with the help of vlc quick sync for the past who knows how long. even though the feature is "experimental", airvideo hd works flawlessly on my old iphone and my intelhd3000 is happy doing the grunt work leaving my cpu cool and quiet.  

I, unfortunately, had to change phone service and buy an android phone because I'm currently poor and now I can't find a proper application that can do what airvideo does for the iphone. 

 

i wonder why they can't incorporate vlc with emby like airvideo hd.

Edited by wehavetogoback
Link to comment
Share on other sites

dark_slayer

all of our android apps embed libVlc for video playback.

They were referring to an alternative server option for iPhones that uses vlc quick sync server side
Link to comment
Share on other sites

  • 3 weeks later...

Hi guys,

 

I am very new to emby so if it seem I am asking a very stupid question please forgive me lol.

 

I been trying to read up on posts regarding quick sync as I am having issue with that.

I am unable to play any of my mkv file if I turn on Hardware acceleration, however if i turn this option off then everything would be fine.

and after reading this post it seem the issue is with ffmpeg, could some pls tell me if I am having this issue (refer to attached logs).

 

if the issue is with ffmpeg does it mean at the moment there isnt anything I could do about it?

 

Thanks in advance.

 

server.txt

tanscode.txt

Link to comment
Share on other sites

Hi, welcome. I think right now we're still learning about the various conditions in which it works and doesn't work. I would make sure you have up to date video drivers. Barring that, if researching this isn't something you're able to help with, then I would just turn it off for now.

Link to comment
Share on other sites

Hey Luke, thanks for the feedback, I have already update my CPU driver but still unable to get it to work, I guess I need to turn off the function for now.

 

Hope the dev have an idea what is causing the issue and a fix is on the way

 

 

 

Sent from my iPhone using Tapatalk

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