Kodi Video settings

plex-for-kodi

#1

Kodi has lots of settings, but what have people got them set at?

I love the idea of being able to use the AFTV with Kodi so it can placy VC1 films,.

I tried yesterday to watch Deadpool which is H264. The full ripped MKV (31mbps) was a bit stuttery..... the nextwork is fine but maybe the v1 aFTV isn't up to it.

So i stopped and switch to my 4Mbps handbraked version of the same film. This would play for a few seconds and then go to a 'paused' state (literally like as though i had pressed the pause button).

I'll try and reproduce and post up some logs.... but I am wondering if my kodi video settings may be the cause.


#2

Okay, so just tried the 4Mbps h264 version and I can replicate it. I have recorded it with my iPhone if needed.

The errors in the log are:

ERROR: Window Translator: Can't find window playerprocessinfo
WARNING: CDVDMessageQueue(audio)::Get - asked for new data packet, with nothing available
NOTICE: CDVDPlayerAudio::OutputPacket skipping a packets of duration 21

This gets repeated numerous times.


#3

We need a full log. the AFTV v1 should handle 31mbps fine. To test if its a Plex issue, or network, you can try to play it back in Kodi over network, and then Kodi locally as well.


#4

File plays perfectly from the NAS using Kodi itself.

Can I PM the log file instead of posting here?


#5

Okay, so I've just tried another film and it won't play. Checking the PMS log I can find this:

Dec 18, 2016 18:56:05.563 [0xe9335b40] DEBUG - MDE: THE TAKE (2016): Direct Play is disabled
Dec 18, 2016 18:56:05.564 [0xe9335b40] DEBUG - MDE: THE TAKE (2016): no direct play video profile exists for http/mp4/h264
Dec 18, 2016 18:56:05.565 [0xe9335b40] DEBUG - MDE: THE TAKE (2016): no direct play video profile exists for http/mp4/h264/aac
Dec 18, 2016 18:56:05.565 [0xe9335b40] DEBUG - MDE: THE TAKE (2016): no direct play video profile exists for http/mp4/h264/aac
Dec 18, 2016 18:56:05.565 [0xe9335b40] DEBUG - MDE: THE TAKE (2016): no direct play video profile exists for http/mp4/h264/ac3
Dec 18, 2016 18:56:05.565 [0xe9335b40] DEBUG - MDE: THE TAKE (2016): no direct play video profile exists for http/mp4/h264/ac3
Dec 18, 2016 18:56:05.565 [0xe9335b40] DEBUG - MDE: THE TAKE (2016): Direct Streaming is disabled, so video stream will be transcoded
Dec 18, 2016 18:56:05.565 [0xe9335b40] DEBUG - MDE: THE TAKE (2016): no remuxable profile found, so video stream will be transcoded
Dec 18, 2016 18:56:05.566 [0xe9335b40] DEBUG - MDE: THE TAKE (2016): selected media 0 / 1094838

So, the film is being transcoded which is why I'm having the issue as my NAS isn't powerful enough.

However it shouldn't need to transcode? Kodi itself plays the film fine as does every other plex player. I've checked the plex settings and Allow Direct Play is ticked, as is Direct Streaming... so why does it think they are disabled as per above?

My mp4s are all handbraked to video of 4Mbps and then a stereo AAC, stereo AC3, 5.1 AAC and 5.1 AC3.

And from the kodi log

19:56:32 T:18446744072539629720  NOTICE: script.plex: API: Choice media:  : 1080P, 6.2 Mbps container=mkv videoCodec=h264 audioCodec=ac3 audioChannels=2 id=21081 part:0
19:56:32 T:18446744072539629720  NOTICE: script.plex: API: Choice videoStream: <plexnet.plexstream.PlexStream object at 0xbce610e0>
19:56:32 T:18446744072539629720  NOTICE: script.plex: API: Choice audioStream: <plexnet.plexstream.PlexStream object at 0xbce61538>
19:56:32 T:18446744072539629720  NOTICE: script.plex: API: MDE: Server was unbiased about the decision. App cannot direct play this item. Direct play is disabled. Direct play not available; Conversion OK. Direct play not available; Conversion OK.
19:56:32 T:18446744072539629720  NOTICE: script.plex: API: WARNING: Server requested new playback decision: App cannot direct play this item. Direct play is disabled. Direct play not available; Conversion OK. Direct play not available; Conversion OK.
19:56:32 T:18446744072539629720  NOTICE: script.plex: API: Choice media:  : 1080P, 6.2 Mbps container=mkv videoCodec=h264 audioCodec=ac3 audioChannels=2 id=21081 part:0
19:56:32 T:18446744072539629720  NOTICE: script.plex: API: Choice videoStream: <plexnet.plexstream.PlexStream object at 0xbce610e0>
19:56:32 T:18446744072539629720  NOTICE: script.plex: API: Choice audioStream: <plexnet.plexstream.PlexStream object at 0xbce61538>
19:56:32 T:18446744072539629720  NOTICE: script.plex: API: MDE: Server has decided this cannot direct play
19:56:32 T:18446744072539629720  NOTICE: script.plex: API: MDE: MediaChoice: direct playable=False version= : 1080P, 6.2 Mbps container=mkv videoCodec=h264 audioCodec=ac3 audioChannels=2 id=21081
19:56:32 T:18446744072539629720  NOTICE: script.plex: API: Replacing 'direct playable=False version= : 1080p, 5.4 Mbps container=mp4 videoCodec=h264 audioCodec=ac3 audioChannels=6 id=21081' with 'direct playable=False version= : 1080P, 6.2 Mbps container=mkv videoCodec=h264 audioCodec=ac3 audioChannels=2 id=21081' and rebuilding.
19:56:32 T:18446744072539629720  NOTICE: script.plex: API: Forced Transcode; allowDirectStream=False
19:56:32 T:18446744072539629720  NOTICE: script.plex: API: DEBUG: buildTranscode()
19:56:32 T:18446744072539629720  NOTICE: script.plex: API: DEBUG: buildTranscodeMkv()

So it looks like the PMS is making the decision that it can't direct play? I'm on 1.2.5.2966, I haven't updated the server as I wait a few weeks for all the new issues to be sorted before I update.

My media file info is:

<MediaContainer size="1" allowSync="1" identifier="com.plexapp.plugins.library" librarySectionID="6" librarySectionTitle="Movies (All)" librarySectionUUID="f1173449-f529-4c8b-bbf2-79ccfeaaa05f" mediaTagPrefix="/system/bundle/media/flags/" mediaTagVersion="1478123408">
<Video ratingKey="477075" key="/library/metadata/477075" guid="com.plexapp.agents.imdb://tt2368619?lang=en" librarySectionID="6" studio="StudioCanal" type="movie" title="THE TAKE" titleSort="TAKE" contentRating="gb/R18" summary="A young artist and former CIA agent embark on an anti-terrorist mission in France." rating="8.2" year="2016" tagline="With law comes disorder" thumb="/library/metadata/477075/thumb/1482087363" art="/library/metadata/477075/art/1482087363" duration="5997248" originallyAvailableAt="2016-04-22" addedAt="1476993611" updatedAt="1482087363" chapterSource="mixed" primaryExtraKey="/library/metadata/494295" ratingImage="imdb://image.rating">
<Media videoResolution="1080" id="1094838" duration="5997248" bitrate="4964" width="1920" height="1080" aspectRatio="1.78" audioChannels="6" audioCodec="aac" videoCodec="h264" container="mp4" videoFrameRate="24p" optimizedForStreaming="1" audioProfile="lc" has64bitOffsets="0" videoProfile="high">
<Part accessible="1" exists="1" id="1098721" key="/library/parts/1098721/1476828982/file.mp4" duration="5997248" file="/volume5/Blu Ray Compressed 3/The Take (2016).mp4" size="3721522780" audioProfile="lc" container="mp4" deepAnalysisVersion="1" has64bitOffsets="0" hasChapterTextStream="1" indexes="sd" optimizedForStreaming="1" requiredBandwidths="36817,20025,7207,7207,7207,7207,7207,7207" videoProfile="high">
<Stream id="2196253" streamType="1" default="1" codec="h264" index="0" bitrate="4000" bitDepth="8" cabac="1" chromaSubsampling="4:2:0" codecID="avc1" colorRange="tv" colorSpace="bt709" duration="5508957" frameRate="24.000" frameRateMode="vfr" hasScalingMatrix="0" height="1080" level="41" pixelFormat="yuv420p" profile="high" refFrames="4" requiredBandwidths="35396,18612,6664,6664,6664,6664,6664,6664" scanType="progressive" streamIdentifier="1" width="1920"/>
<Stream id="2196254" streamType="2" selected="1" default="1" codec="aac" index="1" channels="2" bitrate="147" language="English" languageCode="eng" bitrateMode="vbr" codecID="40" duration="5997227" profile="lc" requiredBandwidths="161,161,161,161,161,161,161,161" samplingRate="48000" streamIdentifier="2"/>
<Stream id="2196255" streamType="2" codec="aac" index="2" channels="6" bitrate="353" language="English" languageCode="eng" bitrateMode="vbr" codecID="40" duration="5997227" profile="lc" requiredBandwidths="383,383,383,383,383,383,383,383" samplingRate="48000" streamIdentifier="3"/>
<Stream id="2196256" streamType="2" codec="ac3" index="3" channels="2" bitrate="224" language="English" languageCode="eng" audioChannelLayout="stereo" bitDepth="16" bitrateMode="cbr" codecID="ac-3" dialogNorm="-31" duration="5997248" requiredBandwidths="224,224,224,224,224,224,224,224" samplingRate="48000" streamIdentifier="4"/>
<Stream id="2196257" streamType="2" codec="ac3" index="4" channels="6" bitrate="640" language="English" languageCode="eng" audioChannelLayout="5.1(side)" bitDepth="16" bitrateMode="cbr" codecID="ac-3" dialogNorm="-31" duration="5997248" requiredBandwidths="640,640,640,640,640,640,640,640" samplingRate="48000" streamIdentifier="5"/>
<Stream id="2196264" key="/library/streams/2196264" streamType="3" codec="srt" language="English" languageCode="eng" format="srt"/>
</Part>
</Media>
<Genre id="97" tag="Action"/>
<Director id="22553" tag="James Watkins"/>
<Writer id="34974" tag="Andrew Baldwin"/>
<Writer id="34975" tag="James Watkins"/>
<Producer id="34984" tag="Bard Dorros"/>
<Producer id="29297" tag="David Kanter"/>
<Producer id="6298" tag="Philippe Rousselet"/>
<Country id="68" tag="USA"/>
<Role id="1116" tag="Idris Elba" role="Sean Briar" thumb="http://image.tmdb.org/t/p/original/4fuJRkT2TdfznRONUvQmdcayTTx.jpg"/>
<Role id="34976" tag="Richard Madden" role="Michael Mason" thumb="http://image.tmdb.org/t/p/original/4OBtiwJBBIeffW5XyY8u83ZPyoF.jpg"/>
<Role id="29909" tag="Charlotte Le Bon" role="Zoe Naville" thumb="http://image.tmdb.org/t/p/original/vozgdySw0fnS3ue6AFcTsfHRbYq.jpg"/>
<Role id="23723" tag="Jorge Leon Martinez" role="Rioter" thumb="http://image.tmdb.org/t/p/original/nWYveATaySCXosWAjcSS8VNPRe7.jpg"/>
<Role id="22241" tag="Kelly Reilly" role="Karen Dacre" thumb="http://image.tmdb.org/t/p/original/utp6IT1cLk80RgJzehBIWkSQ8FJ.jpg"/>
<Role id="34977" tag="Anatol Yusef" role="Tom Luddy" thumb="http://image.tmdb.org/t/p/original/hMgmp1GKGHTvJS7sx6QbO2TXDq3.jpg"/>
<Role id="34978" tag="Eriq Ebouaney" role="Baba" thumb="http://image.tmdb.org/t/p/original/wfxFCJ85tNTUvFRLsOayUQmHgSC.jpg"/>
<Role id="34322" tag="José Garcia" role="Victor Gamieux" thumb="http://image.tmdb.org/t/p/original/9OlwiWiBgxCGd85HcxuljDXZn3U.jpg"/>
<Role id="22791" tag="Daniel Westwood" role="Response Rapide Sniper" thumb="http://image.tmdb.org/t/p/original/yvblj5nqxW7QOTnDWEooKLyGfB3.jpg"/>
<Role id="34979" tag="Alex Fondja" role="Ange" thumb="http://image.tmdb.org/t/p/original/dh4Q8UZeZkXcaAur8aqKOTpaoGp.jpg"/>
<Role id="34980" tag="Ines Boughanmi" role="French Journalist" thumb="http://image.tmdb.org/t/p/original/v22YvPL7BpPPmXC2LYKpGd5V521.jpg"/>
<Role id="34981" tag="Tony Paul West" role="Journalist"/>
<Role id="34982" tag="Tugba Tirpan" role="French Protestor" thumb="http://image.tmdb.org/t/p/original/eJMeKhkIeHQfh4npOYZVHIX21GU.jpg"/>
<Role id="34983" tag="Valeria Ragonese" role="Protester" thumb="http://image.tmdb.org/t/p/original/mzqBXz3BV6qlgl3Sbb6TGsaMbBH.jpg"/>
<Extras size="1">
<Video ratingKey="494295" key="/library/metadata/494295" guid="iva://api.internetvideoarchive.com/2.0/DataService/VideoAssets(114514)?lang=en&bitrates=80,212,450,600,750,1500,2500,5000,8000&duration=140&adaptive=1&dts=0" type="clip" title="Bastille Day" summary="" index="1" year="2016" thumb="/library/metadata/494295/thumb/1482087363" duration="140000" originallyAvailableAt="2016-02-18" addedAt="1482087363" extraType="1">
<Media videoResolution="1080" id="1130623" duration="140000" bitrate="2500" width="1920" height="1080" aspectRatio="1.78" audioCodec="aac" videoCodec="h264" container="mp4" premium="1">
<Part id="1134506" duration="140000" container="mp4" key="/services/iva/assets/114514/video.mp4?bitrate=2500" optimizedForStreaming="1">
<Stream id="2268997" streamType="1" codec="h264" index="0" bitrate="2500" height="1080" width="1920"/>
<Stream id="2268998" streamType="2" selected="1" codec="aac" index="1" channels="2" language="English" languageCode="eng"/>
</Part>
</Media>
<Media videoResolution="720" id="1130624" duration="140000" bitrate="1500" width="1280" height="720" aspectRatio="1.78" audioCodec="aac" videoCodec="h264" container="mp4" premium="1">
<Part id="1134507" duration="140000" container="mp4" key="/services/iva/assets/114514/video.mp4?bitrate=1500" optimizedForStreaming="1">
<Stream id="2268999" streamType="1" codec="h264" index="0" bitrate="1500" height="720" width="1280"/>
<Stream id="2269000" streamType="2" selected="1" codec="aac" index="1" channels="2" language="English" languageCode="eng"/>
</Part>
</Media>
<Media videoResolution="480" id="1130625" duration="140000" bitrate="450" width="640" height="480" aspectRatio="1.33" audioCodec="aac" videoCodec="h264" container="mp4" premium="1">
<Part id="1134508" duration="140000" container="mp4" key="/services/iva/assets/114514/video.mp4?bitrate=450" optimizedForStreaming="1">
<Stream id="2269001" streamType="1" codec="h264" index="0" bitrate="450" height="480" width="640"/>
<Stream id="2269002" streamType="2" selected="1" codec="aac" index="1" channels="2" language="English" languageCode="eng"/>
</Part>
</Media>
</Video>
</Extras>
</Video>
</MediaContainer>

#6

We want full logs, and links to them instead of pasted in, so we can review the entire scenario.

You sure you're running .96? If it is in fact the PMS, we have no insight into why it makes the decisions it does.

What happens when you use the Plex app for Fire TV?


#7

The AFTV plex app happily 'direct plays' the file. The kodi app requests a transcode of video and direct stream of audio.

log file attached and yes, defo on 0.96


#8

Actually this log says:
script.plex: STARTED: 0.0.95

But what are you quality settings? Can you change them all to 'original quality' and try to play it and see what it says?

BTW, you can login to plex/web and goto 'status' and see if its transcoding from there, don't need to look at logs. But if it still is transcoding, I'll need logs again :)


#9

Yep, it updated to 0.96 during that session. Quality settings are on original. I've tried all sorts of things but the same result. It just wants to transcode. Same with 0.96 vs 0.95.


#10

Can you try this build and see if the results are any different?


#11

Spot on, that's done it. They are now direct playing. What was the issue?

I'll do some more testing over the next couple of weeks as I've finished for the holiday season now.

Thanks for identifying a fix.


#12

Some leftover code we didn't need from the previous implementation we ported from. The fix will be in the next release.

Thanks for reporting!