3732 Commits

Author SHA1 Message Date
olly
82edf01c22 Re-use single session when multiSession disabled
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=173098862
2017-10-27 15:55:46 +01:00
andrewlewis
9306b24c65 Fix some Android Studio inspection warnings
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=173085316
2017-10-27 15:54:17 +01:00
eguven
9568802c6d Persist DownloadActions in DownloadManager
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=172875067
2017-10-27 15:52:41 +01:00
Drew Hill
2081667591 cleanups for videoframereleasetimehelper 2017-10-24 11:19:26 -04:00
ojw28
ab6f9aea5b Merge pull request #3381 from google/dev-v2-r2.5.4
r2.5.4
2017-10-20 18:54:45 +01:00
Drew Hill
3830307cd3 fix not initialized error 2017-10-19 20:28:49 -04:00
Drew Hill
84afad0748 adjustments 2017-10-19 16:24:41 -04:00
olly
04862bccc8 Bump to 2.5.4
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=172758309
2017-10-19 18:25:21 +01:00
olly
c2d05f4405 Bump to 2.5.4
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=172758309
2017-10-19 18:10:27 +01:00
Drew Hill
feff4d3e02 fix missing cause of display refresh rate changing between videoframereleasetimehelper constructor and enable being called 2017-10-19 12:49:51 -04:00
Oliver Woodman
9a52d63271 Fix build 2017-10-19 17:48:07 +01:00
andrewlewis
69ec60e0f1 Fix seeking with repeated periods
newPlayingPeriodHolder could be set then updated if seeking to a repeated period
that was loaded more than once. This led to MediaPeriodHolders leaking.

Only set newPlayingPeriodHolder once so that any later holders with the same
period identifier get released.

Also add a regression test. FakeMediaSource checks that all created
MediaPeriods were released when it is released.

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=172591937
2017-10-19 17:44:46 +01:00
olly
5357726a8c Add some additional device specific workarounds
Issue: #3355
Issue: #3257

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=172587141
2017-10-19 17:41:40 +01:00
olly
e54841436b Workaround Samsung tablet reboot playing adaptive secure content
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=169256059
2017-10-19 17:40:21 +01:00
aquilescanta
9ea8a8a714 Update HLS sample streams
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=172722536
2017-10-19 17:35:43 +01:00
andrewlewis
006263e983 Retain playback position on re-preparation
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=172736350
2017-10-19 17:35:16 +01:00
Oliver Woodman
64b928e77f Stylistic cleanup 2017-10-19 17:28:24 +01:00
ojw28
28bd4661ed Merge pull request #3371 from andymiao858/dev-v2
Fix FLV AVCVIDEOPACKET  CTS Type Issue
2017-10-19 17:23:50 +01:00
ojw28
24cca8070e Merge pull request #3378 from Miha-x64/patch-2
Removed useless parentheses
2017-10-19 17:23:28 +01:00
eguven
7d0ec68d86 Put DownloadTasks on hold until preceding conflicting tasks are complete
Tasks conflict if both of them work on the same media and at least one
of them is remove action.

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=172741795
2017-10-19 16:52:43 +01:00
andrewlewis
bb3dea5191 Remove USE_CHORD_PITCH
We have been using USE_CHORD_PITCH == false for a while and the quality of
pitch changes seems fine. It's now possible to set the sample rate too, but
this only works if USE_CHORD_PITCH is false, so remove the constant.

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=172736631
2017-10-19 16:51:29 +01:00
andrewlewis
08706f9bfb Retain playback position on re-preparation
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=172736350
2017-10-19 16:50:04 +01:00
olly
d09f872179 Fix positions passed to TrackSelection
- When transitioning to a new period, the value of bufferedDurationUs
  passed to TrackSelection.updateSelectedTrack was incorrectly set to
  0. It should have been set to correctly reflect buffered media in
  previous periods still being played out.
- This change fixes the issue described above, and also propagates the
  playback position through to this method. The position of the next
  load within the period can be calculated by adding the position and
  bufferedDurationUs.

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=172736101
2017-10-19 16:48:39 +01:00
aquilescanta
2cfc478c3e Allow extractor injection for HLS
Issue:#2748

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=172726367
2017-10-19 16:47:04 +01:00
andrewlewis
49aca6e9ce Fix typo in variable name
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=172724250
2017-10-19 16:45:41 +01:00
aquilescanta
daf9c8d19a Update HLS sample streams
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=172722536
2017-10-19 16:44:18 +01:00
andrewlewis
eb08e1a5c3 Work around AudioTrack Bluetooth connection issue
If connecting a Bluetooth audio device fails, the AudioTrack may be left in a
bad state, where it is not actually playing and its position has jumped back to
zero. Detect and work around this case by resetting the track.

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=172600912
2017-10-19 16:42:52 +01:00
olly
b8ef1dcc78 Fix MediaPeriod position param Javadoc.
prepare and selectTracks receive the position from which any
loading should start, where-as continueLoading receives the
actual playback position. These are different in the case that
a previous period is still being played out.

