Package com.google.android.exoplayer2.transformer

## Class DeviceMappedEncoderBitrateProvider

- java.lang.Object
- - com.google.android.exoplayer2.transformer.DeviceMappedEncoderBitrateProvider

- All Implemented Interfaces:
    `EncoderBitrateProvider`

      public class DeviceMappedEncoderBitrateProvider
      extends Object
      implements EncoderBitrateProvider

  Provides encoder bitrates that should target 0.95 SSIM or higher, accounting for device used.

- - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `DeviceMappedEncoderBitrateProvider()` |

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `int` | `getBitrate​(String encoderName, int width, int height, float frameRate)` | Returns a recommended bitrate that the encoder should target.

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

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

- - ### Constructor Detail

    - #### DeviceMappedEncoderBitrateProvider

          public DeviceMappedEncoderBitrateProvider()

  - ### Method Detail

    - #### getBitrate

          public int getBitrate​(String encoderName,
                                int width,
                                int height,
                                float frameRate)

      Description copied from interface: `EncoderBitrateProvider`
      Returns a recommended bitrate that the encoder should target.
      Specified by:
        `getBitrate` in interface `EncoderBitrateProvider`
      Parameters:
        `encoderName` - The name of the encoder, see `MediaCodecInfo.getName()`.
        `width` - The output width of the video after encoding.
        `height` - The output height of the video after encoding.
        `frameRate` - The expected output frame rate of the video after encoding.
      Returns:
        The bitrate the encoder should target.