Fix/Update TODOs in Mp4Muxer tests
PiperOrigin-RevId: 562728777
This commit is contained in:
parent
2554fe8f70
commit
657856dfe5
@ -228,14 +228,12 @@ public class Mp4MuxerMetadataTest {
|
|||||||
muxer.close();
|
muxer.close();
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO(b/270956881): Use FakeExtractorOutput once it starts dumping custom metadata from the
|
FakeExtractorOutput fakeExtractorOutput =
|
||||||
// meta box.
|
TestUtil.extractAllSamplesFromFilePath(new Mp4Extractor(), outputFilePath);
|
||||||
DumpableMp4Box dumpableBox =
|
// Added string metadata should be present in the track metadata dump.
|
||||||
new DumpableMp4Box(ByteBuffer.wrap(TestUtil.getByteArrayFromFilePath(outputFilePath)));
|
|
||||||
// The meta box should be present in the output MP4.
|
|
||||||
DumpFileAsserts.assertOutput(
|
DumpFileAsserts.assertOutput(
|
||||||
context,
|
context,
|
||||||
dumpableBox,
|
fakeExtractorOutput,
|
||||||
MuxerTestUtil.getExpectedDumpFilePath("mp4_with_string_metadata.mp4"));
|
MuxerTestUtil.getExpectedDumpFilePath("mp4_with_string_metadata.mp4"));
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -252,13 +250,13 @@ public class Mp4MuxerMetadataTest {
|
|||||||
muxer.close();
|
muxer.close();
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO(b/270956881): Use FakeExtractorOutput once it starts dumping custom metadata from the
|
FakeExtractorOutput fakeExtractorOutput =
|
||||||
// meta box.
|
TestUtil.extractAllSamplesFromFilePath(new Mp4Extractor(), outputFilePath);
|
||||||
DumpableMp4Box dumpableBox =
|
// Added float metadata should be present in the track metadata dump.
|
||||||
new DumpableMp4Box(ByteBuffer.wrap(TestUtil.getByteArrayFromFilePath(outputFilePath)));
|
|
||||||
// The meta box should be present in the output MP4.
|
|
||||||
DumpFileAsserts.assertOutput(
|
DumpFileAsserts.assertOutput(
|
||||||
context, dumpableBox, MuxerTestUtil.getExpectedDumpFilePath("mp4_with_float_metadata.mp4"));
|
context,
|
||||||
|
fakeExtractorOutput,
|
||||||
|
MuxerTestUtil.getExpectedDumpFilePath("mp4_with_float_metadata.mp4"));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@ -278,7 +276,7 @@ public class Mp4MuxerMetadataTest {
|
|||||||
muxer.close();
|
muxer.close();
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO(b/270956881): Use FakeExtractorOutput once it starts dumping uuid box.
|
// TODO: b/288544833 - Use FakeExtractorOutput once it starts dumping uuid box.
|
||||||
DumpableMp4Box dumpableBox =
|
DumpableMp4Box dumpableBox =
|
||||||
new DumpableMp4Box(ByteBuffer.wrap(TestUtil.getByteArrayFromFilePath(outputFilePath)));
|
new DumpableMp4Box(ByteBuffer.wrap(TestUtil.getByteArrayFromFilePath(outputFilePath)));
|
||||||
// The uuid box should be present in the output MP4.
|
// The uuid box should be present in the output MP4.
|
||||||
|
@ -1,40 +1,32 @@
|
|||||||
ftyp (28 bytes):
|
seekMap:
|
||||||
Data = length 20, hash EF896440
|
isSeekable = true
|
||||||
mdat (71 bytes):
|
duration = 0
|
||||||
Data = length 55, hash 6B19F4A7
|
getPosition(0) = [[timeUs=0, position=44]]
|
||||||
moov (772 bytes):
|
getPosition(1) = [[timeUs=0, position=44]]
|
||||||
mvhd (108 bytes):
|
getPosition(0) = [[timeUs=0, position=44]]
|
||||||
Data = length 100, hash A5ADE288
|
getPosition(0) = [[timeUs=0, position=44]]
|
||||||
meta (114 bytes):
|
numberOfTracks = 1
|
||||||
hdlr (33 bytes):
|
track 0:
|
||||||
Data = length 25, hash C39D0F5B
|
total output bytes = 55
|
||||||
keys (37 bytes):
|
sample count = 1
|
||||||
Data = length 29, hash 45F2DCDF
|
format 0:
|
||||||
ilst (36 bytes):
|
id = 1
|
||||||
Data = length 28, hash 2BFD5C32
|
sampleMimeType = video/avc
|
||||||
trak (542 bytes):
|
codecs = avc1.F4000A
|
||||||
tkhd (92 bytes):
|
maxInputSize = 85
|
||||||
Data = length 84, hash 8893F5BB
|
width = 12
|
||||||
mdia (442 bytes):
|
height = 10
|
||||||
mdhd (32 bytes):
|
colorInfo:
|
||||||
Data = length 24, hash 50217AD
|
colorSpace = -1
|
||||||
hdlr (44 bytes):
|
colorRange = 1
|
||||||
Data = length 36, hash A0852FF2
|
colorTransfer = -1
|
||||||
minf (358 bytes):
|
hdrStaticInfo = length 0, hash 0
|
||||||
vmhd (20 bytes):
|
metadata = entries=[mdta: key=SomeStringKey, value=10.0, Mp4Timestamp: creation time=2082849800, modification time=2082849800, timescale=10000]
|
||||||
Data = length 12, hash EE830681
|
initializationData:
|
||||||
dinf (36 bytes):
|
data = length 28, hash 410B510
|
||||||
Data = length 28, hash D535436B
|
data = length 9, hash FBADD682
|
||||||
stbl (294 bytes):
|
sample 0:
|
||||||
stsd (166 bytes):
|
time = 0
|
||||||
Data = length 158, hash 11532063
|
flags = 536870913
|
||||||
stts (24 bytes):
|
data = length 55, hash A481CEF4
|
||||||
Data = length 16, hash E4FC6483
|
tracksEnded = true
|
||||||
stsz (24 bytes):
|
|
||||||
Data = length 16, hash 50B7F5B9
|
|
||||||
stsc (28 bytes):
|
|
||||||
Data = length 20, hash 8F6E8285
|
|
||||||
co64 (24 bytes):
|
|
||||||
Data = length 16, hash E4EE4D2E
|
|
||||||
stss (20 bytes):
|
|
||||||
Data = length 12, hash EE911E03
|
|
||||||
|
@ -1,40 +1,32 @@
|
|||||||
ftyp (28 bytes):
|
seekMap:
|
||||||
Data = length 20, hash EF896440
|
isSeekable = true
|
||||||
mdat (71 bytes):
|
duration = 0
|
||||||
Data = length 55, hash 6B19F4A7
|
getPosition(0) = [[timeUs=0, position=44]]
|
||||||
moov (786 bytes):
|
getPosition(1) = [[timeUs=0, position=44]]
|
||||||
mvhd (108 bytes):
|
getPosition(0) = [[timeUs=0, position=44]]
|
||||||
Data = length 100, hash A5ADE288
|
getPosition(0) = [[timeUs=0, position=44]]
|
||||||
meta (128 bytes):
|
numberOfTracks = 1
|
||||||
hdlr (33 bytes):
|
track 0:
|
||||||
Data = length 25, hash C39D0F5B
|
total output bytes = 55
|
||||||
keys (37 bytes):
|
sample count = 1
|
||||||
Data = length 29, hash 45F2DCDF
|
format 0:
|
||||||
ilst (50 bytes):
|
id = 1
|
||||||
Data = length 42, hash F4AA183B
|
sampleMimeType = video/avc
|
||||||
trak (542 bytes):
|
codecs = avc1.F4000A
|
||||||
tkhd (92 bytes):
|
maxInputSize = 85
|
||||||
Data = length 84, hash 8893F5BB
|
width = 12
|
||||||
mdia (442 bytes):
|
height = 10
|
||||||
mdhd (32 bytes):
|
colorInfo:
|
||||||
Data = length 24, hash 50217AD
|
colorSpace = -1
|
||||||
hdlr (44 bytes):
|
colorRange = 1
|
||||||
Data = length 36, hash A0852FF2
|
colorTransfer = -1
|
||||||
minf (358 bytes):
|
hdrStaticInfo = length 0, hash 0
|
||||||
vmhd (20 bytes):
|
metadata = entries=[mdta: key=SomeStringKey, value=Some Random String, Mp4Timestamp: creation time=2082849800, modification time=2082849800, timescale=10000]
|
||||||
Data = length 12, hash EE830681
|
initializationData:
|
||||||
dinf (36 bytes):
|
data = length 28, hash 410B510
|
||||||
Data = length 28, hash D535436B
|
data = length 9, hash FBADD682
|
||||||
stbl (294 bytes):
|
sample 0:
|
||||||
stsd (166 bytes):
|
time = 0
|
||||||
Data = length 158, hash 11532063
|
flags = 536870913
|
||||||
stts (24 bytes):
|
data = length 55, hash A481CEF4
|
||||||
Data = length 16, hash E4FC6483
|
tracksEnded = true
|
||||||
stsz (24 bytes):
|
|
||||||
Data = length 16, hash 50B7F5B9
|
|
||||||
stsc (28 bytes):
|
|
||||||
Data = length 20, hash 8F6E8285
|
|
||||||
co64 (24 bytes):
|
|
||||||
Data = length 16, hash E4EE4D2E
|
|
||||||
stss (20 bytes):
|
|
||||||
Data = length 12, hash EE911E03
|
|
||||||
|
@ -104,7 +104,7 @@ public class TransformerWithInAppMuxerEndToEndTest {
|
|||||||
transformer.start(mediaItem, outputPath);
|
transformer.start(mediaItem, outputPath);
|
||||||
ExportResult exportResult = TransformerTestRunner.runLooper(transformer);
|
ExportResult exportResult = TransformerTestRunner.runLooper(transformer);
|
||||||
|
|
||||||
// TODO(b/270956881): Use FakeExtractorOutput once it starts dumping uuid box.
|
// TODO: b/288544833 - Use FakeExtractorOutput once it starts dumping uuid box.
|
||||||
assertThat(exportResult.exportException).isNull();
|
assertThat(exportResult.exportException).isNull();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user