Skip to content

Commit b4151a6

Browse files
committed
fix(DASH): Revert Dolby Atmos detection when there is not SupplementalProperty
Reverts cf581cd Reverts 56c5f52
1 parent 31373b3 commit b4151a6

File tree

2 files changed

+2
-27
lines changed

2 files changed

+2
-27
lines changed

lib/dash/dash_parser.js

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2334,12 +2334,8 @@ shaka.dash.DashParser = class {
23342334
return element.attributes['schemeIdUri'] == expectedUri &&
23352335
element.attributes['value'] == expectedValue;
23362336
});
2337-
const codecs = context.representation.codecs;
2338-
// Detect the presence of Dolby Atmos audio content based on the codec and
2339-
// bandwidth. Bandwidth above 384 kbps is a good indicator of Atmos content.
2340-
const isAtmos = codecs.includes('ec-3') && context.bandwidth > 384000;
23412337
let spatialAudio = false;
2342-
if (hasJoc || isAtmos) {
2338+
if (hasJoc) {
23432339
spatialAudio = true;
23442340
}
23452341

@@ -2371,6 +2367,7 @@ shaka.dash.DashParser = class {
23712367

23722368
let hdr;
23732369
const profiles = context.profiles;
2370+
const codecs = context.representation.codecs;
23742371

23752372
const hevcHDR = 'http://dashif.org/guidelines/dash-if-uhd#hevc-hdr-pq10';
23762373
if (profiles.includes(hevcHDR) && (codecs.includes('hvc1.2.4.L153.B0') ||

test/dash/dash_parser_manifest_unit.js

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -540,28 +540,6 @@ describe('DashParser Manifest', () => {
540540
expect(stream.spatialAudio).toBe(true);
541541
});
542542

543-
it('Detects spatial audio by codec and bandwidth', async () => {
544-
const source = [
545-
'<MPD>',
546-
' <Period duration="PT30M">',
547-
' <AdaptationSet mimeType="audio/mp4" lang="\u2603">',
548-
' <Representation bandwidth="768000" codecs="ec-3">',
549-
' <BaseURL>http://example.com</BaseURL>',
550-
' <SegmentTemplate media="2.mp4" duration="1" />',
551-
' </Representation>',
552-
' </AdaptationSet>',
553-
' </Period>',
554-
'</MPD>',
555-
].join('\n');
556-
557-
fakeNetEngine.setResponseText('dummy://foo', source);
558-
559-
/** @type {shaka.extern.Manifest} */
560-
const manifest = await parser.start('dummy://foo', playerInterface);
561-
const stream = manifest.variants[0].audio;
562-
expect(stream.spatialAudio).toBe(true);
563-
});
564-
565543
it('correctly parses CEA-608 closed caption tags without channel numbers',
566544
async () => {
567545
const source = [

0 commit comments

Comments
 (0)