mirror of
https://github.com/samsonjs/media.git
synced 2026-04-27 15:07:40 +00:00
Fix read H.264 in WebM when the NAL unit length field length is not 4.
This commit is contained in:
parent
49f4fe7810
commit
854fa928fb
1 changed files with 1 additions and 0 deletions
|
|
@ -646,6 +646,7 @@ public final class WebmExtractor implements Extractor {
|
||||||
// Write a start code for the current NAL unit.
|
// Write a start code for the current NAL unit.
|
||||||
nalStartCode.setPosition(0);
|
nalStartCode.setPosition(0);
|
||||||
trackOutput.sampleData(nalStartCode, 4);
|
trackOutput.sampleData(nalStartCode, 4);
|
||||||
|
sampleSize += nalUnitLengthFieldLengthDiff;
|
||||||
} else {
|
} else {
|
||||||
// Write the payload of the NAL unit.
|
// Write the payload of the NAL unit.
|
||||||
int writtenBytes = trackOutput.sampleData(input, sampleCurrentNalBytesRemaining);
|
int writtenBytes = trackOutput.sampleData(input, sampleCurrentNalBytesRemaining);
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue