Class EventLogger
- java.lang.Object
-
- com.google.android.exoplayer2.util.EventLogger
-
- All Implemented Interfaces:
AnalyticsListener
@Deprecated public class EventLogger extends Object implements AnalyticsListener
Deprecated.com.google.android.exoplayer2 is deprecated. Please migrate to androidx.media3 (which contains the same ExoPlayer code). See the migration guide for more details, including a script to help with the migration.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface com.google.android.exoplayer2.analytics.AnalyticsListener
AnalyticsListener.EventFlags, AnalyticsListener.Events, AnalyticsListener.EventTime
-
-
Field Summary
-
Fields inherited from interface com.google.android.exoplayer2.analytics.AnalyticsListener
EVENT_AUDIO_ATTRIBUTES_CHANGED, EVENT_AUDIO_CODEC_ERROR, EVENT_AUDIO_DECODER_INITIALIZED, EVENT_AUDIO_DECODER_RELEASED, EVENT_AUDIO_DISABLED, EVENT_AUDIO_ENABLED, EVENT_AUDIO_INPUT_FORMAT_CHANGED, EVENT_AUDIO_POSITION_ADVANCING, EVENT_AUDIO_SESSION_ID, EVENT_AUDIO_SINK_ERROR, EVENT_AUDIO_UNDERRUN, EVENT_AVAILABLE_COMMANDS_CHANGED, EVENT_BANDWIDTH_ESTIMATE, EVENT_CUES, EVENT_DEVICE_INFO_CHANGED, EVENT_DEVICE_VOLUME_CHANGED, EVENT_DOWNSTREAM_FORMAT_CHANGED, EVENT_DRM_KEYS_LOADED, EVENT_DRM_KEYS_REMOVED, EVENT_DRM_KEYS_RESTORED, EVENT_DRM_SESSION_ACQUIRED, EVENT_DRM_SESSION_MANAGER_ERROR, EVENT_DRM_SESSION_RELEASED, EVENT_DROPPED_VIDEO_FRAMES, EVENT_IS_LOADING_CHANGED, EVENT_IS_PLAYING_CHANGED, EVENT_LOAD_CANCELED, EVENT_LOAD_COMPLETED, EVENT_LOAD_ERROR, EVENT_LOAD_STARTED, EVENT_MAX_SEEK_TO_PREVIOUS_POSITION_CHANGED, EVENT_MEDIA_ITEM_TRANSITION, EVENT_MEDIA_METADATA_CHANGED, EVENT_METADATA, EVENT_PLAY_WHEN_READY_CHANGED, EVENT_PLAYBACK_PARAMETERS_CHANGED, EVENT_PLAYBACK_STATE_CHANGED, EVENT_PLAYBACK_SUPPRESSION_REASON_CHANGED, EVENT_PLAYER_ERROR, EVENT_PLAYER_RELEASED, EVENT_PLAYLIST_METADATA_CHANGED, EVENT_POSITION_DISCONTINUITY, EVENT_RENDERED_FIRST_FRAME, EVENT_REPEAT_MODE_CHANGED, EVENT_SEEK_BACK_INCREMENT_CHANGED, EVENT_SEEK_FORWARD_INCREMENT_CHANGED, EVENT_SHUFFLE_MODE_ENABLED_CHANGED, EVENT_SKIP_SILENCE_ENABLED_CHANGED, EVENT_SURFACE_SIZE_CHANGED, EVENT_TIMELINE_CHANGED, EVENT_TRACK_SELECTION_PARAMETERS_CHANGED, EVENT_TRACKS_CHANGED, EVENT_UPSTREAM_DISCARDED, EVENT_VIDEO_CODEC_ERROR, EVENT_VIDEO_DECODER_INITIALIZED, EVENT_VIDEO_DECODER_RELEASED, EVENT_VIDEO_DISABLED, EVENT_VIDEO_ENABLED, EVENT_VIDEO_FRAME_PROCESSING_OFFSET, EVENT_VIDEO_INPUT_FORMAT_CHANGED, EVENT_VIDEO_SIZE_CHANGED, EVENT_VOLUME_CHANGED
-
-
Constructor Summary
Constructors Constructor Description EventLogger()Deprecated.Creates an instance.EventLogger(MappingTrackSelector trackSelector)Deprecated.UseEventLogger()EventLogger(MappingTrackSelector trackSelector, String tag)Deprecated.EventLogger(String tag)Deprecated.Creates an instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description protected voidlogd(String msg)Deprecated.Logs a debug message.protected voidloge(String msg)Deprecated.Logs an error message.voidonAudioAttributesChanged(AnalyticsListener.EventTime eventTime, AudioAttributes audioAttributes)Deprecated.Called when the audio attributes change.voidonAudioDecoderInitialized(AnalyticsListener.EventTime eventTime, String decoderName, long initializationDurationMs)Deprecated.voidonAudioDecoderReleased(AnalyticsListener.EventTime eventTime, String decoderName)Deprecated.Called when an audio renderer releases a decoder.voidonAudioDisabled(AnalyticsListener.EventTime eventTime, DecoderCounters decoderCounters)Deprecated.Called when an audio renderer is disabled.voidonAudioEnabled(AnalyticsListener.EventTime eventTime, DecoderCounters decoderCounters)Deprecated.Called when an audio renderer is enabled.voidonAudioInputFormatChanged(AnalyticsListener.EventTime eventTime, Format format, DecoderReuseEvaluation decoderReuseEvaluation)Deprecated.Called when the format of the media being consumed by an audio renderer changes.voidonAudioSessionIdChanged(AnalyticsListener.EventTime eventTime, int audioSessionId)Deprecated.Called when the audio session ID changes.voidonAudioUnderrun(AnalyticsListener.EventTime eventTime, int bufferSize, long bufferSizeMs, long elapsedSinceLastFeedMs)Deprecated.Called when an audio underrun occurs.voidonBandwidthEstimate(AnalyticsListener.EventTime eventTime, int totalLoadTimeMs, long totalBytesLoaded, long bitrateEstimate)Deprecated.Called when the bandwidth estimate for the current data source has been updated.voidonDownstreamFormatChanged(AnalyticsListener.EventTime eventTime, MediaLoadData mediaLoadData)Deprecated.Called when the downstream format sent to the renderers changed.voidonDrmKeysLoaded(AnalyticsListener.EventTime eventTime)Deprecated.Called each time drm keys are loaded.voidonDrmKeysRemoved(AnalyticsListener.EventTime eventTime)Deprecated.Called each time offline drm keys are removed.voidonDrmKeysRestored(AnalyticsListener.EventTime eventTime)Deprecated.Called each time offline drm keys are restored.voidonDrmSessionAcquired(AnalyticsListener.EventTime eventTime, @com.google.android.exoplayer2.drm.DrmSession.State int state)Deprecated.Called each time a drm session is acquired.voidonDrmSessionManagerError(AnalyticsListener.EventTime eventTime, Exception error)Deprecated.Called when a drm error occurs.voidonDrmSessionReleased(AnalyticsListener.EventTime eventTime)Deprecated.Called each time a drm session is released.voidonDroppedVideoFrames(AnalyticsListener.EventTime eventTime, int droppedFrames, long elapsedMs)Deprecated.Called after video frames have been dropped.voidonIsLoadingChanged(AnalyticsListener.EventTime eventTime, boolean isLoading)Deprecated.Called when the player starts or stops loading data from a source.voidonIsPlayingChanged(AnalyticsListener.EventTime eventTime, boolean isPlaying)Deprecated.Called when the player starts or stops playing.voidonLoadCanceled(AnalyticsListener.EventTime eventTime, LoadEventInfo loadEventInfo, MediaLoadData mediaLoadData)Deprecated.Called when a media source canceled loading data.voidonLoadCompleted(AnalyticsListener.EventTime eventTime, LoadEventInfo loadEventInfo, MediaLoadData mediaLoadData)Deprecated.Called when a media source completed loading data.voidonLoadError(AnalyticsListener.EventTime eventTime, LoadEventInfo loadEventInfo, MediaLoadData mediaLoadData, IOException error, boolean wasCanceled)Deprecated.Called when a media source loading error occurred.voidonLoadStarted(AnalyticsListener.EventTime eventTime, LoadEventInfo loadEventInfo, MediaLoadData mediaLoadData)Deprecated.Called when a media source started loading data.voidonMediaItemTransition(AnalyticsListener.EventTime eventTime, MediaItem mediaItem, int reason)Deprecated.Called when playback transitions to a different media item.voidonMetadata(AnalyticsListener.EventTime eventTime, Metadata metadata)Deprecated.Called when there isMetadataassociated with the current playback time.voidonPlaybackParametersChanged(AnalyticsListener.EventTime eventTime, PlaybackParameters playbackParameters)Deprecated.Called when the playback parameters changed.voidonPlaybackStateChanged(AnalyticsListener.EventTime eventTime, @com.google.android.exoplayer2.Player.State int state)Deprecated.Called when the playback state changed.voidonPlaybackSuppressionReasonChanged(AnalyticsListener.EventTime eventTime, @com.google.android.exoplayer2.Player.PlaybackSuppressionReason int playbackSuppressionReason)Deprecated.Called when playback suppression reason changed.voidonPlayerError(AnalyticsListener.EventTime eventTime, PlaybackException error)Deprecated.Called when a fatal player error occurred.voidonPlayWhenReadyChanged(AnalyticsListener.EventTime eventTime, boolean playWhenReady, @com.google.android.exoplayer2.Player.PlayWhenReadyChangeReason int reason)Deprecated.Called when the value changed that indicates whether playback will proceed when ready.voidonPositionDiscontinuity(AnalyticsListener.EventTime eventTime, Player.PositionInfo oldPosition, Player.PositionInfo newPosition, @com.google.android.exoplayer2.Player.DiscontinuityReason int reason)Deprecated.Called when a position discontinuity occurred.voidonRenderedFirstFrame(AnalyticsListener.EventTime eventTime, Object output, long renderTimeMs)Deprecated.Called when a frame is rendered for the first time since setting the surface, or since the renderer was reset, or since the stream being rendered was changed.voidonRepeatModeChanged(AnalyticsListener.EventTime eventTime, @com.google.android.exoplayer2.Player.RepeatMode int repeatMode)Deprecated.Called when the repeat mode changed.voidonShuffleModeChanged(AnalyticsListener.EventTime eventTime, boolean shuffleModeEnabled)Deprecated.Called when the shuffle mode changed.voidonSkipSilenceEnabledChanged(AnalyticsListener.EventTime eventTime, boolean skipSilenceEnabled)Deprecated.Called when skipping silences is enabled or disabled in the audio stream.voidonSurfaceSizeChanged(AnalyticsListener.EventTime eventTime, int width, int height)Deprecated.Called when the output surface size changed.voidonTimelineChanged(AnalyticsListener.EventTime eventTime, @com.google.android.exoplayer2.Player.TimelineChangeReason int reason)Deprecated.Called when the timeline changed.voidonTracksChanged(AnalyticsListener.EventTime eventTime, Tracks tracks)Deprecated.Called when the tracks change.voidonUpstreamDiscarded(AnalyticsListener.EventTime eventTime, MediaLoadData mediaLoadData)Deprecated.Called when data is removed from the back of a media buffer, typically so that it can be re-buffered in a different format.voidonVideoDecoderInitialized(AnalyticsListener.EventTime eventTime, String decoderName, long initializationDurationMs)Deprecated.voidonVideoDecoderReleased(AnalyticsListener.EventTime eventTime, String decoderName)Deprecated.Called when a video renderer releases a decoder.voidonVideoDisabled(AnalyticsListener.EventTime eventTime, DecoderCounters decoderCounters)Deprecated.Called when a video renderer is disabled.voidonVideoEnabled(AnalyticsListener.EventTime eventTime, DecoderCounters decoderCounters)Deprecated.Called when a video renderer is enabled.voidonVideoInputFormatChanged(AnalyticsListener.EventTime eventTime, Format format, DecoderReuseEvaluation decoderReuseEvaluation)Deprecated.Called when the format of the media being consumed by a video renderer changes.voidonVideoSizeChanged(AnalyticsListener.EventTime eventTime, VideoSize videoSize)Deprecated.Called before a frame is rendered for the first time since setting the surface, and each time there's a change in the size or pixel aspect ratio of the video being rendered.voidonVolumeChanged(AnalyticsListener.EventTime eventTime, float volume)Deprecated.Called when the volume changes.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.google.android.exoplayer2.analytics.AnalyticsListener
onAudioCodecError, onAudioDecoderInitialized, onAudioInputFormatChanged, onAudioPositionAdvancing, onAudioSinkError, onAvailableCommandsChanged, onCues, onCues, onDeviceInfoChanged, onDeviceVolumeChanged, onDrmSessionAcquired, onEvents, onLoadingChanged, onMaxSeekToPreviousPositionChanged, onMediaMetadataChanged, onPlayerErrorChanged, onPlayerReleased, onPlayerStateChanged, onPlaylistMetadataChanged, onPositionDiscontinuity, onSeekBackIncrementChanged, onSeekForwardIncrementChanged, onSeekStarted, onTrackSelectionParametersChanged, onVideoCodecError, onVideoDecoderInitialized, onVideoFrameProcessingOffset, onVideoInputFormatChanged, onVideoSizeChanged
-
-
-
-
Constructor Detail
-
EventLogger
public EventLogger()
Deprecated.Creates an instance.
-
EventLogger
public EventLogger(String tag)
Deprecated.Creates an instance.- Parameters:
tag- The tag used for logging.
-
EventLogger
@Deprecated public EventLogger(@Nullable MappingTrackSelector trackSelector)
Deprecated.UseEventLogger()Creates an instance.- Parameters:
trackSelector- This parameter is ignored.
-
EventLogger
@Deprecated public EventLogger(@Nullable MappingTrackSelector trackSelector, String tag)
Deprecated.Creates an instance.- Parameters:
trackSelector- This parameter is ignored.tag- The tag used for logging.
-
-
Method Detail
-
onIsLoadingChanged
public void onIsLoadingChanged(AnalyticsListener.EventTime eventTime, boolean isLoading)
Deprecated.Description copied from interface:AnalyticsListenerCalled when the player starts or stops loading data from a source.- Specified by:
onIsLoadingChangedin interfaceAnalyticsListener- Parameters:
eventTime- The event time.isLoading- Whether the player is loading.
-
onPlaybackStateChanged
public void onPlaybackStateChanged(AnalyticsListener.EventTime eventTime, @State @com.google.android.exoplayer2.Player.State int state)
Deprecated.Description copied from interface:AnalyticsListenerCalled when the playback state changed.- Specified by:
onPlaybackStateChangedin interfaceAnalyticsListener- Parameters:
eventTime- The event time.state- The newplayback state.
-
onPlayWhenReadyChanged
public void onPlayWhenReadyChanged(AnalyticsListener.EventTime eventTime, boolean playWhenReady, @PlayWhenReadyChangeReason @com.google.android.exoplayer2.Player.PlayWhenReadyChangeReason int reason)
Deprecated.Description copied from interface:AnalyticsListenerCalled when the value changed that indicates whether playback will proceed when ready.- Specified by:
onPlayWhenReadyChangedin interfaceAnalyticsListener- Parameters:
eventTime- The event time.playWhenReady- Whether playback will proceed when ready.reason- Thereasonof the change.
-
onPlaybackSuppressionReasonChanged
public void onPlaybackSuppressionReasonChanged(AnalyticsListener.EventTime eventTime, @PlaybackSuppressionReason @com.google.android.exoplayer2.Player.PlaybackSuppressionReason int playbackSuppressionReason)
Deprecated.Description copied from interface:AnalyticsListenerCalled when playback suppression reason changed.- Specified by:
onPlaybackSuppressionReasonChangedin interfaceAnalyticsListener- Parameters:
eventTime- The event time.playbackSuppressionReason- The newPlayer.PlaybackSuppressionReason.
-
onIsPlayingChanged
public void onIsPlayingChanged(AnalyticsListener.EventTime eventTime, boolean isPlaying)
Deprecated.Description copied from interface:AnalyticsListenerCalled when the player starts or stops playing.- Specified by:
onIsPlayingChangedin interfaceAnalyticsListener- Parameters:
eventTime- The event time.isPlaying- Whether the player is playing.
-
onRepeatModeChanged
public void onRepeatModeChanged(AnalyticsListener.EventTime eventTime, @RepeatMode @com.google.android.exoplayer2.Player.RepeatMode int repeatMode)
Deprecated.Description copied from interface:AnalyticsListenerCalled when the repeat mode changed.- Specified by:
onRepeatModeChangedin interfaceAnalyticsListener- Parameters:
eventTime- The event time.repeatMode- The new repeat mode.
-
onShuffleModeChanged
public void onShuffleModeChanged(AnalyticsListener.EventTime eventTime, boolean shuffleModeEnabled)
Deprecated.Description copied from interface:AnalyticsListenerCalled when the shuffle mode changed.- Specified by:
onShuffleModeChangedin interfaceAnalyticsListener- Parameters:
eventTime- The event time.shuffleModeEnabled- Whether the shuffle mode is enabled.
-
onPositionDiscontinuity
public void onPositionDiscontinuity(AnalyticsListener.EventTime eventTime, Player.PositionInfo oldPosition, Player.PositionInfo newPosition, @DiscontinuityReason @com.google.android.exoplayer2.Player.DiscontinuityReason int reason)
Deprecated.Description copied from interface:AnalyticsListenerCalled when a position discontinuity occurred.- Specified by:
onPositionDiscontinuityin interfaceAnalyticsListener- Parameters:
eventTime- The event time.oldPosition- The position before the discontinuity.newPosition- The position after the discontinuity.reason- The reason for the position discontinuity.
-
onPlaybackParametersChanged
public void onPlaybackParametersChanged(AnalyticsListener.EventTime eventTime, PlaybackParameters playbackParameters)
Deprecated.Description copied from interface:AnalyticsListenerCalled when the playback parameters changed.- Specified by:
onPlaybackParametersChangedin interfaceAnalyticsListener- Parameters:
eventTime- The event time.playbackParameters- The new playback parameters.
-
onTimelineChanged
public void onTimelineChanged(AnalyticsListener.EventTime eventTime, @TimelineChangeReason @com.google.android.exoplayer2.Player.TimelineChangeReason int reason)
Deprecated.Description copied from interface:AnalyticsListenerCalled when the timeline changed.- Specified by:
onTimelineChangedin interfaceAnalyticsListener- Parameters:
eventTime- The event time.reason- The reason for the timeline change.
-
onMediaItemTransition
public void onMediaItemTransition(AnalyticsListener.EventTime eventTime, @Nullable MediaItem mediaItem, int reason)
Deprecated.Description copied from interface:AnalyticsListenerCalled when playback transitions to a different media item.- Specified by:
onMediaItemTransitionin interfaceAnalyticsListener- Parameters:
eventTime- The event time.mediaItem- The media item.reason- The reason for the media item transition.
-
onPlayerError
public void onPlayerError(AnalyticsListener.EventTime eventTime, PlaybackException error)
Deprecated.Description copied from interface:AnalyticsListenerCalled when a fatal player error occurred.Implementations of
Playermay pass an instance of a subclass ofPlaybackExceptionto this method in order to include more information about the error.- Specified by:
onPlayerErrorin interfaceAnalyticsListener- Parameters:
eventTime- The event time.error- The error.
-
onTracksChanged
public void onTracksChanged(AnalyticsListener.EventTime eventTime, Tracks tracks)
Deprecated.Description copied from interface:AnalyticsListenerCalled when the tracks change.- Specified by:
onTracksChangedin interfaceAnalyticsListener- Parameters:
eventTime- The event time.tracks- The tracks. Never null, but may be of length zero.
-
onMetadata
public void onMetadata(AnalyticsListener.EventTime eventTime, Metadata metadata)
Deprecated.Description copied from interface:AnalyticsListenerCalled when there isMetadataassociated with the current playback time.- Specified by:
onMetadatain interfaceAnalyticsListener- Parameters:
eventTime- The event time.metadata- The metadata.
-
onAudioEnabled
public void onAudioEnabled(AnalyticsListener.EventTime eventTime, DecoderCounters decoderCounters)
Deprecated.Description copied from interface:AnalyticsListenerCalled when an audio renderer is enabled.- Specified by:
onAudioEnabledin interfaceAnalyticsListener- Parameters:
eventTime- The event time.decoderCounters-DecoderCountersthat will be updated by the renderer for as long as it remains enabled.
-
onAudioDecoderInitialized
public void onAudioDecoderInitialized(AnalyticsListener.EventTime eventTime, String decoderName, long initializationDurationMs)
Deprecated.- Specified by:
onAudioDecoderInitializedin interfaceAnalyticsListener
-
onAudioInputFormatChanged
public void onAudioInputFormatChanged(AnalyticsListener.EventTime eventTime, Format format, @Nullable DecoderReuseEvaluation decoderReuseEvaluation)
Deprecated.Description copied from interface:AnalyticsListenerCalled when the format of the media being consumed by an audio renderer changes.- Specified by:
onAudioInputFormatChangedin interfaceAnalyticsListener- Parameters:
eventTime- The event time.format- The new format.decoderReuseEvaluation- The result of the evaluation to determine whether an existing decoder instance can be reused for the new format, ornullif the renderer did not have a decoder.
-
onAudioUnderrun
public void onAudioUnderrun(AnalyticsListener.EventTime eventTime, int bufferSize, long bufferSizeMs, long elapsedSinceLastFeedMs)
Deprecated.Description copied from interface:AnalyticsListenerCalled when an audio underrun occurs.- Specified by:
onAudioUnderrunin interfaceAnalyticsListener- Parameters:
eventTime- The event time.bufferSize- The size of the audio output buffer, in bytes.bufferSizeMs- The size of the audio output buffer, in milliseconds, if it contains PCM encoded audio.C.TIME_UNSETif the output buffer contains non-PCM encoded audio.elapsedSinceLastFeedMs- The time since audio was last written to the output buffer.
-
onAudioDecoderReleased
public void onAudioDecoderReleased(AnalyticsListener.EventTime eventTime, String decoderName)
Deprecated.Description copied from interface:AnalyticsListenerCalled when an audio renderer releases a decoder.- Specified by:
onAudioDecoderReleasedin interfaceAnalyticsListener- Parameters:
eventTime- The event time.decoderName- The decoder that was released.
-
onAudioDisabled
public void onAudioDisabled(AnalyticsListener.EventTime eventTime, DecoderCounters decoderCounters)
Deprecated.Description copied from interface:AnalyticsListenerCalled when an audio renderer is disabled.- Specified by:
onAudioDisabledin interfaceAnalyticsListener- Parameters:
eventTime- The event time.decoderCounters-DecoderCountersthat were updated by the renderer.
-
onAudioSessionIdChanged
public void onAudioSessionIdChanged(AnalyticsListener.EventTime eventTime, int audioSessionId)
Deprecated.Description copied from interface:AnalyticsListenerCalled when the audio session ID changes.- Specified by:
onAudioSessionIdChangedin interfaceAnalyticsListener- Parameters:
eventTime- The event time.audioSessionId- The audio session ID.
-
onAudioAttributesChanged
public void onAudioAttributesChanged(AnalyticsListener.EventTime eventTime, AudioAttributes audioAttributes)
Deprecated.Description copied from interface:AnalyticsListenerCalled when the audio attributes change.- Specified by:
onAudioAttributesChangedin interfaceAnalyticsListener- Parameters:
eventTime- The event time.audioAttributes- The audio attributes.
-
onSkipSilenceEnabledChanged
public void onSkipSilenceEnabledChanged(AnalyticsListener.EventTime eventTime, boolean skipSilenceEnabled)
Deprecated.Description copied from interface:AnalyticsListenerCalled when skipping silences is enabled or disabled in the audio stream.- Specified by:
onSkipSilenceEnabledChangedin interfaceAnalyticsListener- Parameters:
eventTime- The event time.skipSilenceEnabled- Whether skipping silences in the audio stream is enabled.
-
onVolumeChanged
public void onVolumeChanged(AnalyticsListener.EventTime eventTime, float volume)
Deprecated.Description copied from interface:AnalyticsListenerCalled when the volume changes.- Specified by:
onVolumeChangedin interfaceAnalyticsListener- Parameters:
eventTime- The event time.volume- The new volume, with 0 being silence and 1 being unity gain.
-
onVideoEnabled
public void onVideoEnabled(AnalyticsListener.EventTime eventTime, DecoderCounters decoderCounters)
Deprecated.Description copied from interface:AnalyticsListenerCalled when a video renderer is enabled.- Specified by:
onVideoEnabledin interfaceAnalyticsListener- Parameters:
eventTime- The event time.decoderCounters-DecoderCountersthat will be updated by the renderer for as long as it remains enabled.
-
onVideoDecoderInitialized
public void onVideoDecoderInitialized(AnalyticsListener.EventTime eventTime, String decoderName, long initializationDurationMs)
Deprecated.- Specified by:
onVideoDecoderInitializedin interfaceAnalyticsListener
-
onVideoInputFormatChanged
public void onVideoInputFormatChanged(AnalyticsListener.EventTime eventTime, Format format, @Nullable DecoderReuseEvaluation decoderReuseEvaluation)
Deprecated.Description copied from interface:AnalyticsListenerCalled when the format of the media being consumed by a video renderer changes.- Specified by:
onVideoInputFormatChangedin interfaceAnalyticsListener- Parameters:
eventTime- The event time.format- The new format.decoderReuseEvaluation- The result of the evaluation to determine whether an existing decoder instance can be reused for the new format, ornullif the renderer did not have a decoder.
-
onDroppedVideoFrames
public void onDroppedVideoFrames(AnalyticsListener.EventTime eventTime, int droppedFrames, long elapsedMs)
Deprecated.Description copied from interface:AnalyticsListenerCalled after video frames have been dropped.- Specified by:
onDroppedVideoFramesin interfaceAnalyticsListener- Parameters:
eventTime- The event time.droppedFrames- The number of dropped frames since the last call to this method.elapsedMs- The duration in milliseconds over which the frames were dropped. This duration is timed from when the renderer was started or from when dropped frames were last reported (whichever was more recent), and not from when the first of the reported drops occurred.
-
onVideoDecoderReleased
public void onVideoDecoderReleased(AnalyticsListener.EventTime eventTime, String decoderName)
Deprecated.Description copied from interface:AnalyticsListenerCalled when a video renderer releases a decoder.- Specified by:
onVideoDecoderReleasedin interfaceAnalyticsListener- Parameters:
eventTime- The event time.decoderName- The decoder that was released.
-
onVideoDisabled
public void onVideoDisabled(AnalyticsListener.EventTime eventTime, DecoderCounters decoderCounters)
Deprecated.Description copied from interface:AnalyticsListenerCalled when a video renderer is disabled.- Specified by:
onVideoDisabledin interfaceAnalyticsListener- Parameters:
eventTime- The event time.decoderCounters-DecoderCountersthat were updated by the renderer.
-
onRenderedFirstFrame
public void onRenderedFirstFrame(AnalyticsListener.EventTime eventTime, Object output, long renderTimeMs)
Deprecated.Description copied from interface:AnalyticsListenerCalled when a frame is rendered for the first time since setting the surface, or since the renderer was reset, or since the stream being rendered was changed.- Specified by:
onRenderedFirstFramein interfaceAnalyticsListener- Parameters:
eventTime- The event time.output- The output to which a frame has been rendered. Normally aSurface, however may also be other output types (e.g., aVideoDecoderOutputBufferRenderer).renderTimeMs-SystemClock.elapsedRealtime()when the first frame was rendered.
-
onVideoSizeChanged
public void onVideoSizeChanged(AnalyticsListener.EventTime eventTime, VideoSize videoSize)
Deprecated.Description copied from interface:AnalyticsListenerCalled before a frame is rendered for the first time since setting the surface, and each time there's a change in the size or pixel aspect ratio of the video being rendered.- Specified by:
onVideoSizeChangedin interfaceAnalyticsListener- Parameters:
eventTime- The event time.videoSize- The new size of the video.
-
onLoadStarted
public void onLoadStarted(AnalyticsListener.EventTime eventTime, LoadEventInfo loadEventInfo, MediaLoadData mediaLoadData)
Deprecated.Description copied from interface:AnalyticsListenerCalled when a media source started loading data.- Specified by:
onLoadStartedin interfaceAnalyticsListener- Parameters:
eventTime- The event time.loadEventInfo- TheLoadEventInfodefining the load event.mediaLoadData- TheMediaLoadDatadefining the data being loaded.
-
onLoadError
public void onLoadError(AnalyticsListener.EventTime eventTime, LoadEventInfo loadEventInfo, MediaLoadData mediaLoadData, IOException error, boolean wasCanceled)
Deprecated.Description copied from interface:AnalyticsListenerCalled when a media source loading error occurred.This method being called does not indicate that playback has failed, or that it will fail. The player may be able to recover from the error. Hence applications should not implement this method to display a user visible error or initiate an application level retry.
Player.Listener.onPlayerError(com.google.android.exoplayer2.PlaybackException)is the appropriate place to implement such behavior. This method is called to provide the application with an opportunity to log the error if it wishes to do so.- Specified by:
onLoadErrorin interfaceAnalyticsListener- Parameters:
eventTime- The event time.loadEventInfo- TheLoadEventInfodefining the load event.mediaLoadData- TheMediaLoadDatadefining the data being loaded.error- The load error.wasCanceled- Whether the load was canceled as a result of the error.
-
onLoadCanceled
public void onLoadCanceled(AnalyticsListener.EventTime eventTime, LoadEventInfo loadEventInfo, MediaLoadData mediaLoadData)
Deprecated.Description copied from interface:AnalyticsListenerCalled when a media source canceled loading data.- Specified by:
onLoadCanceledin interfaceAnalyticsListener- Parameters:
eventTime- The event time.loadEventInfo- TheLoadEventInfodefining the load event.mediaLoadData- TheMediaLoadDatadefining the data being loaded.
-
onLoadCompleted
public void onLoadCompleted(AnalyticsListener.EventTime eventTime, LoadEventInfo loadEventInfo, MediaLoadData mediaLoadData)
Deprecated.Description copied from interface:AnalyticsListenerCalled when a media source completed loading data.- Specified by:
onLoadCompletedin interfaceAnalyticsListener- Parameters:
eventTime- The event time.loadEventInfo- TheLoadEventInfodefining the load event.mediaLoadData- TheMediaLoadDatadefining the data being loaded.
-
onBandwidthEstimate
public void onBandwidthEstimate(AnalyticsListener.EventTime eventTime, int totalLoadTimeMs, long totalBytesLoaded, long bitrateEstimate)
Deprecated.Description copied from interface:AnalyticsListenerCalled when the bandwidth estimate for the current data source has been updated.- Specified by:
onBandwidthEstimatein interfaceAnalyticsListener- Parameters:
eventTime- The event time.totalLoadTimeMs- The total time spend loading this update is based on, in milliseconds.totalBytesLoaded- The total bytes loaded this update is based on.bitrateEstimate- The bandwidth estimate, in bits per second.
-
onSurfaceSizeChanged
public void onSurfaceSizeChanged(AnalyticsListener.EventTime eventTime, int width, int height)
Deprecated.Description copied from interface:AnalyticsListenerCalled when the output surface size changed.- Specified by:
onSurfaceSizeChangedin interfaceAnalyticsListener- Parameters:
eventTime- The event time.width- The surface width in pixels. May beC.LENGTH_UNSETif unknown, or 0 if the video is not rendered onto a surface.height- The surface height in pixels. May beC.LENGTH_UNSETif unknown, or 0 if the video is not rendered onto a surface.
-
onUpstreamDiscarded
public void onUpstreamDiscarded(AnalyticsListener.EventTime eventTime, MediaLoadData mediaLoadData)
Deprecated.Description copied from interface:AnalyticsListenerCalled when data is removed from the back of a media buffer, typically so that it can be re-buffered in a different format.- Specified by:
onUpstreamDiscardedin interfaceAnalyticsListener- Parameters:
eventTime- The event time.mediaLoadData- TheMediaLoadDatadefining the media being discarded.
-
onDownstreamFormatChanged
public void onDownstreamFormatChanged(AnalyticsListener.EventTime eventTime, MediaLoadData mediaLoadData)
Deprecated.Description copied from interface:AnalyticsListenerCalled when the downstream format sent to the renderers changed.- Specified by:
onDownstreamFormatChangedin interfaceAnalyticsListener- Parameters:
eventTime- The event time.mediaLoadData- TheMediaLoadDatadefining the newly selected media data.
-
onDrmSessionAcquired
public void onDrmSessionAcquired(AnalyticsListener.EventTime eventTime, @State @com.google.android.exoplayer2.drm.DrmSession.State int state)
Deprecated.Description copied from interface:AnalyticsListenerCalled each time a drm session is acquired.- Specified by:
onDrmSessionAcquiredin interfaceAnalyticsListener- Parameters:
eventTime- The event time.state- TheDrmSession.Stateof the session when the acquisition completed.
-
onDrmSessionManagerError
public void onDrmSessionManagerError(AnalyticsListener.EventTime eventTime, Exception error)
Deprecated.Description copied from interface:AnalyticsListenerCalled when a drm error occurs.This method being called does not indicate that playback has failed, or that it will fail. The player may be able to recover from the error. Hence applications should not implement this method to display a user visible error or initiate an application level retry.
Player.Listener.onPlayerError(com.google.android.exoplayer2.PlaybackException)is the appropriate place to implement such behavior. This method is called to provide the application with an opportunity to log the error if it wishes to do so.- Specified by:
onDrmSessionManagerErrorin interfaceAnalyticsListener- Parameters:
eventTime- The event time.error- The error.
-
onDrmKeysRestored
public void onDrmKeysRestored(AnalyticsListener.EventTime eventTime)
Deprecated.Description copied from interface:AnalyticsListenerCalled each time offline drm keys are restored.- Specified by:
onDrmKeysRestoredin interfaceAnalyticsListener- Parameters:
eventTime- The event time.
-
onDrmKeysRemoved
public void onDrmKeysRemoved(AnalyticsListener.EventTime eventTime)
Deprecated.Description copied from interface:AnalyticsListenerCalled each time offline drm keys are removed.- Specified by:
onDrmKeysRemovedin interfaceAnalyticsListener- Parameters:
eventTime- The event time.
-
onDrmKeysLoaded
public void onDrmKeysLoaded(AnalyticsListener.EventTime eventTime)
Deprecated.Description copied from interface:AnalyticsListenerCalled each time drm keys are loaded.- Specified by:
onDrmKeysLoadedin interfaceAnalyticsListener- Parameters:
eventTime- The event time.
-
onDrmSessionReleased
public void onDrmSessionReleased(AnalyticsListener.EventTime eventTime)
Deprecated.Description copied from interface:AnalyticsListenerCalled each time a drm session is released.- Specified by:
onDrmSessionReleasedin interfaceAnalyticsListener- Parameters:
eventTime- The event time.
-
logd
protected void logd(String msg)
Deprecated.Logs a debug message.- Parameters:
msg- The message to log.
-
loge
protected void loge(String msg)
Deprecated.Logs an error message.- Parameters:
msg- The message to log.
-
-