181 Commits

Author SHA1 Message Date
bachinger
f609fecf9b Parse BaseURL element including DVB attributes in DASH manifest
This change parses the entire BaseURL element including DVB extension attributes, stores it in an instance of new BaseUrl class and puts it in a list of base URLs of the resulting Representation. The base url handling itself is still the same, which means that only the first base url is taken into account, just as before this change.

PiperOrigin-RevId: 380609495
2021-06-21 22:28:17 +01:00
claincly
b05e8f5090 Add RTP streaming test to playback test.
The test prepare_withSupportedTrack_playsTrackUntilEnded

- sets up the supported AAC track with the RTSP server;
- uses RtpPacketTransmitter to send RTP packets from the server to the client;
- runs the player until the playback has ended, and
- asserts on the data RTSP has received and queued to the SampleQueue.

In the test, it was necessary to create a FakeUdpDataSourceRtpDataChannel. The
reason we cannot reuse TransferRtpDataChannel is, we rely on BlockingQueue.poll
timeout to identify the end of an RTSP stream, but the time out mechanism is
unstable in Robolectric. For example, when the timeout is set to 8,000 ms, the
actual timeout occasionally happens after 2,000,000 ms (in FakeClock).

PiperOrigin-RevId: 380528710
2021-06-21 22:20:47 +01:00
claincly
8cc1328d89 Allow customizing the RtspServer using RtspServerResponseProvider.
PiperOrigin-RevId: 379282201
2021-06-15 18:31:58 +01:00
claincly
1dddb8eb1e Allow RtspServer read a RTP dump file.
#minor-release

PiperOrigin-RevId: 377001305
2021-06-02 18:11:27 +01:00
aquilescanta
85e4137b81 Add test for ColorInfo in MP4
PiperOrigin-RevId: 375992816
2021-05-27 10:44:50 +01:00
Kei Murayama
f05197c4d5 Support parsing MPEG-H 3D Audio
First intention to support parsing MPEG-H 3D Audio in ExoPlayer is to
take advantage of parsing capability from MediaParser API in AOSP.
Just with this change ExoPlayer does't support decoding MPEG-H 3D Audio
but can support decoding either by adding decoder with an extension or
by using Android OS which has decoder capability with MediaCodec API.
2021-05-10 17:55:03 +09:00
dlafayet
8c7d6447c0 Merge #8858: Support ebutts:multiRowAlign in TTML text renderer
Imported from GitHub PR https://github.com/google/ExoPlayer/pull/8858

Fix bug in text alignment inheritance where child does not correctly inherit ancestor's setting

@icbaker
Merge 70eb4bceb73b3f07e2f8d545b4fa7961189ac52a into 45616f916b28c9187b3e0f0dd18797464a079cdc

COPYBARA_INTEGRATE_REVIEW=https://github.com/google/ExoPlayer/pull/8877 from dlafayet:multirowalign-cue d942b50a40525fea5d11b35a33d3bbc512550960
PiperOrigin-RevId: 371306966
2021-04-30 18:54:13 +01:00
bachinger
99492902c0 Merge pull request #8877 from dlafayet:textAlign
PiperOrigin-RevId: 371306900
2021-04-30 18:53:54 +01:00
ibaker
f56c1a1253 SSA: Add a test with a present but empty "Style" line
PiperOrigin-RevId: 370897451
2021-04-28 17:32:56 +01:00
Denise LaFayette
5ef0ba4171 Fix bug in TTML inherited text alignment
Fix bug where child does not correctly inherit ancestor's text
alignment setting.

Make it so that alignment is only applied on a P node.
https://www.w3.org/TR/2018/REC-ttml2-20181108/#style-attribute-textAlign
2021-04-27 11:29:37 -07:00
Abel Jimenez
852101a43f initial commit for underline and strikeout 2021-04-21 18:19:38 -07:00
ibaker
84282d7c32 Parse DASH forced_subtitle role
#minor-release

Issue: #8781
PiperOrigin-RevId: 368212289
2021-04-13 18:01:20 +01:00
ibaker
9e0e937c31 Remove pipelining from MetadataRenderer
This reverts
<unknown commit>

Which was a temporary workaround for Issue: #1874

Also add a loop to ensure we process as many metadata items as
applicable in each render() call.

PiperOrigin-RevId: 366965504
2021-04-06 16:14:36 +01:00
ibaker
af926deb7a Use outputStreamEnded for MetadataRenderer#isEnded
Issue: #8710
#minor-release
PiperOrigin-RevId: 366051836
2021-04-01 16:06:09 +01:00
ibaker
056ef5c914 Use Metadata.Entry.toString in PlaybackOutput test logging if possible
Add an allowlist of Metadata.Entry implementations with stable toString
overrides.

