1000 Commits

Author SHA1 Message Date
kimvde
a95c28a929 Implement binary search seeking for FLAC extractor
PiperOrigin-RevId: 284814594
2019-12-11 13:45:43 +00:00
ibaker
9ec524a7e2 Rollback of 355ed11a3c
*** Original commit ***

Suppress warnings emitted by Checker Framework version 2.11.1

More information:
https://docs.google.com/document/d/16tpK6aXqN68PvTyvt4siM-m7f0NXi_8xEeitLDzr8xY/edit?usp=sharing

Tested:
    TAP --sample ran all affected tests and none failed
    http://test/OCL:278915274:BASE:278884711:1573074344615:a6701677

***

PiperOrigin-RevId: 284741721
2019-12-10 12:37:42 +00:00
ibaker
4c4cabdfac (partial) Rollback of 880b879e8c
*** Original commit ***

Suppress warnings emitted by Checker Framework version 2.11.1

More information:
https://docs.google.com/document/d/16tpK6aXqN68PvTyvt4siM-m7f0NXi_8xEeitLDzr8xY/edit?usp=sharing

Tested:
    TAP train for global presubmit queue
    http://test/OCL:278152710:BASE:278144052:1572760370662:22459c12

***

PiperOrigin-RevId: 284738438
2019-12-10 12:37:26 +00:00
kimvde
d0508b2bde Make metadata field nullable in FlacStreamMetadata
This makes the format metadata null (instead of an empty Metadata
object) when it is not provided, and is therefore consistent with the
other extractors behavior.

PiperOrigin-RevId: 284171148
2019-12-06 19:21:16 +00:00
bachinger
f25bcedf72 Playlist API: submit ahead some files of the playlist API CL
PiperOrigin-RevId: 283988536
2019-12-06 19:20:13 +00:00
andrewlewis
cbdf45aa5f Verify metadata in extractor tests
PiperOrigin-RevId: 283960017
2019-12-06 19:19:50 +00:00
olly
cb873dd1ee Use play and pause convenience methods
PiperOrigin-RevId: 283949259
2019-12-06 19:19:18 +00:00
tonihei
72d5b425d3 Add IntDefs for renderer capabilities.
This simplifies documentation and adds compiler checks that the correct values
are used.

PiperOrigin-RevId: 283754163
2019-12-05 10:20:15 +00:00
bachinger
6c10c94f94 MediaSessionConnector: Support ACTION_SET_CAPTIONING_ENABLED
PiperOrigin-RevId: 283546707
2019-12-04 10:00:04 +00:00
kimvde
23b54a95d2 Allow no output frame holder BinarySearchSeeker
PiperOrigin-RevId: 283544187
2019-12-04 09:59:57 +00:00
tonihei
65c4a58825 Use Util method to create Handler instead of using deprecated method.
Calls to new Handler() without arguments are deprecated as of the latest Android
version. Replace them by a Util.createHandler call similar to the ones we
already have.

PiperOrigin-RevId: 283532891
2019-12-04 09:59:44 +00:00
andrewlewis
9b28e53238 Remove row VP9 multi-threading option
PiperOrigin-RevId: 283319944
2019-12-04 09:58:40 +00:00
olly
f14f0ce8ee Remove LibvpxVideoRenderer from nullness blacklist
PiperOrigin-RevId: 283310946
2019-12-04 09:58:33 +00:00
olly
3065d51310 Provide instructions for building extensions using Windows PowerShell
PiperOrigin-RevId: 283296427
2019-12-04 09:58:13 +00:00
andrewlewis
a0736cfbf5 Remove AdsManager listeners on release
Issue: #6687
PiperOrigin-RevId: 283023548
2019-12-04 09:58:07 +00:00
andrewlewis
a81149d962 Fix audio processor draining for reconfiguration
When transitioning to a new stream in a different format, the audio
processors are reconfigured. After this, they are drained and then
flushed so that they are ready to handle data in updated formats for the
new stream.

Before this change, some audio processors made the assumption that after
reconfiguration no more input would be queued in their old input format,
but this assumption is not correct: during draining more input may be
queued. Fix this behavior so that the new configuration is not referred
to while draining and only becomes active once flushed.

Issue: #6601
PiperOrigin-RevId: 282515359
2019-11-27 22:29:07 +00:00
andrewlewis
10f142b3ff Add AudioProcessor.AudioFormat
Issue: #6601
PiperOrigin-RevId: 282515179
2019-11-27 22:28:51 +00:00
andrewlewis
b7000e64e9 Always drain/flush AudioProcessors after configuration
This simplifies the contract of configure and is in preparation for
fixing a bug where more input can't be queued when draining audio
processors for a configuration change.

