- Use ConstantBitrateSeeker to implement seeking for ADTS format. Since most
ADTS streams are VBR, we use the average bitrate of the first 1000 frames as
the average bit rate.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=207509651
This is needed for implementing (optional) support for audio focus handling in a
later change.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=206899837
All known instances use DataSource as generic type and thus code can be simplified
by removing the generic type altogether.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=205798542
This removes the need to populate the entire period for the common usage of
getting the uid from the period.
Also add default implementation to get period by uid.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=205638265
This bandwidth meter is then forwarded to the track selection and as a transfer
listener to media and data sources.
When no bandwidth meter is specified in the ExoPlayerFactory methods, a static
singleton instance will be used.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=204881497
There are only two types at the moment and we can therefore use a boolean.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=203937357
This wires up recent changes of passing a transfer listener to the MediaSource and
allowing DataSources to accept new listeners.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=203280818
This allows implementations to notify when the transfer is about to be started.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=203102117
This allows all leaf data sources (i.e. ones which do not forward the requests
to other data sources) to accept multiple listeners.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=203097587
This allows to use this queue in the track selection in the future.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=202954871
In the future, this allows to register the BandwidthMeter (managed by the player)
as a listener to all media transfers related to this media source.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=202643946
- Make it looks more natural to have MetadataRetrieverTestRunner in the same
package as ExoPlayerTestRunner.
- Change moe_config script to remove the file MetadataRetrieverTestRunner,
instead of the folder.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=202626238
This url is readily available when creating media source events (from the
data source) but so far not published to external listeners. This change
adds a new field to LoadEventInfo which corresponds to DataSource.getUri().
Issue:#2054
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=202459049
When getMedatadata from an ExtractorMediaPeriod, due to the MediaPeriod refreshing its Timeline twice, the MetadataRetriever may wrongly reset periodIndex of the current trackGroup to C.TIME_UNSET, which makes it unable to handle subsequent metadata queries.
This CL changes the MetadataRetriever to keep track of periodUid of the current trackGroup instead of period index. PeriodUid is not changed on timeline refreshing, so is not prone the existing problem.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=201969350
The DefaultEventListener was added for selective overrides. Now that Java 8
support is enabled, these selective listener overrides can be implemented
more easily and more flexible using default methods.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=201695490
Replace assertThat(a >= b).isTrue() with assertThat(a).isAtLeast(b) because it
reads more natural, and in case the assertion fails, it will print out the
actual values to help debugging.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=201371993
Currently, the looper of the thread the player is created on is used (or the
main looper if this thread doesn't have a looper). To allow more control over
the threading, this change lets users specificy the looper which must be used
to call player methods and which is used for event callbacks.
Issue:#4278
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=201331564
Added a capturer that can capture output from video renderer into bitmaps. This
class uses SurfaceCapturer to setup a surface, then configures this surface as the
output for a video renderer. Once the output is set, it will capture the
output frames from the video renderer and return them as bitmaps.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=201148184
Currently, we are using 2 copy steps for PixelCopySurfaceCapturerV24:
- Copy from the source surface to a similarly sized bitmap (using PixelCopy API).
- Copy from the bitmap to a scaled bitmap, based on the given output size, using scaledBitmap API.
This CL merges the 2 steps and uses PixelCopy API to perform copy directly from
the source surface to the bitmap of the given output size.
However, since our test uses scaledBitmap API to create reference bitmap from original image, due to various Bitmap copy optimizations (filtering, antialiasing etc...) that are different between PixelCopy API and scaledBitmap API implementations, the result images cannot be the same. We can perform the our tests by asserting that their PSNR value is very high, which means they are very similar.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=199472005
This adds an optional parameter to ConcatenatingMediaSource to prepare
child sources only lazily when are needed. This is helpful for long playlists
of media sources with manifests to prevent a lot of simultaneous manifest
loads.
Issue:#3972
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=198855676
Use PixelCopy API for the first SurfaceCapturer implementation. This supports
devices from API 24+.
Github: #3609.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=197732711
A new playback nonce is created for each playback of the same item. Thus we
need to inject the nonce dynamically into the data source factory.
This CL adds the DataSource which does the actual insertion into the request
URLs and a MediaSource which listens to new media periods, to request the
nonce and to configure the data source factory for this media period to use
this nonce.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=197134217
Currently, ExoPlayer only supports seeking for FLAC files with a SEEKTABLE.
This CL adds support seeking for cases when the FLAC files do not have a
SEEKTABLE by searching for individual frames within the file using binary
search.
Github: #1088.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=196816398
- This is needed to make DefaultTrackSelector properly thread
safe, and enable atomic changes to the selector that, for
example, disable a renderer and enable another one at the same
time.
- This change also saves/restores parameters and the start
position in PlayerActivity, resolving the ref'd issue.
Issue: #3915
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=193913350
*** Reason for rollback ***
Added the missing initialization to Timeline.EMPTY.
*** Original change description ***
Automated g4 rollback of changelist 192742299.
*** Reason for rollback ***
Culprit for b/78018932.
*** Original change description ***
Auto-register analytics collector in SimpleExoPlayer.
This automatically registers and deregisters an analytics collector in
SimpleExoPlayer. Doing this also allows to write integration tests checking
whether the reported window indices and media period ids are correct.
***
***
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=193006701
*** Reason for rollback ***
Culprit for b/78018932.
*** Original change description ***
Auto-register analytics collector in SimpleExoPlayer.
This automatically registers and deregisters an analytics collector in
SimpleExoPlayer. Doing this also allows to write integration tests checking
whether the reported window indices and media period ids are correct.
***
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=192816182
This automatically registers and deregisters an analytics collector in
SimpleExoPlayer. Doing this also allows to write integration tests checking
whether the reported window indices and media period ids are correct.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=192742299
These don't seem to be needed anymore. All tests run without them in gradle
and Blaze.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=191867518
This field (formerly "id") is almost impossible to use so far. Having setters
in the factories allows to specify custom tags for all media sources.
Also added a ExoPlayer.getCurrentTag() method to retrieve the tag of the
currently playing media source in a convenient way.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=191738754
In some situations, the timeline can't be specified because it is created
internally by the media source under test. If the test still needs to wait for
a timeline update, this change allows to do that by specifying an expected
timeline of null.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=190768386
Currently, MediaPeriod states that continueLoading may be called
during preparation. Some implementations would throw an error if
this happened.
Also make MediaPeriod documentation clearer.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=190596870
This will allow SimpleExoPlayer to auto-register its own listener before the
drm session manager is used to set-up the renderers.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=190478174
This adds callbacks for creating, releasing, and starting to read from media
periods.
Such events allow listeners to keep a list of active media periods. This is
useful to determine when no further events for a certain media period are
expected. It also allows listeners to associate renderer events unambigiously
with a reading media period.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=190462717
This gives the MediaSourceEventListener API a consistent look when new methods are
added which only have a window index and media period id.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=190450270
This allows to test sending events when using fake media sources.
The FakeMediaSource now simulates a manifest load when being prepared.
And the FakeMediaPeriod simulates a media load when being prepared.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=189205285
This allows to distinguish between media source events of multi-window and
multi-period media sources. In this change, only media sources currently reporting
events are changed. Proper support in composite sources will be added in a later
change.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=188847366
This is achieved by moving the listener registration and the creation of the
event dispatcher into BaseMediaSource.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=188461932
The start position was set to the old start position instead of the current
playback position. We need to set the start position to the current playback
position to ensure a repreperation with the same media starts from the last
playback position.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=188025439
- Change 'compile' configuration (deprecared) to using 'implementation'
and 'api' configurations instead.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=187311778
This is achieved by adding a BaseMediaSource which keeps a reference count of the
number of times the source has been prepared and forwards to the actual implementations
only once, such that only minimal changes are needed for each media source.
Issue:#3498
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=187186691