PiperOrigin-RevId: 366037505
2021-04-01 16:05:44 +01:00
ibaker
c02288452b Add test for emsg near to end of DASH period
The dumped output should include metadata, but doesn't because of
Issue: #8710. The fix is in a follow-up change.
PiperOrigin-RevId: 366028303
2021-04-01 16:05:27 +01:00
Oliver Woodman
6603c6bbcf Merge pull request #8720 from dlafayet:tts-shear-block
PiperOrigin-RevId: 365998615
2021-04-01 16:05:00 +01:00
Denise LaFayette
4be774aaac Support tts:shear in TTML parser and WebView output 2021-03-24 12:39:44 -07:00
kimvde
2c76bc5a4c JpegExtractor: support JFIF segment preceding Exif segment
#minor-release

PiperOrigin-RevId: 364561115
2021-03-24 18:06:16 +00:00
Ian Baker
6c688891e3 Merge pull request #8653 from dlafayet:textemphasis
PiperOrigin-RevId: 364363882
2021-03-24 18:05:46 +00:00
Ian Baker
c3e3b19ad2 Merge pull request #8654 from abeljim:dev-v2-8435-bolditalic
PiperOrigin-RevId: 361767801
2021-03-12 10:40:58 +00:00
Denise LaFayette
4ad6454713 Address code review comments
- Refactor TextEmphasis class to support different ordering of styles
- Merge RubySpan.Position and TextEmphasisSpan.Position
- Remove TTML constructs from Spanned classes
2021-03-04 15:49:28 -08:00
Ian Baker
d80d548503
Merge branch 'dev-v2' into dev-v2-8435-bolditalic 2021-03-04 09:41:39 +00:00
ibaker
34d76a793b Make SsaDecoder robust against absent Format items
Suggested in a comment on PR Issue: #8615

PiperOrigin-RevId: 359522217
2021-03-02 17:02:15 +00:00
Abel Jimenez
ec69977a1c ssa bold and italic 2021-03-01 15:55:34 -08:00
Abel Jimenez
71409c440a ssa bold and italic 2021-03-01 15:52:24 -08:00
Denise LaFayette
fcda8d47ff Support tts:textEmphasis in TTML parser and WebView output 2021-03-01 14:21:22 -08:00
marcbaechinger
4ed36e19cf Merge pull request #8615 from szaboa:dev-v2-8435-ssa-font-size
PiperOrigin-RevId: 359244236
2021-02-24 15:46:44 +00:00
Arnold Szabo
9c35d76184 Parse font size into float, and fallback to Cue.DIMEN_UNSET instead of null. 2021-02-22 20:33:12 +01:00
kimvde
da52de669c Avoid skipping the first decoder output buffers after speed change
#minor-release

PiperOrigin-RevId: 355652144
2021-02-04 18:14:35 +00:00
andrewlewis
c3bce234ca Improve format propagation in transformer
- Store output format in `MediaCodecAdapterWrapper` when we get a format from
  the codec, instead of creating it on demand.
- Make format building code not audio-specific.
- Remove `MediaCodecAdapterWrapper.getConfigFormat` and instead keep track of
  the input/output formats in the renderer. This will mean that the code still
  works if an audio processor changes the audio format in future.
- Make exceptions thrown during audio rendering use the same (input) renderer
  format.
- Misc other minor cleanup.

#minor-release

PiperOrigin-RevId: 354556619
2021-02-01 18:11:04 +00:00
andrewlewis
afb41123c2 Switch transformer tests to use dump files
Add an interface to muxers to allow tests to pass a dumpable muxer.

#minor-release

PiperOrigin-RevId: 354543388
2021-02-01 18:10:55 +00:00
Oliver Woodman
c9fce083f3 Merge pull request #8490 from szaboa:dev-2-8435-ssa-color
PiperOrigin-RevId: 354293679
2021-02-01 18:10:35 +00:00
Arnold Szabo
28a3921a6a Add color decoding tests to SsaDecoderTest, remove SubStation Alpha colors" from media.exolist.json. 2021-01-26 22:57:10 +01:00
kimvde
0d85958a76 Fix parsing of Vorbis codec private
- Fix comparison between a byte and 0xFF to avoid conversion of 0xFF to
  byte and to int again (due to numeric promotion).
