5060 Commits

Author SHA1 Message Date
ojw28
6cb029d8c1 Merge pull request #818 from pakerfeldt/on-drm-session-ready
Add onDrmSessionReady callback
2015-09-28 11:16:29 +01:00
Patrik Åkerfeldt
95db1eacd1 Add onKeysLoaded callback
This adds a callback for when DRM keys have been loaded.
2015-09-25 10:03:00 +02:00
Oliver Woodman
765d1659be Return "seeked to" position immediately after seek. 2015-09-18 18:25:25 +01:00
Oliver Woodman
c1b8352e33 Stylistic tweaks. 2015-09-18 18:25:07 +01:00
Oliver Woodman
88452d95ee Playback test tweaks. 2015-09-18 18:24:33 +01:00
Oliver Woodman
da97e30e33 Support mp3 media segments in HLS.
Issue #804
2015-09-18 18:23:50 +01:00
Oliver Woodman
c960636d28 Stylistic cleanup. 2015-09-18 18:23:28 +01:00
Oliver Woodman
cf27b83e8a Implement handlesTrack using MediaCodecUtil. 2015-09-18 18:22:40 +01:00
Oliver Woodman
8022d28e04 Make certain we have appropriate locks held for playback tests. 2015-09-18 18:21:26 +01:00
Oliver Woodman
3538e57797 Work around incorrect timestamp handling on Sony Xperia E.
Also include more Sony Xperia Z devices in the MP3 workaround.
2015-09-18 18:20:47 +01:00
Oliver Woodman
6ef8c3a61b Avoid loading the first HLS segment twice.
Issue: #788
2015-09-18 18:20:12 +01:00
Oliver Woodman
8a723706d6 Provide more flexibility for setting caption font size.
- Respect any padding set on SubtitleLayout.
- Allow specification of absolute, fractional and fractional-ignoring-padding
  text sizes.
2015-09-18 18:19:28 +01:00
Oliver Woodman
7f9b12982d Use consistent buffer sizes in demo app. 2015-09-18 18:18:15 +01:00
ojw28
d6801389de Merge pull request #807 from castlabs/feature/parse_audio_channels_only_for_mpeg_dash
Parse audioChannels only when on mpeg-dash
2015-09-18 11:58:28 +01:00
Miquel Beltran
ff6455aadb Parse audioChannels only when on mpeg-dash
Only parse the @value as Int when the schemeIdUri is urn:mpeg:dash:23003:3:audio_channel_configuration:2011
2015-09-18 11:48:34 +02:00
ojw28
de68c982ab Merge pull request #795 from jeoliva/webvtt-parser-improvements
Improve WebVTT parser according to WebVTT spec
2015-09-17 16:34:33 +01:00
ojw28
1be3f9dcbc Merge pull request #796 from souji1103/dev
Prevent ArrayIndexOutOfBoundsException when proguard is enabled
2015-09-17 15:15:59 +01:00
joli
925795cb4f Improve WebVTT parser according to WebVTT spec
- Line parameter
  - Added support for value and line alignment attributes.
  - Support negative numbers when line is an absolute number (not a
percentage).
- Position parameter
  - Added support for value and position alignment attributes
- Added support for WebVTT comment blocks
- Percentage values now accept decimal numbers (as webvtt spec states)
- Added new WebVTT tests for testing all new implemented features
2015-09-16 21:09:44 +02:00
souji
e2ed741ddd prevented excess loop, reading pes header 2015-09-16 09:04:04 +09:00
Oliver Woodman
d7697176ed Include language in audio formats.
Issue: #437
2015-09-15 13:45:54 +01:00
Oliver Woodman
b6f15a17e0 TTML improvements.
- do not denormalize styles at parsing time but only put normalized style info
into TtmlNode tree. Resolve styles on demand when Cues are requested for a
given timeUs.
- create TtmlRenderUtil to have static render functions separate
- added unit test for TtmlRenderUtil
- adjusted testing strategy for unit test to check resolved style on Spannables after rendering
2015-09-15 13:44:52 +01:00
Oliver Woodman
908e4dfd5d Search for synch' when sniffing ADTS and check four frames.
Issue: #791
2015-09-15 13:43:42 +01:00
Oliver Woodman
721956710f Remove MediaFormat.create methods that don't take a duration. 2015-09-15 13:43:12 +01:00
Oliver Woodman
e7926145c6 Fix overflow for DASH live streams using large timescales.
Issue: #789
2015-09-15 13:42:16 +01:00
Oliver Woodman
74186c2cd0 Try harder before allowing playback tests to fail. 2015-09-15 13:42:01 +01:00
Oliver Woodman
ab46d263ad Use decoders with names that don't start "OMX.".
There is no guarantee codec names start with this prefix in >= L.

