Package com.castlabs.android.hybridads

# Class AdNativeAudioRenderer

java.lang.Object
com.google.android.exoplayer2.BaseRenderer
com.google.android.exoplayer2.audio.SimpleDecoderAudioRenderer
com.castlabs.android.hybridads.AdNativeAudioRenderer

All Implemented Interfaces:
  `com.google.android.exoplayer2.drm.DrmSession.EventListener`, `com.google.android.exoplayer2.PlayerMessage.Target`, `com.google.android.exoplayer2.Renderer`, `com.google.android.exoplayer2.RendererCapabilities`, `com.google.android.exoplayer2.util.MediaClock`

public class AdNativeAudioRenderer extends com.google.android.exoplayer2.audio.SimpleDecoderAudioRenderer

- ## Nested Class Summary

  ## Nested classes/interfaces inherited from class com.google.android.exoplayer2.BaseRenderer

  `com.google.android.exoplayer2.BaseRenderer.RendererStreamException`

  ## Nested classes/interfaces inherited from interface com.google.android.exoplayer2.Renderer

  `com.google.android.exoplayer2.Renderer.Listener, com.google.android.exoplayer2.Renderer.State`

  ## Nested classes/interfaces inherited from interface com.google.android.exoplayer2.RendererCapabilities

  `com.google.android.exoplayer2.RendererCapabilities.AdaptiveSupport, com.google.android.exoplayer2.RendererCapabilities.Capabilities, com.google.android.exoplayer2.RendererCapabilities.CodecImplementation, com.google.android.exoplayer2.RendererCapabilities.FormatSupport, com.google.android.exoplayer2.RendererCapabilities.Listener, com.google.android.exoplayer2.RendererCapabilities.TunnelingSupport`

- ## Field Summary

  ### Fields inherited from interface com.google.android.exoplayer2.Renderer

  `STATE_DISABLED, STATE_ENABLED, STATE_STARTED`

  ### Fields inherited from interface com.google.android.exoplayer2.RendererCapabilities

  `ADAPTIVE_NOT_SEAMLESS, ADAPTIVE_NOT_SUPPORTED, ADAPTIVE_SEAMLESS, ADAPTIVE_SUPPORT_MASK, CODEC_IMPLEMENTATION_HARDWARE, CODEC_IMPLEMENTATION_MASK, CODEC_IMPLEMENTATION_SOFTWARE, FORMAT_EXCEEDS_CAPABILITIES, FORMAT_HANDLED, FORMAT_SUPPORT_MASK, FORMAT_UNSUPPORTED_DRM, FORMAT_UNSUPPORTED_SUBTYPE, FORMAT_UNSUPPORTED_TYPE, TUNNELING_NOT_SUPPORTED, TUNNELING_SUPPORT_MASK, TUNNELING_SUPPORTED`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `AdNativeAudioRenderer(AdNativeDecoder decoder, com.castlabs.android.tunerhal.aidl.IPlayerService tunerhalPlayerService, boolean rendererUsesSharedMemory, int sharedMemorySizeInBytes, Handler eventHandler, PlayerConfig playerConfig, com.google.android.exoplayer2.audio.AudioRendererEventListener eventListener, int playerServiceInstance, long splicePts, long adDuration, HybridAdView hybridAdView)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `long`
  `getPositionUs()`
  `boolean`
  `isReady()`
  `void`
  `render(long positionUs, long elapsedRealtimeUs)`

  ### Methods inherited from class com.google.android.exoplayer2.audio.SimpleDecoderAudioRenderer

  `getMediaClock, getPlaybackParameters, handleMessage, isEnded, setPlaybackParameters, supportsFormat`

  ### Methods inherited from class com.google.android.exoplayer2.BaseRenderer

  `clearListener, disable, enable, getCapabilities, getReadingPositionUs, getState, getStream, getStreamOffsetUs, getTrackType, hasReadStreamToEnd, isCurrentStreamFinal, maybeThrowStreamError, onRenewed, release, replaceStream, reset, resetPosition, setCurrentStreamFinal, setIndex, setListener, setListener, setRenderingIntervalManager, start, stop, supportsMixedMimeTypeAdaptation`

  ### Methods inherited from class java.lang.Object

  `equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

  ### Methods inherited from interface com.google.android.exoplayer2.Renderer

  `setOperatingRate`

- ## Constructor Details

  - ### AdNativeAudioRenderer

    public AdNativeAudioRenderer(AdNativeDecoder decoder, com.castlabs.android.tunerhal.aidl.IPlayerService tunerhalPlayerService, boolean rendererUsesSharedMemory, int sharedMemorySizeInBytes, @Nullable Handler eventHandler, PlayerConfig playerConfig, @Nullable com.google.android.exoplayer2.audio.AudioRendererEventListener eventListener, int playerServiceInstance, long splicePts, long adDuration, HybridAdView hybridAdView) throws CastlabsPlayerException
    Throws:
      `CastlabsPlayerException`

- ## Method Details

  - ### isReady

    public boolean isReady()
    Specified by:
      `isReady` in interface `com.google.android.exoplayer2.Renderer`
    Overrides:
      `isReady` in class `com.google.android.exoplayer2.audio.SimpleDecoderAudioRenderer`

  - ### render

    public void render(long positionUs, long elapsedRealtimeUs) throws com.google.android.exoplayer2.ExoPlaybackException
    Specified by:
      `render` in interface `com.google.android.exoplayer2.Renderer`
    Overrides:
      `render` in class `com.google.android.exoplayer2.audio.SimpleDecoderAudioRenderer`
    Throws:
      `com.google.android.exoplayer2.ExoPlaybackException`

  - ### getPositionUs

    public long getPositionUs()
    Specified by:
      `getPositionUs` in interface `com.google.android.exoplayer2.util.MediaClock`
    Overrides:
      `getPositionUs` in class `com.google.android.exoplayer2.audio.SimpleDecoderAudioRenderer`