Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4b09c6bc authored by Eric Laurent's avatar Eric Laurent Committed by android-build-merger
Browse files

Merge \"Add Dolby TrueHD audio format\" into nyc-mr1-dev

am: b2fe8040

Change-Id: I2eba2e118c6ce34299ffe894d2c6e6ef9140fa24
parents 04831844 b2fe8040
Loading
Loading
Loading
Loading
+18 −12
Original line number Original line Diff line number Diff line
@@ -32,6 +32,8 @@
#define ENCODING_AAC_HE_V1      11
#define ENCODING_AAC_HE_V1      11
#define ENCODING_AAC_HE_V2      12
#define ENCODING_AAC_HE_V2      12
#define ENCODING_IEC61937       13
#define ENCODING_IEC61937       13
#define ENCODING_DOLBY_TRUEHD   14

#define ENCODING_INVALID    0
#define ENCODING_INVALID    0
#define ENCODING_DEFAULT    1
#define ENCODING_DEFAULT    1


@@ -65,6 +67,8 @@ static inline audio_format_t audioFormatToNative(int audioFormat)
        return AUDIO_FORMAT_AAC_HE_V1;
        return AUDIO_FORMAT_AAC_HE_V1;
    case ENCODING_AAC_HE_V2:
    case ENCODING_AAC_HE_V2:
        return AUDIO_FORMAT_AAC_HE_V2;
        return AUDIO_FORMAT_AAC_HE_V2;
    case ENCODING_DOLBY_TRUEHD:
        return AUDIO_FORMAT_DOLBY_TRUEHD;
    case ENCODING_IEC61937:
    case ENCODING_IEC61937:
        return AUDIO_FORMAT_IEC61937;
        return AUDIO_FORMAT_IEC61937;
    case ENCODING_DEFAULT:
    case ENCODING_DEFAULT:
@@ -108,6 +112,8 @@ static inline int audioFormatFromNative(audio_format_t nativeFormat)
        return ENCODING_AAC_HE_V2;
        return ENCODING_AAC_HE_V2;
    case AUDIO_FORMAT_IEC61937:
    case AUDIO_FORMAT_IEC61937:
        return ENCODING_IEC61937;
        return ENCODING_IEC61937;
    case AUDIO_FORMAT_DOLBY_TRUEHD:
        return ENCODING_DOLBY_TRUEHD;
    case AUDIO_FORMAT_DEFAULT:
    case AUDIO_FORMAT_DEFAULT:
        return ENCODING_DEFAULT;
        return ENCODING_DEFAULT;
    default:
    default:
+4 −0
Original line number Original line Diff line number Diff line
@@ -263,6 +263,10 @@ public final class AudioFormat implements Parcelable {
     * on some platforms when converting to short internally.
     * on some platforms when converting to short internally.
     */
     */
    public static final int ENCODING_IEC61937 = 13;
    public static final int ENCODING_IEC61937 = 13;
    /** Audio data format: DOLBY TRUEHD compressed
     * @hide
     **/
    public static final int ENCODING_DOLBY_TRUEHD = 14;


    /** Invalid audio channel configuration */
    /** Invalid audio channel configuration */
    /** @deprecated Use {@link #CHANNEL_INVALID} instead.  */
    /** @deprecated Use {@link #CHANNEL_INVALID} instead.  */