Issue: #6601
PiperOrigin-RevId: 282514367
2019-11-27 22:28:43 +00:00
andrewlewis
731b002e13 Add AV1 to supported formats
PiperOrigin-RevId: 281724630
2019-11-22 15:09:39 +00:00
kimvde
b18650fdcf Expose metadata in FLAC extractor
PiperOrigin-RevId: 281538423
2019-11-22 15:09:17 +00:00
aquilescanta
699dd3d27c Deprecate public renderer constructors that take a DrmSessionManager
PiperOrigin-RevId: 281086336
2019-11-18 17:55:43 +00:00
kimvde
9b2917a9ae Add Java FLAC extractor
Seeking, live streams support and exposure of vorbis and ID3 data
are not part of this commit.

Issue: #6406
PiperOrigin-RevId: 281083332
2019-11-18 17:55:28 +00:00
andrewlewis
3b26ecf6fe Remove option to disable loop filter for VP9
PiperOrigin-RevId: 281039634
2019-11-18 17:54:24 +00:00
bachinger
734b4ad9c8 document media button handling prior to API level 21
ISSUE: #6545
PiperOrigin-RevId: 281032120
2019-11-18 17:54:07 +00:00
olly
6df92fdd3f Update VP9 extension README to ref NDK r20
PiperOrigin-RevId: 279899984
2019-11-15 05:14:19 +00:00
aquilescanta
53283ecb52 Add CastPlayer tests for repeatMode masking
PiperOrigin-RevId: 279091742
2019-11-15 05:12:42 +00:00
kimvde
d1da3d925b Fix FLAC bit rate computation
PiperOrigin-RevId: 279088193
2019-11-15 05:12:34 +00:00
kimvde
a226bd0d69 Fix extractor sniffing in FLAC extension
Assuming that a flac stream starts with bytes
['f', 'L', 'a', 'C', 0, 0, 0, 0x22] is not always correct as it could
also start with ['f', 'L', 'a', 'C', 0x80, 0, 0, 0x22]
(see https://xiph.org/flac/format.html#metadata_block_streaminfo).

PiperOrigin-RevId: 279080562
2019-11-15 05:12:25 +00:00
olly
355ed11a3c Suppress warnings emitted by Checker Framework version 2.11.1
More information:
https://docs.google.com/document/d/16tpK6aXqN68PvTyvt4siM-m7f0NXi_8xEeitLDzr8xY/edit?usp=sharing

Tested:
    TAP --sample ran all affected tests and none failed
    http://test/OCL:278915274:BASE:278884711:1573074344615:a6701677
PiperOrigin-RevId: 279080514
2019-11-15 05:12:17 +00:00
kimvde
29d110b7eb Fix FLAC extension tests
- Add @Test annotations.
- Fix seeking to ignore potential placeholders
  (see https://xiph.org/flac/format.html#metadata_block_seektable).

PiperOrigin-RevId: 279074092
2019-11-15 05:12:09 +00:00
kimvde
c8170e18d0 Update AndroidX Test versions to latest
Split the version of the sublibraries because their latest version
number is different. See
https://developer.android.com/jetpack/androidx/releases/test#1.2.0.

PiperOrigin-RevId: 278585090
2019-11-05 16:18:38 +00:00
olly
46d58b5eda Add missing IntDef case in switch
PiperOrigin-RevId: 278332276
2019-11-05 16:17:54 +00:00
olly
880b879e8c Suppress warnings emitted by Checker Framework version 2.11.1
More information:
https://docs.google.com/document/d/16tpK6aXqN68PvTyvt4siM-m7f0NXi_8xEeitLDzr8xY/edit?usp=sharing

Tested:
    TAP train for global presubmit queue
    http://test/OCL:278152710:BASE:278144052:1572760370662:22459c12
PiperOrigin-RevId: 278241536
2019-11-05 16:17:39 +00:00
olly
c5c50078d7 Reset MediaSession shuffle/repeat modes if player is null
- This is for consistency with PlayerControlView.

- Also update PlayerNotificationManager notification if shuffle
  mode changes. This is for consistency with what happens when
  the repeat mode changes. By default the notification will be
  unchanged, but custom implementations can extend and then
  override createNotification, and given these modes change
  infrequently it feels like we can just do this. The alternative
  for achieving consistency would be to remove handling of repeat
  mode changes.

Issue: #6582
PiperOrigin-RevId: 277925094
2019-11-05 16:16:45 +00:00
andrewlewis
a4e7274cca Update audio extension build configurations
- Fix FLAC extension build (currently broken due to use of std::array,
  but fixed by migrating to NDK r20).
- Move opus and ffmpeg extensions to NDK r20. For ffmpeg, upgrade to
  release 4.2 which requires using libswresample and updates to the
  build script.

Issue: #6601
PiperOrigin-RevId: 277924119
2019-11-05 16:16:38 +00:00
andrewlewis
656556b828 Clean up naming for GLSurfaceViews
PiperOrigin-RevId: 277896757
2019-11-05 16:15:29 +00:00
olly
981008f76e Fix field-can-be-local warnings
PiperOrigin-RevId: 277732159
2019-11-05 16:15:06 +00:00
aquilescanta
0f312561e5 Add shuffle and repeat modes to media session playback state invalidation
Which ensures both get updated when the MediaSessionConnector player
changes.

Issue:#6582
PiperOrigin-RevId: 277254889
2019-10-30 08:51:35 +00:00
aquilescanta
bae2b1e4bc Add tests for playWhenReady masking
PiperOrigin-RevId: 277057328
2019-10-30 08:51:05 +00:00
olly
8ec6cf154c Fix incorrect anamorphic handling in Leanback extension
The leanback library doesn't know about non-square pixels. So if
we're playing content that uses non-square pixels, we need to adjust
the video dimensions that we provide to leanback such that it
renders the video with the correct aspect ratio.

PiperOrigin-RevId: 277042560
2019-10-30 08:50:49 +00:00
ibaker
7277df3547 Remove @NonNull where it's implied by @NonNullApi
Also remove it from all tests, these aren't covered by the null-checker

Covered by the following package-info.java files:
- j/c/g/a/exoplayer2/ext/mediasession/package-info.java
- j/c/g/a/exoplayer2/package-info.java
- j/c/g/a/exoplayer2/offline/package-info.java
- j/c/g/a/exoplayer2/video/package-info.java
- j/c/g/a/exoplayer2/ui/package-info.java

PiperOrigin-RevId: 277038916
2019-10-30 08:50:42 +00:00
aquilescanta
fc12457c7e Set internal state before setting up cast dependencies
Prevents access of fields before initialization. Also set
remoteMediaClient in the constructor by using setRemoteMediaClient
instead of assigning the field directly, which will (if possible)
pull the state of the receiver in the constructor.

PiperOrigin-RevId: 276660004
2019-10-30 08:49:40 +00:00
olly
47423b3100 Fix code triggering [-Werror, -Wreorder].
Otherwise, it will be a build error once we turn on the error.
Sponge: https://sponge.corp.google.com/target?id=8e88bd90-a716-40f7-9599-b70e9193b297&target=//third_party/java_src/android_libs/exoplayer/v2/extensions/flac/src/main:binary.
PiperOrigin-RevId: 276461029
2019-10-30 08:49:17 +00:00
aquilescanta
101746934f Guard repeatMode masking against regular status updates
PiperOrigin-RevId: 276035838
2019-10-30 08:48:07 +00:00
andrewlewis
51e4f7b260 Fix supplemental data handling with dropped frames
PiperOrigin-RevId: 276024935
2019-10-30 08:47:52 +00:00
aquilescanta
a0843d0e2f Guard playWhenReady masking against regular status updates
PiperOrigin-RevId: 275863101
2019-10-30 08:47:28 +00:00
olly
7ccbc4c436 Remove VR code
- Leaving GvrAudioProcessor for now.
- Removing GvrPlayerActivity because it was never released. Also removing
  related UI classes. These were released, but it's unlikely anyone would
  have been using them directly.

PiperOrigin-RevId: 275822516
2019-10-30 08:47:06 +00:00
bachinger
e6e2dcc58d Rollback of 36f8bd78f7
*** Original commit ***

Rollback of 4ad4e3e4fc

*** Original commit ***

Rollback of 3b22db33ba

*** Original commit ***

add top-level playlist API to ExoPlayer

Public design doc:
https://docs.google.com/document/d/11...

***

PiperOrigin-RevId: 275813737
2019-10-30 08:46:42 +00:00
olly
3150591b0a Minor CastPlayer Javadoc cleanup
PiperOrigin-RevId: 275439892
2019-10-18 17:42:58 +01:00
olly
64786c6ce4 Refactor GlViewGroup to ViewRenderer
GlViewGroup doesn't work properly as an actual ViewGroup. For example,
it doesn't support addition of child views after instantiation. This
change turns the class into a renderer, which is also more consistent
with other classes in the package.

PiperOrigin-RevId: 275322295
2019-10-18 17:42:19 +01:00