Jump to content


Photo
- - - - -

Unable to Direct Play via Chrome Web Client - "Unknown Profile"

Transcoding Direct Play Chrome

  • Please log in to reply
13 replies to this topic

#1 Douglas_D OFFLINE  

Douglas_D

    Member

  • Members
  • 20 posts
  • Local time: 03:22 PM

Posted 09 December 2015 - 12:27 PM

Hi All.  I've recently transitioned my Emby Server from my Windows box to a Docker within UnRaid 6.1.6 on a Dell T20 Xeon e3-1225v3. The Server is running Version 3.0.5781.5

 

I'm trying to direct play from my main system running Windows 7 x64 Chrome 47.0.2526.80, but every video I've tried has transcoded instead of direct playing.  Some are due to bitrate (I'd be interested in how to adjust this limit), but most are reporting back the following in the server log:

2015-12-09 09:03:53.9325 Info App: Profile: Unknown Profile, Path: \\Galaxy\TV Shows\The League\Season 1\The League - S01E01 - The Draft.mkv, isEligibleForDirectPlay: True, isEligibleForDirectStream: True
2015-12-09 09:03:53.9325 Info App: Profile: Unknown Profile, No direct play profiles found for Path: \\Galaxy\TV Shows\The League\Season 1\The League - S01E01 - The Draft.mkv

(server-63585219811.txt, transcode-05c5fd09-a231-4e3a-ad55-83d6fc9b7231.txt)

The League S01E01

Video
CodecH264
ProfileHigh
Level31
Resolution1280x720
Aspect ratio16:9
AnamorphicNo
InterlacedNo
Framerate23.97602
Bitrate5287 kbps
Bit depth8 bit
Pixel formatyuv420p
Ref frames5
CABACNo
Audio
Languageeng
CodecDCA
ProfileDTS
Layout5.1
Channels6 ch
Bitrate1500 kbps
Sample rate48000 khz
DefaultYes

Attached Files


Edited by Douglas_D, 09 December 2015 - 12:58 PM.


#2 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 137727 posts
  • Local time: 05:22 PM

Posted 09 December 2015 - 01:04 PM

You can't direct play an mkv with dts in any browser at the moment. You're limited to formats the browser can play natively.



#3 Douglas_D OFFLINE  

Douglas_D

    Member

  • Members
  • 20 posts
  • Local time: 03:22 PM

Posted 09 December 2015 - 01:24 PM

Thanks for your quick response Luke.

 

Here's a fresh test with a file that does not use DTS.

 

 

Video
CodecH264
ProfileHigh
Level31
Resolution1280x720
Aspect ratio16:9
AnamorphicNo
InterlacedNo
Framerate23.976
Bitrate4326 kbps
Bit depth8 bit
Pixel formatyuv420p
Ref frames2
CABACNo
Audio
Languageeng
CodecAC3
Layout5.1
Channels6 ch
Bitrate375 kbps
Sample rate48000 khz
DefaultYes
Containermkv
Path\\Galaxy\TV Shows\Castle (2009)\Season 2\Castle (2009) - S02E12 - A Rose For Everafter.mkv

Attached Files



#4 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 137727 posts
  • Local time: 05:22 PM

Posted 09 December 2015 - 01:27 PM

You're limited to formats the browser can play natively.

This also includes ac3. MS Edge is the only browser that supports ac3 but not in an mkv container.



#5 Douglas_D OFFLINE  

Douglas_D

    Member

  • Members
  • 20 posts
  • Local time: 03:22 PM

Posted 09 December 2015 - 01:42 PM

Sorry about that.  I've tried poking around looking for supported formats, but all of my search results keep coming back with Chromecast and Chromebook results for supported formats.  

 

Do you know if there is a list of browsers and supported formats floating around?



#6 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 137727 posts
  • Local time: 05:22 PM

Posted 09 December 2015 - 01:49 PM

the best rule of thumb is mp4 or m4v with aac or mp3 audio. with those same codecs chrome can also direct play mkv.



#7 Douglas_D OFFLINE  

Douglas_D

    Member

  • Members
  • 20 posts
  • Local time: 03:22 PM

Posted 09 December 2015 - 03:14 PM

Maybe this one will be of some interest.

 

I direct played this file by copying the path into Chrome.  Audio and Video work.

 

When I go through Emby Web client it transcodes.  I saw that the profile it uses sets directplay = false, but don't know why it does.

 

 

Audio
Languageeng
CodecAAC
ProfileLC
Layoutstereo
Channels2 ch
Sample rate48000 khz
DefaultYes
Video
CodecH264
ProfileHigh
Level31
Resolution1280x720
Aspect ratio16:9
AnamorphicNo
InterlacedNo
Framerate23.976
Bitrate3672 kbps
Bit depth8 bit
Pixel formatyuv420p
Ref frames2
CABACNo
Containermkv
Path\\Galaxy\TV Shows\South Park\Season 14\South Park - S14E01 - Sexual Healing.mkv

 

Attached Files



#8 kayrus OFFLINE  

kayrus

    Member

  • Members
  • 13 posts
  • Local time: 10:22 PM

Posted 11 December 2015 - 05:17 PM

I have the same problem. Here is my MKV details:

Video
CodecH264
ProfileHigh
Level31
Resolution800x336
Aspect ratio2.40:1
AnamorphicNo
InterlacedNo
Framerate23.97602
Bitrate887 kbps
Bit depth8 bit
Pixel formatyuv420p
Ref frames10
CABACNo
Audio
CodecAAC
ProfileLC
Layoutstereo
Channels2 ch
Sample rate48000 khz
DefaultYes
Subtitle
CodecSRT
DefaultYes
ForcedNo
ExternalNo
Subtitle
CodecSRT
DefaultNo
ForcedNo
ExternalNo
Subtitle
CodecSRT
DefaultNo
ForcedNo
ExternalNo
Containermkv
Path/media/life.mkv


Logs are:

2015-12-11 21:19:38.6189 Info HttpServer: HTTP POST http://192.168.25.4:8096/emby/Items/167f9d5b91b26b414e347d5b36bf2ba2/PlaybackInfo?UserId=96d4f498ffef4dc68ef9bc01c5fcbed4&StartTimeTicks=0. UserAgent: Mozilla/5.0 (X11; CrOS x86_64 7520.55.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/47.0.2526.74 Safari/537.36
2015-12-11 21:19:38.6588 Info App: Profile: Unknown Profile, Path: /media/life.mkv, isEligibleForDirectPlay: True, isEligibleForDirectStream: True
2015-12-11 21:19:38.6588 Info App: Profile: VideoAudioCodecProfile, DirectPlay=false. Reason=Unknown Profile.AudioProfile Condition: NotEquals. ConditionValue: LC. IsRequired: True. Path: /media/life.mkv
2015-12-11 21:19:38.6600 Info App: Profile: Unknown Profile, Path: /media/life.mkv, isEligibleForDirectPlay: True, isEligibleForDirectStream: True
2015-12-11 21:19:38.6600 Info App: Profile: VideoAudioCodecProfile, DirectPlay=false. Reason=Unknown Profile.AudioProfile Condition: NotEquals. ConditionValue: LC. IsRequired: True. Path: /media/life.mkv
2015-12-11 21:19:38.6729 Info HttpServer: HTTP Response 200 to 192.168.25.192. Time: 51ms. http://192.168.25.4:8096/emby/Items/167f9d5b91b26b414e347d5b36bf2ba2/PlaybackInfo?UserId=96d4f498ffef4dc68ef9bc01c5fcbed4&StartTimeTicks=0

Edited by kayrus, 11 December 2015 - 05:44 PM.


#9 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 137727 posts
  • Local time: 05:22 PM

Posted 11 December 2015 - 05:18 PM

we are currently excluding the LC aac profile from direct play. i will remove this for the next release.



#10 kayrus OFFLINE  

kayrus

    Member

  • Members
  • 13 posts
  • Local time: 10:22 PM

Posted 11 December 2015 - 07:52 PM

Excellent. I already found the reason of this problem: https://github.com/M...aplayer.js#L302

 

I've removed whole vlc condition and AAC started to work well.

 

And I have another two questions:

1) Why don't you use something like ffmpeg -i video.mkv -vcodec copy -acodec copy stream.ts for browsers which don't support mkv or mov?

2) How can I enable only audio track transcoding? For example I have mkv (h264+ac3) and I would like to directly stream h264 and transcode only audio track ac3->mp3. How can I achieve that?

 

For the history:

 

There are no playback profiles which are defined for web clients. There are only configurable DLNA profiles which are absolutely don't relate to web browser. Web browsers generate their own playback profiles dynamically using this javascript (https://github.com/M.../mediaplayer.js). And I don't have an idea how it is possible to modify this JS and allow transcode only audio track.


Edited by kayrus, 11 December 2015 - 08:00 PM.

  • Deihmos likes this

#11 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 137727 posts
  • Local time: 05:22 PM

Posted 11 December 2015 - 08:02 PM

the browsers don't accept the .ts container. your question is frequently asked but we would already be doing it if it were possible.



#12 kayrus OFFLINE  

kayrus

    Member

  • Members
  • 13 posts
  • Local time: 10:22 PM

Posted 11 December 2015 - 08:31 PM

That was an example. Anyway, transcoding only of the audio track works! I've hardcoded "copy" codec inside mediaplayer.js and now firefox/chrome can play videos which were not available before! Now it is necessary to write down proper code which can determine original codec, compare it with x264 (or whatever browser can play) and force "copy" for video. If browser doesn't support some container - force copy for video+audio and use valid container.

 