Issue: #782
2015-09-15 13:41:42 +01:00
Oliver Woodman
5050913ba0 Update release notes. 2015-09-10 19:19:17 +01:00
Oliver Woodman
e6e1e2c1d1 Tweaking TTML parsing logic. 2015-09-10 19:03:40 +01:00
Oliver Woodman
04342f2b76 Don't use toLowerCase :).
It can do weird things if the device has an unusual default Locale.
Util.toLowerInvariant uses the US Locale, which does the right thing
in this case.
2015-09-10 18:31:08 +01:00
Oliver Woodman
eeb73a86ea Improve sniffer behavior for fragmented MP4.
- Allow a moof box to exceed the search size.
- Return immediately after reading an ftyp box with no compatible types.

Issue: #784
2015-09-10 18:30:47 +01:00
Oliver Woodman
6f9019a4e3 Use DTS to set timestamp adjustment where available.
Partial fix for #778
2015-09-10 18:30:13 +01:00
Oliver Woodman
1f3bd97a2d Add non-strict SubRip parsing (enabled by default). 2015-09-10 18:29:36 +01:00
Oliver Woodman
ede7a69d95 Change DTS MIME type to vnd.dts. 2015-09-10 18:28:50 +01:00
Oliver Woodman
ab66dfa7c2 Parsing embedded TTML styling. 2015-09-10 18:27:03 +01:00
Oliver Woodman
95fcb3b411 Draw subtitles over the shutter.
This allows the demo app to display subtitles without video
(when there's no video, the shutter view does not hide itself).
2015-09-10 18:24:31 +01:00
Oliver Woodman
e48851d8cc Share PTS timestamp adjustment across format changes.
When switching format in HLS, we instantiate a new extractor, which
adjusts TS presentation timestamps so that they align properly with
the start of the first segment in the new format. Some HLS streams
appear to have slightly misalignment that causes a glitch when using
this approach.

It's better to re-use the same timestamp adjustment across formats,
and only reset it when seeking or when there's an actual discontinuity.
This is because the HLS spec guarantees PTS timestamp alignment across
different formats.

We'll also need something like PtsTimestampAdjuster to share between
separated audio and WebVTT tracks, which also contain PTS timestamps
that are aligned, and will need to share a common adjustment.

Issue: #692
2015-09-10 18:23:57 +01:00
Oliver Woodman
7d38d2ef3c CuePainter fixes for caption styling.
- Don't allow "nothing has changed" optimization in the case
  that only styling has changed (TextUtils.equals will return
  true in this case, but we shouldn't optimize).
- Add functionality to suppress embedded styling; seems useful
  to have.
- Added "this." for clarity.
2015-09-10 18:22:44 +01:00
Oliver Woodman
68f2dc5998 Remove MultiTrackChunkSource (multi track now supported directly). 2015-09-10 18:22:07 +01:00
Oliver Woodman
e6ca2df514 Fix end-of-stream for live streams.
Issue: #764
2015-09-10 18:21:21 +01:00
Oliver Woodman
89fcafec5b Correctly set a format duration. 2015-09-10 18:20:07 +01:00
Oliver Woodman
820433de06 Call stop() to fully play out remaining audio!
Issue: #707
2015-09-10 18:19:09 +01:00
Oliver Woodman
9bcc00f369 Fix reported buffered position for HLS across format switches. 2015-09-10 18:16:42 +01:00
Oliver Woodman
a7ba393d54 When multiple BaseURL elements are present, prefer the first one.
Issue: #771
2015-09-10 18:16:23 +01:00
Oliver Woodman
4a29be498b Correctly use "current-manifest-live" v.s. "stream-is-live"
When a live stream ends, what typically happens is that the manifest
is refreshed and the refreshed version is not marked as live/dynamic.
When this happens we:

1. Don't want the duration of the track to change.
2. Still want to consider the possibility that we may have fallen behind
   the live window.
3. Don't want to allow futher manifest refreshes.

This change uses the right thing in the right place.
2015-09-10 18:15:15 +01:00
Oliver Woodman
143a4deee8 If no buffers were queued, handle EoS directly.
Issue: #707
2015-09-10 18:12:32 +01:00
Oliver Woodman
59a789b340 Include missing durations in AC3/DTS formats. 2015-09-10 18:11:18 +01:00
ojw28
e13e23e3e0 Merge pull request #776 from IanDBird/srt-fix
Ignore extra returns in Subrip parsing
2015-09-09 14:31:49 +01:00
Ian Bird
4b69fad6b7 Ignore extra returns in Subrip parsing 2015-09-09 11:56:10 +01:00
Oliver Woodman
5c0745cedf Add some generally useful error propagation logic for HLS.
Issue #765
2015-09-07 13:59:55 +01:00
Oliver Woodman
fb8f0113c6 Hide captions when the track is disabled.
Issue #763
2015-09-07 13:59:18 +01:00