- Fix addition of int and byte with most significant bit set. The byte
  was incorrectly promoted to an int negative value.

Issue:#8496
#minor-release
PiperOrigin-RevId: 353865751
2021-01-26 15:59:41 +00:00
tonihei
737630740c Add WAV playback tests.
The output dumps are intentionally empty because the playback
is using bypass modes.

Still adding a AUDIO_RAW decoder to the ShadowMediaCodecConfig to
ensure that we would output samples if bypass mode were disabled.

PiperOrigin-RevId: 352794959
2021-01-22 16:20:44 +00:00
andrewlewis
981826555c Add support for playing JPEG motion photos
PiperOrigin-RevId: 352413375
2021-01-18 22:00:36 +00:00
olly
4359016145 Fix disabling of bypass
PiperOrigin-RevId: 352403189
2021-01-18 22:00:28 +00:00
andrewlewis
9b062053fa Add support for JPEG motion photo extraction
PiperOrigin-RevId: 351752989
2021-01-15 10:56:07 +00:00
andrewlewis
a7b20fd133 Rollback of 59aec416af
*** Original commit ***

Rollback of ff8c8645ab

*** Original commit ***

Merge #8401: Initialize Format.codecs from HEVC SPS NAL unit (#8393)

Imported from GitHub PR https://github.com/google/ExoPlayer/pull/8401

This will allow ExoPlayer to check if video track's profile and level are supported by decoder when playing progressive media so...

***

PiperOrigin-RevId: 351139861
2021-01-11 18:05:34 +00:00
olly
59aec416af Rollback of ff8c8645ab
*** Original commit ***

Merge #8401: Initialize Format.codecs from HEVC SPS NAL unit (#8393)

Imported from GitHub PR https://github.com/google/ExoPlayer/pull/8401

This will allow ExoPlayer to check if video track's profile and level are supported by decoder when playing progressive media sources.
Merge e582fb91b73c7c95e754167140211d5473c36d14 into 1347d572ef9ce79aacd667cfffa7d7468c8408a4

Issue: #8393

***

PiperOrigin-RevId: 350871621
2021-01-11 18:04:22 +00:00
Alexey Rochev
ff8c8645ab Merge #8401: Initialize Format.codecs from HEVC SPS NAL unit (#8393)
Imported from GitHub PR https://github.com/google/ExoPlayer/pull/8401

This will allow ExoPlayer to check if video track's profile and level are supported by decoder when playing progressive media sources.
Merge e582fb91b73c7c95e754167140211d5473c36d14 into 1347d572ef9ce79aacd667cfffa7d7468c8408a4

Issue: #8393
COPYBARA_INTEGRATE_REVIEW=https://github.com/google/ExoPlayer/pull/8401 from equeim:hevc-codecs e582fb91b73c7c95e754167140211d5473c36d14
PiperOrigin-RevId: 350738065
2021-01-08 15:33:09 +00:00
tonihei
1ef06b8d92 Rename sample_mpd to sample_mpd_live
This helps to better disambiguate the file from other mpd files in the
directory.

PiperOrigin-RevId: 350552168
2021-01-08 15:32:26 +00:00
bachinger
6e8af81ddc Reload HLS media playlist when merging delta update fails
Issue: #5011
PiperOrigin-RevId: 350550204
2021-01-08 15:31:54 +00:00
tonihei
2c925a4109 Fix MIGHT_NOT_USE_FULL_NETWORK_SPEED for VOD DASH streams.
The flag compared against the nowTime in the period that is only
set to a positive value for live streams.

PiperOrigin-RevId: 350514934
2021-01-07 10:44:53 +00:00
Ian Baker
a9a150a1d3 Merge pull request #8397 from equeim:avc-codecs
PiperOrigin-RevId: 350105847
2021-01-05 12:00:21 +00:00
andrewlewis
47b95fe9e1 Remove duplicate xmlns attributes in testdata
PiperOrigin-RevId: 350100601
2021-01-05 12:00:09 +00:00
olly
5f3d1c1bc8 Fix bypass mode when the stream is empty
#minor-release
Issue: #8374
PiperOrigin-RevId: 348792965
2020-12-23 22:53:50 +00:00
olly
e71ce06722 Add e2e test for playing SilenceMediaSource
PiperOrigin-RevId: 348789555
2020-12-23 22:53:41 +00:00
ibaker
0d1dac93c4 Use CapturingRenderersFactory in DashPlaybackTest
PiperOrigin-RevId: 348018409
2020-12-23 22:50:33 +00:00