From 7372e837ee486b09aaad9c0088aefd13562576e4 Mon Sep 17 00:00:00 2001 From: George Haidos Date: Sun, 19 May 2024 00:45:44 +0300 Subject: [PATCH 1/3] Force support DoVi profile 8 for webOS TVs that support it but report otherwise --- src/scripts/browserDeviceProfile.js | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/scripts/browserDeviceProfile.js b/src/scripts/browserDeviceProfile.js index cb19a4172fd..9219978f8c8 100644 --- a/src/scripts/browserDeviceProfile.js +++ b/src/scripts/browserDeviceProfile.js @@ -247,9 +247,13 @@ function supportedDolbyVisionProfilesHevc(videoTestElement) { .replace(/no/, '')) { supportedProfiles.push(5); } - if (videoTestElement - .canPlayType('video/mp4; codecs="dvh1.08.09"') - .replace(/no/, '')) { + if ( + videoTestElement + .canPlayType('video/mp4; codecs="dvh1.08.09"') + .replace(/no/, '') + // LG TVs from at least 2020 onwards should support profile 8, but they don't report it. + || (browser.web0sVersion >= 4) + ) { supportedProfiles.push(8); } } From edd32297ee402b599426cae9e400b2f43decab25 Mon Sep 17 00:00:00 2001 From: George Haidos Date: Sat, 25 May 2024 21:54:40 +0300 Subject: [PATCH 2/3] Disable fmp4 by default for Tizen and WebOS --- src/scripts/settings/userSettings.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/scripts/settings/userSettings.js b/src/scripts/settings/userSettings.js index ddfb8e81941..f83f3134156 100644 --- a/src/scripts/settings/userSettings.js +++ b/src/scripts/settings/userSettings.js @@ -1,7 +1,7 @@ -import appSettings from './appSettings'; -import browser from '../browser'; import Events from '../../utils/events.ts'; import { toBoolean } from '../../utils/string.ts'; +import browser from '../browser'; +import appSettings from './appSettings'; function onSaveTimeout() { const self = this; @@ -142,7 +142,7 @@ export class UserSettings { } // Enable it by default only for the platforms that play fMP4 for sure. - return toBoolean(this.get('preferFmp4HlsContainer', false), browser.safari || browser.firefox || browser.chrome || browser.edgeChromium); + return toBoolean(this.get('preferFmp4HlsContainer', false), browser.safari || browser.firefox || (browser.chrome && !browser.web0s && !browser.tizen) || browser.edgeChromium); } /** From 0b34c1812e1a354b546e39be395c8d86b069c747 Mon Sep 17 00:00:00 2001 From: George Haidos Date: Sat, 6 Jul 2024 00:15:34 +0300 Subject: [PATCH 3/3] Allow Dolby Vision in TS for WebOS Co-authored-by: Dmitry Lyzo <56478732+dmitrylyzo@users.noreply.github.com> --- src/scripts/browserDeviceProfile.js | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/scripts/browserDeviceProfile.js b/src/scripts/browserDeviceProfile.js index 9219978f8c8..050c6a726eb 100644 --- a/src/scripts/browserDeviceProfile.js +++ b/src/scripts/browserDeviceProfile.js @@ -1263,17 +1263,16 @@ export default function (options) { }); if (browser.web0s && supportsDolbyVision(options)) { - // Disallow direct playing of DOVI media in containers not mp4. - // This paired with the "Prefer fMP4-HLS Container" client playback setting enables DOVI playback on webOS. + // Disallow direct playing of DOVI media in containers not ts or mp4. profile.CodecProfiles.push({ Type: 'Video', - Container: '-mp4', + Container: '-mp4,ts', Codec: 'hevc', Conditions: [ { Condition: 'EqualsAny', Property: 'VideoRangeType', - Value: 'SDR|HDR10|HLG', + Value: hevcVideoRangeTypes.split('|').filter((v) => !v.startsWith('DOVI')).join('|'), IsRequired: false } ]