Also removed "relative to the start of the period" from prepare
documentation because it couldn't really be relative to anything
else.

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=172592769
2017-10-19 16:41:23 +01:00
andrewlewis
1e79d6eb84 Fix seeking with repeated periods
newPlayingPeriodHolder could be set then updated if seeking to a repeated period
that was loaded more than once. This led to MediaPeriodHolders leaking.

Only set newPlayingPeriodHolder once so that any later holders with the same
period identifier get released.

Also add a regression test. FakeMediaSource checks that all created
MediaPeriods were released when it is released.

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=172591937
2017-10-19 16:39:57 +01:00
olly
fc5e8ee516 Add some additional device specific workarounds
Issue: #3355
Issue: #3257

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=172587141
2017-10-19 16:37:10 +01:00
苗华栋(Rabbit)
69e50a43a8 add readSignedInt24 in ParsableByteArray 2017-10-19 23:18:12 +08:00
Mike
276087c532 Removed useless parentheses 2017-10-19 14:23:50 +03:00
miaohuadong
5895884c53 Fix bug 2017-10-19 14:10:18 +08:00
苗华栋(Rabbit)
4f8f87221e Fix FLV AVCVIDEOPACKET -> compositionTimeMs Type from UI 24 to SI 24 2017-10-18 23:03:26 +08:00
andrewlewis
ce0a03dbdf Add an extractor flag for ignoring edit lists
Issue: #3358

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=172464053
2017-10-17 19:01:24 +01:00
olly
aa42d3c910 We're not playing an ad if the timeline is empty.
Issue: #3334

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=172447125
2017-10-17 19:01:18 +01:00
olly
f6d0dae50e Workaround/Fix #3351
1. Ignore edit list where the sequence doesn't contain a sync
   sample, rather than failing.
2. Make Mp4Extractor.readAtomPayload so it doesn't try and read
   the same payload twice if a failure occurs parsing it.
3. Make processAtomEnded so that it doesn't pop the moov if
   parsing it fails.

Issue: #3351

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=172106244
2017-10-17 19:00:52 +01:00
andrewlewis
f9249d23ea Add an extractor flag for ignoring edit lists
Issue: #3358

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=172464053
2017-10-17 18:28:39 +01:00
olly
2c10e6f1c3 We're not playing an ad if the timeline is empty.
Issue: #3334

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=172447125
2017-10-17 18:27:26 +01:00
tonihei
f6821c6d95 Split playbacktests mobile_test into multiple version-dependent test targets.
MobileHarness allocates random devices for each test and repeats tests up to 5 times to
account for spurious test failures. Some of our tests automatically pass for SDK versions
below a certain threshold. Thus, even if such a version-guarded test would always fail,
the MobileHarness test is likely to succeed as it only needs one random allocation to a
device with a lower SDK version.

To prevent this behaviour and to make sure all tests are actually run, the mobile_test
target is split into multiple targets one for each minimum SDK version.

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=172447046
2017-10-17 18:26:11 +01:00
andrewlewis
ac31dc7c7a Allow setting output sample rate in SonicAudioProcessor
This is not really useful with the DefaultAudioSink, but could be used in a
custom AudioSink when mixing audio from sources that have different sample
rates.

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=172434482
2017-10-17 18:24:53 +01:00
andrewlewis
e46a7600cf Document DefaultTimeBar attributes
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=172339124
2017-10-17 18:23:35 +01:00
andrewlewis
9356363117 Document load() exceptions
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=172329677
2017-10-17 18:22:14 +01:00
aquilescanta
d0758c9393 Fix typo
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=172328148
2017-10-17 18:20:49 +01:00
Oliver Woodman
51fd3365bb Remove spurious method 2017-10-17 17:57:27 +01:00
olly
e7d6f1a2ce Prevent unnecessary consecutive playlist loads
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=170078933
2017-10-17 17:32:12 +01:00
Oliver Woodman
d8ceef1038 Clean up HlsPlaylistTracker 2017-10-17 17:32:06 +01:00
yqritc
98f6e89efd remove space 2017-10-17 17:32:01 +01:00
yqritc
3b8fd4985c remove keep alive check for updating primary url to avoid redundant playlist loading 2017-10-17 17:31:55 +01:00
yqritc
758de818db fix primarySnapshotAccessAgeMs 2017-10-17 17:31:50 +01:00