Probably it is better to put these options into settings page... I guess enough for today.



#13 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 137727 posts
  • Local time: 05:22 PM

Posted 11 December 2015 - 08:34 PM

You're going to run into problems and then you'll see why it's not so simple. What is the transcoding container? if it is mp4, then try pausing the video in chrome and then unpausing. the video player will fail. this is not an issue in the web client code as it can be reproduced directly by putting the video url into the browser address bar.

 

On the other hand, if the transcoding container is HLS, then you'll run into this issue here:

 

http://emby.media/co...scode/?p=212333

 

If you can live with those issues then fine but we can't put them into the released software.



#14 kayrus OFFLINE  

kayrus

    Member

  • Members
  • 13 posts
  • Local time: 10:22 PM

Posted 11 December 2015 - 08:49 PM

Didn't you try to analyze how does Plex work? Or at least use Plex transcoder. Here are the command lines of both plex and emby for the same file:
#reencode
/usr/bin/ffmpeg -i file:/media/man.mkv -map_metadata -1 -threads 0 -map 0:0 -map 0:3 -map -0:s -codec:v:0
libx264 -pix_fmt yuv420p -preset superfast -crf 23 -b:v 3455640 -maxrate 3455640 -bufsize 6911280 -vsync vfr -profile:v high -level 41 -force_key_frames expr:gte(t,n_forced*3) -vf scale=trunc(oh*a/2)*2:min(ih\,1080) -flags -global_header -sc_threshold 0 -codec:a:0 aac -strict experimental -ac 6 -ab 320000 -af adelay=1,aresample=async=1 -hls_time 3 -start_number 0 -hls_list_size 0 -y /var/lib/emby-server/transcoding-temp/55c689d6814a16d267597c86c3b3c7e2.m3u8

#copy
ffmpeg -fflags +genpts -i file:/media/man.mkv -map 0:0 -map 0:3 -map -0:s -codec:v:0 copy -map_metadata -1 -threads 1 -codec:a:0 libmp3lame -ab 320000 -af aresample=async=1 -f mp4 -movflags frag_keyframe+empty_moov -y /var/lib/emby-server/transcoding-temp/d52a39e93afb6a804d89a4c821361681.mp4

#position+copy
/usr/bin/ffmpeg -ss 00:55:53.687 -fflags +genpts -i file:/media/man.mkv -map 0:0 -map 0:3 -map -0:s -codec:v:0 copy -map_metadata -1 -threads 1 -codec:a:0 libmp3lame -ab 320000 -af aresample=async=1 -f mp4 -movflags frag_keyframe+empty_moov -y /var/lib/emby-server/transcoding-temp/f34e00bb323032e886e1414ce2d3d330.mp4

#plex
/opt/plex/Application/Resources/Plex New Transcoder -noaccurate_seek -i /media/man.mkv -map 0:0 -codec:0 copy -bsf:0 h264_mp4toannexb,h264_plex -map 0:1 -metadata:s:1 language=eng -codec:1 aac -strict:1 experimental -cutoff:1 15000 -channel_layout:1 stereo -b:1 256k -f matroska -avoid_negative_ts disabled -map_metadata -1 - -start_at_zero -copyts -y -nostats -loglevel quiet -loglevel_plex error -progressurl http://127.0.0.1:32400/video/:/transcode/session/uab6dx27bcqjv2t9/progress

#plex+position
/opt/plex/Application/Resources/Plex New Transcoder -ss 1925.07495 -noaccurate_seek -i /media/man.mkv -map 0:0 -codec:0 copy -bsf:0 h264_mp4toannexb,h264_plex -map 0:1 -metadata:s:1 language=eng -codec:1 aac -strict:1 experimental -cutoff:1 15000 -channel_layout:1 stereo -b:1 256k -f matroska -avoid_negative_ts disabled -map_metadata -1 - -start_at_zero -copyts -y -nostats -loglevel quiet -loglevel_plex error -progressurl http://127.0.0.1:32400/video/:/transcode/session/gup8g9q8h5d8to6r/progress
 
 
 
 
Both work on my armhf pc. Plex works flawlessly out-of-the-box, but Emby has already spent a lot of my time and I hope not in vain.

Edited by kayrus, 11 December 2015 - 09:00 PM.

  • Luke and Deihmos like this





Also tagged with one or more of these keywords: Transcoding, Direct Play, Chrome

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users