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

Commit f24dd061 authored by Amy Zhang's avatar Amy Zhang
Browse files

Use char instead of int in Tuner AIDL interface for all the 16-bit data defined in TunerHAL

char is char16_t in cpp backend when defined in AIDL interface.
See: https://source.android.com/devices/architecture/aidl/aidl-backends#types

Test: make
Bug: 185627837
Change-Id: Iecb6ae293e0ad46e80b29c558816705be1577d3f
parent ce82d784
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -685,7 +685,7 @@ void TunerFilter::FilterCallback::getMediaEvent(
        DemuxFilterMediaEvent mediaEvent = e.media();
        TunerFilterMediaEvent tunerMedia;

        tunerMedia.streamId = static_cast<int>(mediaEvent.streamId);
        tunerMedia.streamId = static_cast<char16_t>(mediaEvent.streamId);
        tunerMedia.isPtsPresent = mediaEvent.isPtsPresent;
        tunerMedia.pts = static_cast<long>(mediaEvent.pts);
        tunerMedia.dataLength = static_cast<int>(mediaEvent.dataLength);
@@ -750,7 +750,7 @@ void TunerFilter::FilterCallback::getPesEvent(
        TunerFilterPesEvent tunerPes;

        tunerPes.streamId = static_cast<char16_t>(pesEvent.streamId);
        tunerPes.dataLength = static_cast<int>(pesEvent.dataLength);
        tunerPes.dataLength = static_cast<char16_t>(pesEvent.dataLength);
        tunerPes.mpuSequenceNumber = static_cast<int>(pesEvent.mpuSequenceNumber);

        TunerFilterEvent tunerEvent;
+2 −2
Original line number Diff line number Diff line
@@ -22,7 +22,7 @@ package android.media.tv.tuner;
 * {@hide}
 */
union TunerDemuxPid {
    int tPid;
    char tPid;

    int mmtpPid;
    char mmtpPid;
}
+1 −1
Original line number Diff line number Diff line
@@ -25,7 +25,7 @@ import android.media.tv.tuner.TunerAudioExtraMetaData;
 * {@hide}
 */
parcelable TunerFilterMediaEvent {
    int streamId;
    char streamId;

    /**
     * true if PTS is present in PES header.
+1 −1
Original line number Diff line number Diff line
@@ -27,7 +27,7 @@ parcelable TunerFilterPesEvent {
    /**
     * Data size in bytes of PES data
     */
    int dataLength;
    char dataLength;

    /**
     * MPU sequence number of filtered data
+1 −1
Original line number Diff line number Diff line
@@ -27,7 +27,7 @@ parcelable TunerFrontendIsdbs3Settings {
     */
    int frequency;

    int streamId;
    char streamId;

    int streamIdType;

Loading