ibaker
3cf21bd5d5
Require the list returned by SubtitleParser
to be sorted by timestamp
...
This makes it more efficient to consume (e.g. we can binary search
through it).
PiperOrigin-RevId: 539095673
2023-06-10 20:21:29 +00:00
sheenachhabra
53c174f047
Add support for passing custom metadata via transformer
...
Changes included:
1. Enable MP4 extractor to read all types of metadata.
2. Allow passing String and Float metadata via Transformer.
Reference to QuickTime spec: https://developer.apple.com/library/archive/documentation/QuickTime/QTFF/Metadata/Metadata.html#//apple_ref/doc/uid/TP40000939-CH1-SW21
PiperOrigin-RevId: 538783982
2023-06-09 13:51:15 +00:00
sheenachhabra
7e14811e25
Add support for passing creation time via InAppMuxer
...
PiperOrigin-RevId: 538175466
2023-06-06 18:12:51 +00:00
tianyifeng
f4bf376e89
Defer outputting the metadata sample when TimestampAdjuster isn't initialized
...
The sample timestamp carried by the emsg box can have a significant delta when comparing to the earliest presentation timestamp of the segment. Using this timestamp to intialize the timestamp offset in TimestampAdjuster will cause the media sample to have a wrong adjusted timestamp. So we should defer adjusting the metadata sample timestamp until the TimestampAdjuster is initialized with a real media sample.
PiperOrigin-RevId: 538172841
2023-06-06 18:10:41 +00:00
Googler
83e9080b71
Override ParserException#getMessage
...
PiperOrigin-RevId: 537908595
2023-06-06 18:05:33 +00:00
ibaker
79b721e411
Define the SubtitleParser
interface
...
We will migrate concrete implementations of `SubtitleDecoder` to implement
this instead.
PiperOrigin-RevId: 537298600
2023-06-05 09:49:26 +00:00
Tianyi Feng
9d147f2227
Adjust the comment lines
2023-05-25 09:58:07 +00:00
Tianyi Feng
f69718e5ad
Fix the lint issues
2023-05-25 09:58:07 +00:00
Tianyi Feng
47b0726ea9
Format with google-java-format
2023-05-25 09:55:10 +00:00
Cedric T
c984387248
Re-word comments for new DTS Sync words in DtsUtil.java.
2023-05-25 09:55:10 +00:00
Cedric T
3b9d680914
Add comments for DTSUtil.java
2023-05-25 09:55:09 +00:00
Cedric T
b73d2cc736
Add direct passthrough support for DTS audio.
2023-05-25 09:55:09 +00:00
christosts
b9a4e614f7
Fix seeking bug in opus
...
Fix a bug when seeking in an opus container. The calculations inside
DefaultOggSeeker may overflow a long primitive.
Issue: androidx/media#391
#minor-release
PiperOrigin-RevId: 534128513
2023-05-24 15:44:49 +01:00
sheenachhabra
b382a7c2da
Move MdtaMetadataEntry class into container module
...
This class is to be shared between extractor, transformer
and muxer module.
PiperOrigin-RevId: 533490888
2023-05-24 15:29:23 +01:00
sheenachhabra
7b62b33127
Move Mp4LocationData from extractor module to container module
...
This class will be shared between extractor and muxer module.
PiperOrigin-RevId: 532784415
2023-05-17 16:37:57 +01:00
sheenachhabra
e0d6f67dd9
Move NAL unit related methods from common to container module
...
PiperOrigin-RevId: 532750099
2023-05-17 16:32:46 +01:00
huangdarwin
82ede47398
media3: Capitalize "MIME" for MIME types.
...
Find and replace "mime" to "MIME", where appropriate, throughout media3.
PiperOrigin-RevId: 531122121
2023-05-11 10:05:01 +00:00
michaelkatz
06ac2f7990
Add UTF-16 encoded subtitle support to SsaDecoder
...
Issue: androidx/media#319
PiperOrigin-RevId: 527891646
2023-05-03 17:04:35 +01:00
Ian Baker
fab134f0b3
Merge pull request #313 from pengbins:fix_ts_h265reader_parse_sps
...
PiperOrigin-RevId: 527259619
2023-04-26 15:53:58 +01:00
Ian Baker
171c224bc6
Add a release note for MPEG-TS H.265 SPS parsing fix
...
Also clean-up a comment about skipping the NAL start code
2023-04-25 18:17:44 +01:00
Ian Baker
e88fa7c52e
Reformat with google-java-format
2023-04-25 09:15:26 +01:00
peng bin
d7acae20c0
Use parseH265SpsNalUnit instead of parseH265SpsNalUnitPayload
...
To consistent with the other callsites of NalUnitUtil for parsing H265 SPS
2023-04-25 09:15:26 +01:00
peng bin
6ae8c8c041
Use NalUnitUtil.parseH265SpsNalUnitPayload when parsing MPEG-TS files
...
This implicitly fixes a bug by removing the buggy implementation in H265Reader in favour of a working one. This change also adds tests to confirm the parsing bug is fixed.
2023-04-25 09:15:25 +01:00
peng bin
114020c2d8
Fix previousNumDeltaPocs in skipShortTermRefPicSets
2023-04-25 09:15:25 +01:00
Ian Baker
75d81c7630
Derive previousNumDeltaPocs from numNegativePics and numPositivePics
...
This more closely matches the equations in equations 7-61 and 7-62 in
See H.265/HEVC (2014) section 7.4.8.
2023-04-25 09:15:25 +01:00
peng bin
a65b5a5c2b
Fix previousNumDeltaPocs in skipShortTermRefPicSets
2023-04-25 09:15:25 +01:00
peng bin
b08120d752
Fix used_by_curr_pic_flag to align with H.265 spec
2023-04-25 09:15:25 +01:00
peng bin
bc0dc01a69
Add a test sample for ts+h265
2023-04-25 09:15:25 +01:00
rohks
8a73d8d3fe
Add support to fetch ColorInfo
from avcC
box in AtomParsers
...
#minor-release
PiperOrigin-RevId: 526082823
2023-04-24 11:37:55 +01:00
rohks
596a7c7033
Update colr
box values to be overridden by bitstream boxes
...
#minor-release
PiperOrigin-RevId: 523983688
2023-04-13 16:30:45 +01:00
ibaker
642d34ffc7
Update comment on Track.nalUnitLengthFieldLength
...
This field is also non-zero for h.265 tracks.
PiperOrigin-RevId: 523676455
2023-04-12 17:01:21 +01:00
sheenachhabra
28aa5e847b
Move NAL unit utility classes into common
...
Need to use NAL unit util methods in muxer module.
PiperOrigin-RevId: 521772831
2023-04-05 15:45:35 +01:00
ibaker
43ad45dbef
Remove all RawCC references from media3
...
RawCC is a Google-internal subtitle format that is no longer directly
supported by this library (since 4f616d6003
).
PiperOrigin-RevId: 520591591
2023-03-30 17:25:20 +00:00
sheenachhabra
669008f437
Use FakeExtractorOutput in Mp4MuxerMetadataTest
...
The FakeExtractorOutput dumps data in more readable format
so using that where ever possible.
The MdtaMetadataEntry which contains key and value dumped only "key".
Added fix to dump "value" as well.
PiperOrigin-RevId: 517968996
2023-03-21 14:19:12 +00:00
Rohit Singh
0e3f407e0e
Merge pull request #11064 from haixia-meta:release-v2
...
PiperOrigin-RevId: 517128752
2023-03-16 15:37:02 +00:00
rohks
8a5fcf82d3
Add support to fetch ColorInfo
from hvcc
box in AtomParsers
...
#minor-release
PiperOrigin-RevId: 517086016
2023-03-16 15:34:28 +00:00
Rohit Singh
49d85d625c
Merge pull request #11061 from cedricxperi:dts-udts-support
...
PiperOrigin-RevId: 517067549
2023-03-16 15:33:38 +00:00
sheenachhabra
2f01f9c53b
Add support for reading location data in MP4 extractor
...
The geodata is stored in the "udta" box as per MediaMuxer reference
https://cs.android.com/android/platform/superproject/+/master:frameworks/av/media/libstagefright/MPEG4Writer.cpp;drc=master;l=5588
PiperOrigin-RevId: 515095127
2023-03-14 07:46:28 +00:00
ibaker
cb7d565fd4
Add missing @param
tags
...
Dackka generates a warning if a method has at least one `@param` tag,
but not all of them are documented.
#minor-release
PiperOrigin-RevId: 513873453
2023-03-07 11:49:24 +00:00
tonihei
17499cefcc
Merge pull request #255 from mayurk2:use_edts_offset_if_it_is_for_entire_file
...
PiperOrigin-RevId: 513213229
2023-03-01 17:27:15 +00:00
ibaker
1c4ba5d9f6
Delete VorbisUtil.CodeBook since it's not used
...
PiperOrigin-RevId: 513186205
2023-03-01 17:26:31 +00:00
ibaker
c07cf3dc41
Remove @see tags with <a> tags
...
These are not supported by Dackka
#minor-release
PiperOrigin-RevId: 513176533
2023-03-01 17:25:48 +00:00
Mayur K
0761641d9f
Use edts media time offset if edits list duration is entire media duration.
2023-02-24 18:18:16 +05:30
michaelkatz
4854e771d7
Encapsulate Opus frames in Ogg during audio offload
...
PiperOrigin-RevId: 508053559
2023-02-08 14:12:06 +00:00
tonihei
00436a04a4
Fix timestamp comparison for seeks in fMP4
...
When seeking in fMP4, we try to extract as little samples as possible
by only starting at the preceding sync frame. This comparison should
use <= to allow sync frames at exactly the seek position.
Issue: google/ExoPlayer#10941
#minor-release
PiperOrigin-RevId: 505098172
2023-02-01 10:26:52 +00:00
rohks
6c14ffc1ec
Fix javadoc references to writeSampleData
...
PiperOrigin-RevId: 502821506
2023-01-18 12:05:08 +00:00
Googler
d8ea770e9b
Throw a ParserException instead of a NullPointerException if the sample table (stbl) is missing a required sample description (stsd).
...
As per the javadoc for AtomParsers.parseTrack, ParserException should be "thrown if the trak atom can't be parsed."
PiperOrigin-RevId: 499522748
2023-01-04 21:58:17 +00:00
Googler
c14b250445
Temporal fix to allow proper library shrinking.
...
PiperOrigin-RevId: 492579961
2022-12-12 11:10:18 +00:00
ibaker
3efc62b512
Deprecate C.POSITION_UNSET
in favour of C.INDEX_UNSET
...
These have the same value (`-1`), and basically the same meaning (offset
in an array/list/file/byte stream/etc), but 'position' is an overloaded
term in a media playback library, and there's a risk people assume that
methods like `Player.getCurrentPosition()` may return
`C.POSITION_UNSET`, when in fact unset media times (whether duration or
position) are always represented by `C.TIME_UNSET` which is a) a `long`
(not `int`) and b) a different underlying value. (aside:
`getCurrentPosition()` never returns an unset value, but it's a good
example of the ambiguity of the word 'position' between 'byte offset'
and 'media timestamp'.)
PiperOrigin-RevId: 492493102
2022-12-12 11:09:18 +00:00
ibaker
e4fb663b23
Split SubripDecoder and ParsableByteArray tests
...
In some cases we split a test method, and in other cases we just add
line breaks to make the separation between arrange/act/assert more
clear.
PiperOrigin-RevId: 492182769
2022-12-12 10:57:18 +00:00