mirror of
https://github.com/jellyfin/jellyfin-kodi.git
synced 2024-11-10 04:06:11 +00:00
Update playutils.py
Modified Hi10P to get streams and parse profiles
This commit is contained in:
parent
db8ddc16d2
commit
9d50c4f745
1 changed files with 18 additions and 10 deletions
|
@ -102,10 +102,14 @@ class PlayUtils():
|
|||
|
||||
videotrack = self.item['MediaSources'][0]['Name']
|
||||
transcodeH265 = settings('transcodeH265')
|
||||
videoprofile = self.item['MediaSources'][0]['Profile']
|
||||
transcodeHi10P = settings('transcodeHi10P')
|
||||
videoprofiles = self.item['MediaSources'][0]['MediaStreams']
|
||||
streamprofiles = []
|
||||
for vprofile in videoprofiles:
|
||||
if "Profile" in vprofile:
|
||||
streamprofiles.append(vprofile['Profile'])
|
||||
transcodeHi10P = utils.settings('transcodeHi10P')
|
||||
|
||||
if transcodeHi10P == "true" and "H264" in videotrack and "High 10" in videoprofile:
|
||||
if transcodeHi10P == "true" and "H264" in videotrack and "High 10" in streamprofiles:
|
||||
return False
|
||||
|
||||
if transcodeH265 in ("1", "2", "3") and ("HEVC" in videotrack or "H265" in videotrack):
|
||||
|
@ -212,10 +216,14 @@ class PlayUtils():
|
|||
|
||||
videotrack = self.item['MediaSources'][0]['Name']
|
||||
transcodeH265 = utils.settings('transcodeH265')
|
||||
videoprofile = self.item['MediaSources'][0]['Profile']
|
||||
transcodeHi10P = settings('transcodeHi10P')
|
||||
videoprofiles = self.item['MediaSources'][0]['MediaStreams']
|
||||
streamprofiles = []
|
||||
for vprofile in videoprofiles:
|
||||
if "Profile" in vprofile:
|
||||
streamprofiles.append(vprofile['Profile'])
|
||||
transcodeHi10P = utils.settings('transcodeHi10P')
|
||||
|
||||
if transcodeHi10P == "true" and "H264" in videotrack and "High 10" in videoprofile:
|
||||
if transcodeHi10P == "true" and "H264" in videotrack and "High 10" in streamprofiles:
|
||||
return False
|
||||
|
||||
if transcodeH265 in ("1", "2", "3") and ("HEVC" in videotrack or "H265" in videotrack):
|
||||
|
|
Loading…
Reference in a new issue