mirror of
https://github.com/androidx/media.git
synced 2025-05-09 16:40:55 +08:00
Fix MatroskaExtractor to use blockDurationUs not durationUs
This typo was introduced inddb70d96ad
when migrating a static method with parameter `durationUs` to an instance method where the correct field to use was `blockDurationUs` (but `durationUs` also exists). The test that catches this was only added in45013ece1e
(and therefore configured with the wrong expected output data). issue:#6833 PiperOrigin-RevId: 288274197
This commit is contained in:
parent
1c1c0ed88a
commit
29df73e268
@ -43,6 +43,8 @@
|
||||
* WAV:
|
||||
* Support IMA ADPCM encoded data.
|
||||
* Improve support for G.711 A-law and mu-law encoded data.
|
||||
* Fix MKV subtitles to disappear when intended instead of lasting until the
|
||||
next cue ([#6833](https://github.com/google/ExoPlayer/issues/6833)).
|
||||
|
||||
### 2.11.1 (2019-12-20) ###
|
||||
|
||||
|
@ -1250,10 +1250,10 @@ public class MatroskaExtractor implements Extractor {
|
||||
if (CODEC_ID_SUBRIP.equals(track.codecId) || CODEC_ID_ASS.equals(track.codecId)) {
|
||||
if (blockSampleCount > 1) {
|
||||
Log.w(TAG, "Skipping subtitle sample in laced block.");
|
||||
} else if (durationUs == C.TIME_UNSET) {
|
||||
} else if (blockDurationUs == C.TIME_UNSET) {
|
||||
Log.w(TAG, "Skipping subtitle sample with no duration.");
|
||||
} else {
|
||||
setSubtitleEndTime(track.codecId, durationUs, subtitleSample.data);
|
||||
setSubtitleEndTime(track.codecId, blockDurationUs, subtitleSample.data);
|
||||
// Note: If we ever want to support DRM protected subtitles then we'll need to output the
|
||||
// appropriate encryption data here.
|
||||
track.output.sampleData(subtitleSample, subtitleSample.limit());
|
||||
|
@ -31,13 +31,13 @@ track 1:
|
||||
sample 0:
|
||||
time = 0
|
||||
flags = 1
|
||||
data = length 59, hash A0217393
|
||||
data = length 59, hash 1AD38625
|
||||
sample 1:
|
||||
time = 2345000
|
||||
flags = 1
|
||||
data = length 95, hash 4904F2
|
||||
data = length 95, hash F331C282
|
||||
sample 2:
|
||||
time = 4567000
|
||||
flags = 1
|
||||
data = length 59, hash EFAB6D8A
|
||||
data = length 59, hash F8CD7C60
|
||||
tracksEnded = true
|
||||
|
@ -31,13 +31,13 @@ track 1:
|
||||
sample 0:
|
||||
time = 0
|
||||
flags = 1
|
||||
data = length 59, hash A0217393
|
||||
data = length 59, hash 1AD38625
|
||||
sample 1:
|
||||
time = 2345000
|
||||
flags = 1
|
||||
data = length 95, hash 4904F2
|
||||
data = length 95, hash F331C282
|
||||
sample 2:
|
||||
time = 4567000
|
||||
flags = 1
|
||||
data = length 59, hash EFAB6D8A
|
||||
data = length 59, hash F8CD7C60
|
||||
tracksEnded = true
|
||||
|
@ -31,13 +31,13 @@ track 1:
|
||||
sample 0:
|
||||
time = 0
|
||||
flags = 1
|
||||
data = length 59, hash A0217393
|
||||
data = length 59, hash 1AD38625
|
||||
sample 1:
|
||||
time = 2345000
|
||||
flags = 1
|
||||
data = length 95, hash 4904F2
|
||||
data = length 95, hash F331C282
|
||||
sample 2:
|
||||
time = 4567000
|
||||
flags = 1
|
||||
data = length 59, hash EFAB6D8A
|
||||
data = length 59, hash F8CD7C60
|
||||
tracksEnded = true
|
||||
|
@ -31,13 +31,13 @@ track 1:
|
||||
sample 0:
|
||||
time = 0
|
||||
flags = 1
|
||||
data = length 59, hash A0217393
|
||||
data = length 59, hash 1AD38625
|
||||
sample 1:
|
||||
time = 2345000
|
||||
flags = 1
|
||||
data = length 95, hash 4904F2
|
||||
data = length 95, hash F331C282
|
||||
sample 2:
|
||||
time = 4567000
|
||||
flags = 1
|
||||
data = length 59, hash EFAB6D8A
|
||||
data = length 59, hash F8CD7C60
|
||||
tracksEnded = true
|
||||
|
Loading…
x
Reference in New Issue
Block a user