package com.mstar.android.tv;

import android.os.Handler;
import android.os.IBinder;
import android.os.Looper;
import android.os.Message;
import android.os.RemoteException;
import android.os.ServiceManager;
import android.util.Log;
import com.mstar.android.tv.IEventClient;
import com.mstar.android.tv.ITvService;
import com.mstar.android.tvapi.common.exception.TvCommonException;
import com.mstar.android.tvapi.common.vo.ColorTemperatureExData;
import com.mstar.android.tvapi.common.vo.EnumColorTemperature;
import com.mstar.android.tvapi.common.vo.EnumPictureMode;
import com.mstar.android.tvapi.common.vo.EnumVideoArcType;
import com.mstar.android.tvapi.common.vo.EnumVideoItem;
import com.mstar.android.tvapi.common.vo.Film;
import com.mstar.android.tvapi.common.vo.HdrAttribute;
import com.mstar.android.tvapi.common.vo.MpegNoiseReduction;
import com.mstar.android.tvapi.common.vo.MweType;
import com.mstar.android.tvapi.common.vo.NoiseReduction;
import com.mstar.android.tvapi.common.vo.PanelProperty;
import com.mstar.android.tvapi.common.vo.PglValue;
import com.mstar.android.tvapi.common.vo.PqRange;
import com.mstar.android.tvapi.common.vo.SwdrLevel;
import com.mstar.android.tvapi.common.vo.TestPattern;
import com.mstar.android.tvapi.common.vo.TimingInfo;
import com.mstar.android.tvapi.common.vo.TvOsType;
import com.mstar.android.tvapi.common.vo.UltraBlackWhite;
import com.mstar.android.tvapi.common.vo.VideoInfo;
import com.mstar.android.tvapi.common.vo.VideoWindowType;
import java.util.ArrayList;
import java.util.Iterator;

/* JADX INFO: loaded from: classes.dex */
public class TvPictureManager extends IEventClient.Stub {
    public static final int ADVANCE_COLOR_HSB_BRIGHTNESS = 2;
    public static final int ADVANCE_COLOR_HSB_HUE = 0;
    public static final int ADVANCE_COLOR_HSB_SATURATION = 1;
    public static final int ADVANCE_COLOR_WIN0 = 0;
    public static final int ADVANCE_COLOR_WIN1 = 1;
    public static final int ADVANCE_COLOR_WIN10 = 10;
    public static final int ADVANCE_COLOR_WIN11 = 11;
    public static final int ADVANCE_COLOR_WIN12 = 12;
    public static final int ADVANCE_COLOR_WIN13 = 13;
    public static final int ADVANCE_COLOR_WIN14 = 14;
    public static final int ADVANCE_COLOR_WIN15 = 15;
    public static final int ADVANCE_COLOR_WIN2 = 2;
    public static final int ADVANCE_COLOR_WIN3 = 3;
    public static final int ADVANCE_COLOR_WIN4 = 4;
    public static final int ADVANCE_COLOR_WIN5 = 5;
    public static final int ADVANCE_COLOR_WIN6 = 6;
    public static final int ADVANCE_COLOR_WIN7 = 7;
    public static final int ADVANCE_COLOR_WIN8 = 8;
    public static final int ADVANCE_COLOR_WIN9 = 9;
    public static final int AFD_ASP_16TO9 = 3;
    public static final int AFD_ASP_1TO1 = 1;
    public static final int AFD_ASP_221TO100 = 4;
    public static final int AFD_ASP_4TO3 = 2;
    public static final int AFD_ASP_FORBIDDEN = 0;
    public static final int AFD_BOX_14X9_TOP = 3;
    public static final int AFD_BOX_16X9 = 4;
    public static final int AFD_BOX_16X9_TOP = 2;
    public static final int AFD_CENTRE_14X9 = 11;
    public static final int AFD_CENTRE_16X9 = 10;
    public static final int AFD_CENTRE_16X9_14X9 = 14;
    public static final int AFD_CENTRE_16X9_4X3 = 15;
    public static final int AFD_CENTRE_4X3_14X9 = 13;
    public static final int AFD_CENTRE_4x3 = 9;
    public static final int AFD_FULL_FRAME = 8;
    public static final int AFD_INVALID = 255;
    public static final int AFD_UNKNOWN = 0;
    public static final int ARC_DESCRIPTION_AFD = 1;
    public static final int ARC_DESCRIPTION_NONE = 0;
    public static final int ARC_DESCRIPTION_WSS = 2;
    public static final int COLOR_TEMP_COOL = 0;
    public static final int COLOR_TEMP_NATURE = 1;
    public static final int COLOR_TEMP_USER1 = 3;
    public static final int COLOR_TEMP_USER2 = 4;
    public static final int COLOR_TEMP_WARM = 2;
    public static final int EQ_TYPE_DLC = 0;
    public static final int EQ_TYPE_GAMMA = 3;
    public static final int EQ_TYPE_HSB = 1;
    public static final int EQ_TYPE_HSY = 2;
    public static final int FILM_MODE_OFF = 0;
    public static final int FILM_MODE_ON = 1;
    public static final int GAMMA_IRE_100IRE = 9;
    public static final int GAMMA_IRE_10IRE = 0;
    public static final int GAMMA_IRE_20IRE = 1;
    public static final int GAMMA_IRE_30IRE = 2;
    public static final int GAMMA_IRE_40IRE = 3;
    public static final int GAMMA_IRE_50IRE = 4;
    public static final int GAMMA_IRE_60IRE = 5;
    public static final int GAMMA_IRE_70IRE = 6;
    public static final int GAMMA_IRE_80IRE = 7;
    public static final int GAMMA_IRE_90IRE = 8;
    public static final int GAMMA_IRE_OFF = 65535;
    public static final int GAMMA_TABLE_BLUE = 2;
    public static final int GAMMA_TABLE_GREEN = 1;
    public static final int GAMMA_TABLE_RED = 0;
    public static final int HDMI_COLOR_RGB = 0;
    public static final int HDMI_COLOR_YUV_422 = 1;
    public static final int HDMI_COLOR_YUV_444 = 2;
    public static final int HDR_DOLBY_ATTRIBUTES = 1;
    public static final int HDR_DOLBY_LEVEL_OFF = 0;
    public static final int HDR_DOLBY_LEVEL_VIVID = 1;
    public static final int HDR_ERROR_CODE_NOT_SUPPORT = 2;
    public static final int HDR_ERROR_CODE_STILL_WORK = 3;
    public static final int HDR_ERROR_CODE_SUCCESS = 0;
    public static final int HDR_ERROR_CODE_UNDEFINED_FAIL = 1;
    public static final int HDR_OPEN_ATTRIBUTES = 0;
    public static final int HDR_OPEN_LEVEL_AUTO = 1;
    public static final int HDR_OPEN_LEVEL_HIGH = 4;
    public static final int HDR_OPEN_LEVEL_LOW = 2;
    public static final int HDR_OPEN_LEVEL_MIDDLE = 3;
    public static final int HDR_OPEN_LEVEL_OFF = 0;
    public static final int HDR_OPEN_LEVEL_REF_MODE = 5;
    public static final int MFC_LEVEL_BYPASS = 4;
    public static final int MFC_LEVEL_HIGH = 3;
    public static final int MFC_LEVEL_LOW = 1;
    public static final int MFC_LEVEL_MID = 2;
    public static final int MFC_LEVEL_OFF = 0;
    public static final int MFC_MODE_BYPASS = 4;
    public static final int MFC_MODE_HIGH = 2;
    public static final int MFC_MODE_LOW = 1;
    public static final int MFC_MODE_MIDDLE = 3;
    public static final int MFC_MODE_OFF = 0;
    public static final int MPEG_NR_MODE_HIGH = 3;
    public static final int MPEG_NR_MODE_LOW = 1;
    public static final int MPEG_NR_MODE_MIDDLE = 2;
    public static final int MPEG_NR_MODE_OFF = 0;
    public static final int MVOP_PATTERN_MODE = 0;
    public static final int MWE_DEMO_MODE_CENTERBASEDSCALE = 5;
    public static final int MWE_DEMO_MODE_CUSTOMER1 = 12;
    public static final int MWE_DEMO_MODE_CUSTOMER2 = 13;
    public static final int MWE_DEMO_MODE_CUSTOMER3 = 14;
    public static final int MWE_DEMO_MODE_CUSTOMER4 = 15;
    public static final int MWE_DEMO_MODE_CUSTOMER5 = 16;
    public static final int MWE_DEMO_MODE_CUSTOMER6 = 17;
    public static final int MWE_DEMO_MODE_CUSTOMER7 = 18;
    public static final int MWE_DEMO_MODE_CUSTOMER8 = 19;
    public static final int MWE_DEMO_MODE_DYNAMICCOMPARE = 4;
    public static final int MWE_DEMO_MODE_ENHANC = 2;
    public static final int MWE_DEMO_MODE_GOLDENEYES = 7;
    public static final int MWE_DEMO_MODE_HIGH_SPEED_MOVEMENT_PROCESSINGF = 10;
    public static final int MWE_DEMO_MODE_LED_BACKLIGHT_CONTROL = 9;
    public static final int MWE_DEMO_MODE_MOVEALON = 6;
    public static final int MWE_DEMO_MODE_OFF = 0;
    public static final int MWE_DEMO_MODE_OPTIMIZE = 1;
    public static final int MWE_DEMO_MODE_SIDE_BY_SIDE = 3;
    public static final int MWE_DEMO_MODE_SQUAREMOVE = 11;
    public static final int MWE_DEMO_MODE_TRUE_COLOR_ANALYSIS_ASCENSION = 8;
    public static final int NR_MODE_AUTO = 4;
    public static final int NR_MODE_HIGH = 3;
    public static final int NR_MODE_LOW = 1;
    public static final int NR_MODE_MIDDLE = 2;
    public static final int NR_MODE_OFF = 0;
    public static final int PICTURE_BACKLIGHT = 5;
    public static final int PICTURE_BRIGHTNESS = 0;
    public static final int PICTURE_CONTRAST = 1;
    public static final int PICTURE_HUE = 4;
    public static final int PICTURE_MODE_AUTO = 5;
    public static final int PICTURE_MODE_DYNAMIC = 0;
    public static final int PICTURE_MODE_GAME = 4;
    public static final int PICTURE_MODE_NATURAL = 8;
    public static final int PICTURE_MODE_NORMAL = 1;
    public static final int PICTURE_MODE_PC = 6;
    public static final int PICTURE_MODE_SOFT = 2;
    public static final int PICTURE_MODE_SPORTS = 9;
    public static final int PICTURE_MODE_USER = 3;
    public static final int PICTURE_MODE_VIVID = 7;
    public static final int PICTURE_SATURATION = 2;
    public static final int PICTURE_SHARPNESS = 3;
    public static final int PQ_MODELITEM_BLUE = 2;
    public static final int PQ_MODELITEM_CYAN = 3;
    public static final int PQ_MODELITEM_DLC = 8;
    public static final int PQ_MODELITEM_FLESH = 6;
    public static final int PQ_MODELITEM_GAMMA = 7;
    public static final int PQ_MODELITEM_GREEN = 1;
    public static final int PQ_MODELITEM_MAGENTA = 4;
    public static final int PQ_MODELITEM_RED = 0;
    public static final int PQ_MODELITEM_YELLOW = 5;
    public static final int PQ_MODEL_DLC = 4;
    public static final int PQ_MODEL_GAMMA = 3;
    public static final int PQ_MODEL_HSY_HUE = 0;
    public static final int PQ_MODEL_HSY_LUMINANCE = 2;
    public static final int PQ_MODEL_HSY_SATURATION = 1;
    public static final int PQ_SETTING_HSY_OFF = 0;
    public static final int PQ_SETTING_HSY_ON = 1;
    public static final int RESOURCE_CONFLICT_3D_ID = 2;
    public static final int RESOURCE_CONFLICT_HDR_ID = 1;
    private static final String TAG = "TvPictureManager";
    public static final int TVPICTURE_EVENT_CONFLICT = 1;
    private static final int TVPICTURE_EVENT_CONFLICT_END = 999;
    private static final int TVPICTURE_EVENT_CONFLICT_START = 0;
    public static final int TVPICTURE_EVENT_VIDEO_STATUS = 1001;
    private static final int TVPICTURE_EVENT_VIDEO_STATUS_END = 1999;
    private static final int TVPICTURE_EVENT_VIDEO_STATUS_START = 1000;
    public static final int VIDEO_ARC_14x9 = 8;
    public static final int VIDEO_ARC_16x9 = 1;
    public static final int VIDEO_ARC_16x9_COMBIND = 18;
    public static final int VIDEO_ARC_16x9_PANSCAN = 16;
    public static final int VIDEO_ARC_16x9_PILLARBOX = 15;
    public static final int VIDEO_ARC_4x3 = 2;
    public static final int VIDEO_ARC_4x3_COMBIND = 17;
    public static final int VIDEO_ARC_4x3_LETTERBOX = 14;
    public static final int VIDEO_ARC_4x3_PANSCAN = 13;
    public static final int VIDEO_ARC_AUTO = 3;
    public static final int VIDEO_ARC_CUSTOMIZE = 32;
    public static final int VIDEO_ARC_DEFAULT = 0;
    public static final int VIDEO_ARC_DOTBYDOT = 9;
    public static final int VIDEO_ARC_JUSTSCAN = 5;
    public static final int VIDEO_ARC_MAX = 64;
    public static final int VIDEO_ARC_MOVIE = 11;
    public static final int VIDEO_ARC_PANORAMA = 4;
    public static final int VIDEO_ARC_PERSONAL = 12;
    public static final int VIDEO_ARC_SUBTITLE = 10;
    public static final int VIDEO_ARC_ZOOM1 = 6;
    public static final int VIDEO_ARC_ZOOM2 = 7;
    public static final int VIDEO_ARC_Zoom_2x = 19;
    public static final int VIDEO_ARC_Zoom_3x = 20;
    public static final int VIDEO_ARC_Zoom_4x = 21;
    public static final int VIDEO_DOLBY_HDR_RUNNING = 2;
    public static final int VIDEO_MAIN_WINDOW = 0;
    public static final int VIDEO_OPEN_HDR_RUNNING = 1;
    public static final int VIDEO_SUB_WINDOW = 1;
    public static final int VIDEO_VIDEO_HDR_STOP = 0;
    public static final int WSS_ARC14x9_FULL_CENTER = 6;
    public static final int WSS_ARC14x9_LETTERBOX_CENTER = 1;
    public static final int WSS_ARC14x9_LETTERBOX_TOP = 2;
    public static final int WSS_ARC16x9_ANAMORPHIC = 7;
    public static final int WSS_ARC16x9_LETTERBOX_CENTER = 3;
    public static final int WSS_ARC16x9_LETTERBOX_TOP = 4;
    public static final int WSS_ARC4x3_FULL = 0;
    public static final int WSS_ARC_ABOVE16x9_LETTERBOX_CENTER = 5;
    public static final int WSS_ARC_INVALID = 8;
    public static final int XC_ADC_PATTERN_MODE = 1;
    public static final int XC_IPMUX_PATTERN_MODE = 2;
    public static final int XC_IP_PATTERN_MODE = 3;
    public static final int XC_MOD_PATTERN_MODE = 7;
    public static final int XC_OP_PATTERN_MODE = 4;
    public static final int XC_VOP2_PATTERN_MODE = 6;
    public static final int XC_VOP_PATTERN_MODE = 5;
    public static final int XC_WHITE_BALANCE_PATTERN_MODE = 8;
    private static TvPictureManager mInstance;
    private static ITvPicture mService;
    private EventHandler mHandler;
    private ArrayList<OnConflictEventListener> mConflictEventListeners = new ArrayList<>();
    private ArrayList<OnVideoStatusEventListener> mVideoStatusEventListeners = new ArrayList<>();

    private class EventHandler extends Handler {
        EventHandler(Looper looper) {
            super(looper);
        }

        @Override // android.os.Handler
        public void handleMessage(Message message) {
            int i2 = message.what;
            if (i2 > 0 && i2 < 999) {
                synchronized (TvPictureManager.this.mConflictEventListeners) {
                    try {
                        Iterator it = TvPictureManager.this.mConflictEventListeners.iterator();
                        while (it.hasNext()) {
                            ((OnConflictEventListener) it.next()).onConflictEvent(message.what, message.arg1, message.arg2, message.obj);
                        }
                    } finally {
                    }
                }
                return;
            }
            if (i2 <= 1000 || i2 >= 1999) {
                return;
            }
            synchronized (TvPictureManager.this.mVideoStatusEventListeners) {
                try {
                    Iterator it2 = TvPictureManager.this.mVideoStatusEventListeners.iterator();
                    while (it2.hasNext()) {
                        ((OnVideoStatusEventListener) it2.next()).onVideoStatusEvent(message.what, message.arg1, message.arg2, message.obj);
                    }
                } finally {
                }
            }
        }
    }

    public interface OnConflictEventListener {
        boolean onConflictEvent(int i2, int i3, int i4, Object obj);
    }

    public interface OnVideoStatusEventListener {
        boolean onVideoStatusEvent(int i2, int i3, int i4, Object obj);
    }

    private TvPictureManager() throws TvCommonException {
        this.mHandler = null;
        if (true == TvServiceBinder.isNeedBindService()) {
            ITvService tvService = TvServiceBinder.getTvService();
            if (tvService == null) {
                Log.e(TAG, "TvService doesn't exist!!");
                throw new TvCommonException("TvService doesn't exist.");
            }
            try {
                mService = tvService.getTvPicture();
            } catch (RemoteException e2) {
                e2.printStackTrace();
            }
        } else {
            IBinder service = ServiceManager.getService("tv");
            if (service == null) {
                Log.e(TAG, "TvService doesn't exist!!");
                throw new TvCommonException("TvService doesn't exist.");
            }
            try {
                mService = ITvService.Stub.asInterface(service).getTvPicture();
            } catch (RemoteException e3) {
                e3.printStackTrace();
            }
        }
        Looper looperMyLooper = Looper.myLooper();
        if (looperMyLooper != null) {
            this.mHandler = new EventHandler(looperMyLooper);
        } else {
            Looper mainLooper = Looper.getMainLooper();
            if (mainLooper != null) {
                this.mHandler = new EventHandler(mainLooper);
            } else {
                this.mHandler = null;
            }
        }
        try {
            mService.addClient(this);
        } catch (RemoteException e4) {
            e4.printStackTrace();
        }
    }

    public static TvPictureManager getInstance() {
        if (mInstance == null) {
            synchronized (TvPictureManager.class) {
                if (mInstance == null) {
                    try {
                        mInstance = new TvPictureManager();
                    } catch (TvCommonException e2) {
                        e2.printStackTrace();
                        return null;
                    }
                }
            }
        }
        return mInstance;
    }

    public int GetReproduce() {
        int reproduceRate;
        try {
            reproduceRate = mService.getReproduceRate();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            reproduceRate = 0;
        }
        Log.d(TAG, "GetReproduce() return = " + reproduceRate);
        return reproduceRate;
    }

    public byte GetResloution() {
        byte resolution;
        try {
            resolution = mService.getResolution();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            resolution = 0;
        }
        Log.d(TAG, "GetResloution() return = " + ((int) resolution));
        return resolution;
    }

    public void SetReproduce(int i2) {
        Log.d(TAG, "SetReproduce()");
        try {
            mService.setReproduceRate(i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
        }
    }

    public void SetResolution(byte b2) {
        Log.d(TAG, "SetResolution() resolution = " + ((int) b2));
        try {
            mService.setResolution(b2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
        }
    }

    public int cvte_GetDCRBacklightMAX() {
        Log.d(TAG, "cvte_GetDCRBacklightMAX");
        try {
            return mService.cvte_GetDCRBacklightMAX();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return 0;
        }
    }

    public int cvte_GetDCRBacklightRange() {
        Log.d(TAG, "cvte_GetDCRBacklightRange");
        try {
            return mService.cvte_GetDCRBacklightRange();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return 0;
        }
    }

    public int cvte_GetDCRBacklightStep() {
        Log.d(TAG, "cvte_GetDCRBacklightStep");
        try {
            return mService.cvte_GetDCRBacklightStep();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return 0;
        }
    }

    public int cvte_GetDCREnableStatus() {
        Log.d(TAG, "cvte_GetDCREnableStatus");
        try {
            return mService.cvte_GetDCREnableStatus();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return 0;
        }
    }

    public int cvte_GetDCRStepTime() {
        Log.d(TAG, "cvte_GetDCRStepTime");
        try {
            return mService.cvte_GetDCRStepTime();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return 0;
        }
    }

    public void cvte_SetDCRBacklightMAX(int i2) {
        Log.d(TAG, "cvte_SetDCRBacklightMAX");
        try {
            mService.cvte_SetDCRBacklightMAX(i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
        }
    }

    public void cvte_SetDCRBacklightRange(int i2) {
        Log.d(TAG, "cvte_SetDCRBacklightRange");
        try {
            mService.cvte_SetDCRBacklightRange(i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
        }
    }

    public void cvte_SetDCRBacklightStep(int i2) {
        Log.d(TAG, "cvte_SetDCRBacklightStep");
        try {
            mService.cvte_SetDCRBacklightStep(i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
        }
    }

    public void cvte_SetDCREnableStatus(int i2) {
        Log.d(TAG, "cvte_SetDCREnableStatus");
        try {
            mService.cvte_SetDCREnableStatus(i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
        }
    }

    public void cvte_SetDCRStepTime(int i2) {
        Log.d(TAG, "cvte_SetDCRStepTime");
        try {
            mService.cvte_SetDCRStepTime(i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
        }
    }

    public void disableBacklight() {
        Log.d(TAG, "disableBacklight");
        try {
            mService.disableBacklight();
        } catch (RemoteException e2) {
            e2.printStackTrace();
        }
    }

    public boolean disableDbc() {
        boolean zDisableDbc;
        try {
            zDisableDbc = mService.disableDbc();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            zDisableDbc = false;
        }
        Log.d(TAG, "disableDbc() return = " + zDisableDbc);
        return zDisableDbc;
    }

    public boolean disableDcc() {
        boolean zDisableDcc;
        try {
            zDisableDcc = mService.disableDcc();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            zDisableDcc = false;
        }
        Log.d(TAG, "disableDcc() return = " + zDisableDcc);
        return zDisableDcc;
    }

    public boolean disableDlc() {
        boolean zDisableDlc;
        try {
            zDisableDlc = mService.disableDlc();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            zDisableDlc = false;
        }
        Log.d(TAG, "disableDlc() return = " + zDisableDlc);
        return zDisableDlc;
    }

    public void enableBacklight() {
        Log.d(TAG, "enableBacklight");
        try {
            mService.enableBacklight();
        } catch (RemoteException e2) {
            e2.printStackTrace();
        }
    }

    public boolean enableDbc() {
        boolean zEnableDbc;
        try {
            zEnableDbc = mService.enableDbc();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            zEnableDbc = false;
        }
        Log.d(TAG, "enableDbc() return = " + zEnableDbc);
        return false;
    }

    public boolean enableDcc() {
        boolean zEnableDcc;
        try {
            zEnableDcc = mService.enableDcc();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            zEnableDcc = false;
        }
        Log.d(TAG, "enableDcc() return = " + zEnableDcc);
        return zEnableDcc;
    }

    public boolean enableDlc() {
        boolean zEnableDlc;
        try {
            zEnableDlc = mService.enableDlc();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            zEnableDlc = false;
        }
        Log.d(TAG, "enableDlc() return = " + zEnableDlc);
        return zEnableDlc;
    }

    public boolean enableXvyccCompensation(boolean z2, int i2) {
        boolean zEnableXvyccCompensation;
        Log.d(TAG, "enableXvyccCompensation bEn = " + z2 + " eWin = " + i2);
        try {
            zEnableXvyccCompensation = mService.enableXvyccCompensation(z2, i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            zEnableXvyccCompensation = false;
        }
        Log.d(TAG, "enableXvyccCompensation return = " + zEnableXvyccCompensation);
        return zEnableXvyccCompensation;
    }

    public boolean execAutoPc() {
        boolean zExecAutoPc;
        try {
            zExecAutoPc = mService.execAutoPc();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            zExecAutoPc = false;
        }
        Log.d(TAG, "execAutoPc() return = " + zExecAutoPc);
        return zExecAutoPc;
    }

    public boolean freezeImage() {
        boolean zFreezeImage;
        try {
            zFreezeImage = mService.freezeImage();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            zFreezeImage = false;
        }
        Log.d(TAG, "freezeImage() return = " + zFreezeImage);
        return zFreezeImage;
    }

    public void generateTestPattern(int i2, TestPattern testPattern) {
        Log.d(TAG, "generateTestPattern");
        try {
            mService.generateTestPattern(i2, testPattern);
        } catch (RemoteException e2) {
            e2.printStackTrace();
        }
    }

    public int[] getAdvanceColor(int i2) {
        try {
            return mService.getAdvanceColor(i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return null;
        }
    }

    public boolean getAdvanceColorEnable() {
        try {
            return mService.getAdvanceColorEnable();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    public int[] getAdvanceColorIniSetting() {
        try {
            return mService.getAdvanceColorIniSetting();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return null;
        }
    }

    public boolean[] getAspectRationList() {
        try {
            return mService.getAspectRationList();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return null;
        }
    }

    public int getBacklight() {
        int backlight;
        try {
            backlight = mService.getBacklight();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            backlight = -1;
        }
        Log.d(TAG, "getBacklight(), return int " + backlight);
        return backlight;
    }

    public byte getColorRange() {
        byte colorRange;
        try {
            colorRange = mService.getColorRange();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            colorRange = -1;
        }
        Log.d(TAG, "getColorRange(), return byte " + ((int) colorRange));
        return colorRange;
    }

    @Deprecated
    public EnumColorTemperature getColorTempIdx() {
        for (EnumColorTemperature enumColorTemperature : EnumColorTemperature.values()) {
            if (enumColorTemperature.getValue() == getColorTempratureIdx()) {
                Log.d(TAG, "getColorTempIdx(), return EnumColorTemperature " + enumColorTemperature);
                return enumColorTemperature;
            }
        }
        return null;
    }

    @Deprecated
    public int getColorTemprature() {
        Log.d(TAG, "getColorTemprature()");
        try {
            return mService.getColorTempIdx();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return 1;
        }
    }

    public ColorTemperatureExData getColorTempratureEx() {
        ColorTemperatureExData colorTempratureEx = null;
        try {
            colorTempratureEx = mService.getColorTempratureEx();
            Log.d(TAG, "getColorTemprature, return ColorTemperatureExData redGain = " + colorTempratureEx.redGain + ", blueGain = " + colorTempratureEx.blueGain + ", greenGain = " + colorTempratureEx.greenGain + ", redOffset = " + colorTempratureEx.redOffset + ", blueOffse = " + colorTempratureEx.blueOffset + ", greenOffset = " + colorTempratureEx.greenOffset);
            return colorTempratureEx;
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return colorTempratureEx;
        }
    }

    public int getColorTempratureIdx() {
        Log.d(TAG, "getColorTempratureIdx()");
        try {
            return mService.getColorTempIdx();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return 1;
        }
    }

    public int getCurrentTimingId() {
        try {
            return mService.getCurrentTimingId();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return 0;
        }
    }

    @Deprecated
    public MweType.EnumMweType getDemoMode() {
        return MweType.EnumMweType.values()[getMWEDemoMode()];
    }

    public int getFilm() {
        Log.d(TAG, "getFilm()");
        try {
            return mService.getFilmMode();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return 0;
        }
    }

    @Deprecated
    public Film.EnumFilm getFilmMode() {
        Log.d(TAG, "getFilmMode()");
        for (Film.EnumFilm enumFilm : Film.EnumFilm.values()) {
            if (enumFilm.getValue() == getFilm()) {
                Log.d(TAG, "getFilmMode(), return EnumFilm " + enumFilm);
                return enumFilm;
            }
        }
        return null;
    }

    public int[] getGamma(int i2) {
        try {
            return mService.getGamma(i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return null;
        }
    }

    public boolean getGammaEnable() {
        try {
            return mService.getGammaEnable();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    public int[] getGammaIniSetting() {
        try {
            return mService.getGammaIniSetting();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return null;
        }
    }

    public int getHDMIColorFormat() {
        int hDMIColorFormat = 0;
        try {
            hDMIColorFormat = mService.getHDMIColorFormat();
            Log.d(TAG, "getHDMIColorFormat return = " + hDMIColorFormat);
            return hDMIColorFormat;
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return hDMIColorFormat;
        }
    }

    public HdrAttribute getHdrAttributes(int i2, int i3) {
        Log.d(TAG, "getHdrAttributes");
        try {
            return mService.getHdrAttributes(i2, i3);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return null;
        }
    }

    public int getITC() {
        int itc;
        try {
            itc = mService.getITC();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            itc = 0;
        }
        Log.d(TAG, "GetITC(), return " + itc);
        return itc;
    }

    public int getIsPcMode() {
        int isPcMode;
        try {
            isPcMode = mService.getIsPcMode();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            isPcMode = 0;
        }
        Log.d(TAG, "getIsPcMode(), return " + isPcMode);
        return isPcMode;
    }

    public int getMWEDemoMode() {
        try {
            return mService.getDemoMode();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return 0;
        }
    }

    public int getMfcLevel() {
        try {
            return mService.getMfcLevel();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return 0;
        }
    }

    @Deprecated
    public MpegNoiseReduction.EnumMpegNoiseReduction getMpegNR() {
        try {
            for (MpegNoiseReduction.EnumMpegNoiseReduction enumMpegNoiseReduction : MpegNoiseReduction.EnumMpegNoiseReduction.values()) {
                if (enumMpegNoiseReduction.getValue() == mService.getMpegNR()) {
                    Log.d(TAG, "getMpegNR(), return en " + enumMpegNoiseReduction);
                    return enumMpegNoiseReduction;
                }
            }
            return null;
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return null;
        }
    }

    public int getMpegNoiseReduction() {
        try {
            return mService.getMpegNR();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return 0;
        }
    }

    @Deprecated
    public NoiseReduction.EnumNoiseReduction getNR() {
        try {
            for (NoiseReduction.EnumNoiseReduction enumNoiseReduction : NoiseReduction.EnumNoiseReduction.values()) {
                if (enumNoiseReduction.getValue() == mService.getNR()) {
                    Log.d(TAG, "getNR(), return en " + enumNoiseReduction);
                    return enumNoiseReduction;
                }
            }
            return null;
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return null;
        }
    }

    public int getNoiseReduction() {
        try {
            return mService.getNR();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return 0;
        }
    }

    public int getPCClock() {
        int pCClock;
        try {
            pCClock = mService.getPCClock();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            pCClock = -1;
        }
        Log.d(TAG, "getPCClock(), return int " + pCClock);
        return pCClock;
    }

    public int getPCHPos() {
        int pCHPos;
        try {
            pCHPos = mService.getPCHPos();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            pCHPos = -1;
        }
        Log.d(TAG, "getPCHPos(), return int " + pCHPos);
        return pCHPos;
    }

    public int getPCPhase() {
        int pCPhase;
        try {
            pCPhase = mService.getPCPhase();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            pCPhase = -1;
        }
        Log.d(TAG, "getPCPhase(), return int " + pCPhase);
        return pCPhase;
    }

    public int getPCVPos() {
        int pCVPos;
        try {
            pCVPos = mService.getPCVPos();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            pCVPos = -1;
        }
        Log.d(TAG, "getPCVPos(), return int " + pCVPos);
        return pCVPos;
    }

    public PanelProperty getPanelWidthHeight() {
        try {
            PanelProperty panelWidthHeight = mService.getPanelWidthHeight();
            Log.d(TAG, "get Panel Width = " + panelWidthHeight.width + " Height = " + panelWidthHeight.height);
            return panelWidthHeight;
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return null;
        }
    }

    public int[] getPcModeInfo() {
        Log.d(TAG, "getPcModeInfo()");
        try {
            return mService.getPcModeInfo();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return null;
        }
    }

    public int getPictureMode() {
        Log.d(TAG, "getPictureMode()");
        try {
            return mService.getPictureModeIdx();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return 1;
        }
    }

    @Deprecated
    public EnumPictureMode getPictureModeIdx() {
        Log.d(TAG, "getPictureModeIdx()");
        return EnumPictureMode.values()[getPictureMode()];
    }

    public PqRange getPqRange(int i2, int i3, int i4) {
        Log.d(TAG, "getPqRange");
        try {
            return mService.getPqRange(i2, i3, i4);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return null;
        }
    }

    public int getPqStatus(int i2, int i3) {
        Log.d(TAG, "getPqStatus");
        try {
            return mService.getPqStatus(i2, i3);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return 0;
        }
    }

    public PglValue getPqValue(int i2, int i3, int i4) {
        Log.d(TAG, "getPqValue");
        try {
            return mService.getPqValue(i2, i3, i4);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return null;
        }
    }

    public int getReproduceRate() {
        int reproduceRate = 0;
        try {
            reproduceRate = mService.getReproduceRate();
            Log.d(TAG, "getReproduceRate return = " + reproduceRate);
            return reproduceRate;
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return reproduceRate;
        }
    }

    public TimingInfo[] getSupportedTimingList() {
        try {
            return mService.getSupportedTimingList();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return null;
        }
    }

    public int getSupportedTimingListCount() {
        try {
            return mService.getSupportedTimingListCount();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return 0;
        }
    }

    public SwdrLevel getSwdrInfo() {
        Log.d(TAG, "getSwdrInfo");
        try {
            return mService.getSwdrInfo();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return null;
        }
    }

    public SwdrLevel getSwdrLevel() {
        Log.d(TAG, "getSwdrLevel");
        try {
            return mService.getSwdrLevel();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return null;
        }
    }

    public UltraBlackWhite getUltraBlackWhite() {
        Log.d(TAG, "getUltraBlackWhite");
        try {
            UltraBlackWhite ultraBlackWhite = mService.getUltraBlackWhite();
            Log.d(TAG, "UltraBlackLevel = " + ultraBlackWhite.ultraBlackLevel + "UltraWhiteLevel" + ultraBlackWhite.ultraWhiteLevel);
            return ultraBlackWhite;
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return null;
        }
    }

    @Deprecated
    public EnumVideoArcType getVideoArc() {
        Log.d(TAG, "getVideoArc()");
        return EnumVideoArcType.values()[getVideoArcType()];
    }

    public int getVideoArcType() {
        Log.d(TAG, "getVideoArcType()");
        try {
            return mService.getVideoArc();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return 1;
        }
    }

    public VideoInfo getVideoInfo() {
        VideoInfo videoInfo = null;
        try {
            videoInfo = mService.getVideoInfo();
            Log.d(TAG, "getVideoInfo, return VideoInfo videoInfo.frameRate = " + videoInfo.frameRate + ", videoInfo.hResolution = " + videoInfo.hResolution + ", videoInfo.modeIndex = " + videoInfo.modeIndex + ", videoInfo.vResolution = " + videoInfo.vResolution + ", videoInfo.arcDescriptionType = " + videoInfo.arcDescriptionType + ", videoInfo.arcType = " + videoInfo.arcType);
            return videoInfo;
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return videoInfo;
        }
    }

    @Deprecated
    public int getVideoItem(EnumVideoItem enumVideoItem) {
        Log.d(TAG, "getVideoItem(), paras eIndex = " + enumVideoItem);
        return getVideoItem(enumVideoItem.ordinal());
    }

    @Deprecated
    public int getVideoItemByInputSource(EnumVideoItem enumVideoItem, TvOsType.EnumInputSource enumInputSource) {
        Log.d(TAG, "getVideoItem(), paras eIndex = " + enumVideoItem + ", input = " + enumInputSource);
        return getVideoItemByInputSource(enumVideoItem.ordinal(), enumInputSource.ordinal());
    }

    public boolean getxvYCCEnable() {
        boolean z2 = false;
        try {
            z2 = mService.getxvYCCEnable();
            Log.d(TAG, "getxvYCCEnable return = " + z2);
            return z2;
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return z2;
        }
    }

    public boolean is3DTVPlugedIn() {
        try {
            return mService.is3DTVPlugedIn();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    public boolean is4K2KMode(boolean z2) {
        boolean zIs4K2KMode;
        try {
            zIs4K2KMode = mService.is4K2KMode(z2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            zIs4K2KMode = false;
        }
        Log.d(TAG, "is4K2KMode() return = " + zIs4K2KMode);
        return zIs4K2KMode;
    }

    public boolean isDbcEnabled() {
        boolean zIsDbcEnabled;
        try {
            zIsDbcEnabled = mService.isDbcEnabled();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            zIsDbcEnabled = false;
        }
        Log.d(TAG, "isDbcEnabled() return = " + zIsDbcEnabled);
        return zIsDbcEnabled;
    }

    public boolean isDccEnabled() {
        boolean zIsDccEnabled;
        try {
            zIsDccEnabled = mService.isDccEnabled();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            zIsDccEnabled = false;
        }
        Log.d(TAG, "isDccEnabled() return = " + zIsDccEnabled);
        return zIsDccEnabled;
    }

    public boolean isDlcEnabled() {
        boolean zIsDlcEnabled;
        try {
            zIsDlcEnabled = mService.isDlcEnabled();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            zIsDlcEnabled = false;
        }
        Log.d(TAG, "isDlcEnabled() return = " + zIsDlcEnabled);
        return zIsDlcEnabled;
    }

    public boolean isImageFreezed() {
        boolean zIsImageFreezed;
        try {
            zIsImageFreezed = mService.isImageFreezed();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            zIsImageFreezed = false;
        }
        Log.d(TAG, "isImageFreezed() return = " + zIsImageFreezed);
        return zIsImageFreezed;
    }

    public boolean isSupportedZoom() {
        try {
            return mService.isSupportedZoom();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    public boolean isUClearOn() {
        boolean zIsUClearOn;
        try {
            zIsUClearOn = mService.isUClearOn();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            zIsUClearOn = false;
        }
        Log.d(TAG, "isUClearOn return " + zIsUClearOn);
        return zIsUClearOn;
    }

    @Override // com.mstar.android.tv.IEventClient
    public boolean onEvent(Message message) throws RemoteException {
        EventHandler eventHandler = this.mHandler;
        if (eventHandler == null) {
            return true;
        }
        Message messageObtainMessage = eventHandler.obtainMessage();
        messageObtainMessage.copyFrom(message);
        this.mHandler.sendMessage(messageObtainMessage);
        return true;
    }

    public boolean registerOnConflictEventListener(OnConflictEventListener onConflictEventListener) {
        Log.d(TAG, "registerOnConflictEventListener");
        synchronized (this.mConflictEventListeners) {
            this.mConflictEventListeners.add(onConflictEventListener);
        }
        return true;
    }

    public boolean registerOnVideoStatusEventListener(OnVideoStatusEventListener onVideoStatusEventListener) {
        Log.d(TAG, "OnVideoStatusEventListener");
        synchronized (this.mVideoStatusEventListeners) {
            this.mVideoStatusEventListeners.add(onVideoStatusEventListener);
        }
        return true;
    }

    public boolean resetAdvanceColor() {
        try {
            return mService.resetAdvanceColor();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    public boolean resetGamma() {
        try {
            return mService.resetGamma();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    public boolean resetPq(int i2, int i3) {
        Log.d(TAG, "resetPq");
        try {
            return mService.resetPq(i2, i3);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    public void selectWindow(int i2) {
        try {
            mService.selectWindow(i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
        }
    }

    public boolean setAdvanceColor(int i2, int i3, int i4) {
        try {
            return mService.setAdvanceColor(i2, i3, i4);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    public boolean setAdvanceColorEnable(boolean z2) {
        try {
            return mService.setAdvanceColorEnable(z2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    public boolean setBacklight(int i2) {
        Log.d(TAG, "setBacklight(), paras value = " + i2);
        try {
            return mService.setBacklight(i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    public boolean setColorRange(byte b2) {
        Log.d(TAG, "setAtvChannel(), paras value = " + ((int) b2));
        try {
            return mService.setColorRange(b2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    @Deprecated
    public boolean setColorTempIdx(EnumColorTemperature enumColorTemperature) {
        Log.d(TAG, "setColorTempIdx(), paras eColorTemp = " + enumColorTemperature);
        return setColorTempratureIdx(enumColorTemperature.getValue());
    }

    @Deprecated
    public boolean setColorTemprature(int i2) {
        Log.d(TAG, "setColorTemprature(), paras colorTemp = " + i2);
        try {
            return mService.setColorTempIdx(i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    public void setColorTempratureEx(ColorTemperatureExData colorTemperatureExData) {
        Log.d(TAG, "setColorTemprature");
        Log.d(TAG, "setColorTemprature, paras ColorTemperatureExData stColorTemp.redGain = " + colorTemperatureExData.redGain + ", stColorTemp.blueGain = " + colorTemperatureExData.blueGain + ", stColorTemp.greenGain = " + colorTemperatureExData.greenGain + ", stColorTemp.redOffset = " + colorTemperatureExData.redOffset + ", stColorTemp.blueOffse = " + colorTemperatureExData.blueOffset + ", stColorTemp.greenOffset = " + colorTemperatureExData.greenOffset);
        try {
            mService.setColorTempratureEx(colorTemperatureExData);
        } catch (RemoteException e2) {
            e2.printStackTrace();
        }
    }

    public boolean setColorTempratureIdx(int i2) {
        Log.d(TAG, "setColorTempratureIdx(), paras colorTempIdx = " + i2);
        try {
            return mService.setColorTempIdx(i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    @Deprecated
    public void setDemoMode(MweType.EnumMweType enumMweType) {
        Log.d(TAG, "setDemoMode() MweType = " + enumMweType);
        setMWEDemoMode(enumMweType.ordinal());
    }

    public void setDisplayWindow(VideoWindowType videoWindowType) {
        Log.d(TAG, "setDisplayWindow, paras VideoWindowType videoWindowType.x = " + videoWindowType.f3305x + ", videoWindowType.y = " + videoWindowType.f3306y + ", videoWindowType.width = " + videoWindowType.width + ", videoWindowType.height = " + videoWindowType.height);
        try {
            mService.setDisplayWindow(videoWindowType);
        } catch (RemoteException e2) {
            e2.printStackTrace();
        }
    }

    public void setDynamicBackLightThreadSleep(boolean z2) {
        Log.d(TAG, "setDynamicBackLightThreadSleep bFlag = " + z2);
        try {
            mService.forceThreadSleep(z2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
        }
    }

    public boolean setFilm(int i2) {
        Log.d(TAG, "setFilm(), paras filmMode = " + i2);
        try {
            return mService.setFilmMode(i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    @Deprecated
    public boolean setFilmMode(Film.EnumFilm enumFilm) {
        Log.d(TAG, "setFilmMode(), paras eMode = " + enumFilm);
        return setFilm(enumFilm.ordinal());
    }

    public boolean setGamma(int i2, int i3) {
        try {
            return mService.setGamma(i2, i3);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    public boolean setGammaEnable(boolean z2) {
        try {
            return mService.setGammaEnable(z2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    public boolean setHdrAttributes(int i2, int i3, int i4) {
        Log.d(TAG, "setHdrAttributes");
        try {
            return mService.setHdrAttributes(i2, i3, i4);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    public void setITC(int i2) {
        try {
            mService.setITC(i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
        }
    }

    public boolean setIrePattern(int i2) {
        try {
            return mService.setIrePattern(i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    public boolean setMEMCMode(String str) {
        boolean mEMCMode;
        try {
            mEMCMode = mService.setMEMCMode(str);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            mEMCMode = false;
        }
        Log.d(TAG, "setMEMCMode() return = " + mEMCMode);
        return mEMCMode;
    }

    public void setMWEDemoMode(int i2) {
        Log.d(TAG, "setMWEDemoMode(), paras demoMode = " + i2);
        try {
            mService.setDemoMode(i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
        }
    }

    public void setMfcLevel(int i2) {
        try {
            mService.setMfcLevel(i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
        }
    }

    public void setMfcMode(int i2) {
        Log.d(TAG, "setMfcMode(), paras eMode = " + i2);
        try {
            mService.setMfcMode(i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
        }
    }

    @Deprecated
    public boolean setMpegNR(MpegNoiseReduction.EnumMpegNoiseReduction enumMpegNoiseReduction) {
        Log.d(TAG, "setMpegNR(), paras eMpNRIdx = " + enumMpegNoiseReduction);
        try {
            return mService.setMpegNR(enumMpegNoiseReduction.getValue());
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    public boolean setMpegNoiseReduction(int i2) {
        Log.d(TAG, "setMpegNoiseReduction(), paras MpegNR = " + i2);
        try {
            return mService.setMpegNR(i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    @Deprecated
    public boolean setNR(NoiseReduction.EnumNoiseReduction enumNoiseReduction) {
        Log.d(TAG, "setNR(), paras eNRIdx = " + enumNoiseReduction);
        try {
            return mService.setNR(enumNoiseReduction.getValue());
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    public boolean setNoiseReduction(int i2) {
        Log.d(TAG, "setNR(), paras NR = " + i2);
        try {
            return mService.setNR(i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    public boolean setPCClock(int i2) {
        Log.d(TAG, "setPCClock(), paras clock = " + i2);
        try {
            return mService.setPCClock(i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    public boolean setPCHPos(int i2) {
        Log.d(TAG, "setPCHPos(), paras hpos = " + i2);
        try {
            return mService.setPCHPos(i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    public boolean setPCPhase(int i2) {
        Log.d(TAG, "setPCPhase(), paras phase = " + i2);
        try {
            return mService.setPCPhase(i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    public boolean setPCVPos(int i2) {
        Log.d(TAG, "setPCVPos(), paras vpos = " + i2);
        try {
            return mService.setPCVPos(i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    public boolean setPictureMode(int i2) {
        Log.d(TAG, "setPictureMode(), paras pictureMode = " + i2);
        try {
            return mService.setPictureModeIdx(i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    @Deprecated
    public boolean setPictureModeIdx(EnumPictureMode enumPictureMode) {
        Log.d(TAG, "setPictureModeIdx(), paras ePicMode = " + enumPictureMode);
        return setPictureMode(enumPictureMode.ordinal());
    }

    public boolean setPqStatus(int i2, int i3, int i4) {
        Log.d(TAG, "setPqStatus");
        try {
            return mService.setPqStatus(i2, i3, i4);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    public boolean setPqValue(int i2, int i3, int i4, int i5) {
        Log.d(TAG, "setPqValue");
        try {
            return mService.setPqValue(i2, i3, i4, i5);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    public boolean setSwdrLevel(int i2, int i3) {
        Log.d(TAG, "setSwdrLevel");
        try {
            return mService.setSwdrLevel(i2, i3);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    public void setUClearStatus(boolean z2) {
        Log.d(TAG, "setUClearStatus bFlag = " + z2);
        try {
            mService.setUClearStatus(z2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
        }
    }

    public boolean setUltraBlackWhite(UltraBlackWhite ultraBlackWhite) {
        Log.d(TAG, "setUltraBlackWhite");
        try {
            return mService.setUltraBlackWhite(ultraBlackWhite);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    @Deprecated
    public boolean setVideoArc(EnumVideoArcType enumVideoArcType) {
        Log.d(TAG, "setVideoArc(), paras eArcIdx = " + enumVideoArcType);
        return setVideoArcType(enumVideoArcType.ordinal());
    }

    public boolean setVideoArcType(int i2) {
        Log.d(TAG, "setVideoArcType(), paras arcType = " + i2);
        try {
            return mService.setVideoArc(i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    @Deprecated
    public boolean setVideoItem(EnumVideoItem enumVideoItem, int i2) {
        Log.d(TAG, "setVideoItem(), paras eIndex = " + enumVideoItem + ", value = " + i2);
        return setVideoItem(enumVideoItem.ordinal(), i2);
    }

    @Deprecated
    public boolean setVideoItemByInputSource(EnumVideoItem enumVideoItem, int i2, TvOsType.EnumInputSource enumInputSource) {
        Log.d(TAG, "setVideoItem(), paras eIndex = " + enumVideoItem + ", value = " + i2 + ", input = " + enumInputSource);
        return setVideoItemByInputSource(enumVideoItem.ordinal(), i2, enumInputSource.ordinal());
    }

    public void setWindowInvisible() {
        try {
            mService.setWindowInvisible();
        } catch (RemoteException e2) {
            e2.printStackTrace();
        }
    }

    public void setWindowVisible() {
        try {
            mService.setWindowVisible();
        } catch (RemoteException e2) {
            e2.printStackTrace();
        }
    }

    public boolean setxvYCCEnable(boolean z2, int i2) {
        boolean z3;
        Log.d(TAG, "setxvYCCEnable bEn = " + z2 + " eMode = " + i2);
        try {
            z3 = mService.setxvYCCEnable(z2, i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            z3 = false;
        }
        Log.d(TAG, "setxvYCCEnable return = " + z3);
        return z3;
    }

    public boolean turnOffLocalDimmingBacklight(boolean z2) {
        Log.d(TAG, "turnOffLocalDimmingBacklight bOffFlag = " + z2);
        try {
            return mService.turnOffLocalDimmingBacklight(z2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    public boolean unFreezeImage() {
        boolean zUnFreezeImage;
        Log.d(TAG, "unFreezeImage()");
        try {
            zUnFreezeImage = mService.unFreezeImage();
        } catch (RemoteException e2) {
            e2.printStackTrace();
            zUnFreezeImage = false;
        }
        Log.d(TAG, "unFreezeImage() return = " + zUnFreezeImage);
        return zUnFreezeImage;
    }

    public boolean unregisterOnConflictEventListener(OnConflictEventListener onConflictEventListener) {
        synchronized (this.mConflictEventListeners) {
            this.mConflictEventListeners.remove(onConflictEventListener);
            Log.d(TAG, "unregisterOnConflictEventListener size: " + this.mConflictEventListeners.size());
        }
        return true;
    }

    public boolean unregisterOnVideoStatusEventListener(OnVideoStatusEventListener onVideoStatusEventListener) {
        synchronized (this.mVideoStatusEventListeners) {
            this.mVideoStatusEventListeners.remove(onVideoStatusEventListener);
            Log.d(TAG, "unregisterOnVideoStatusEventListener size: " + this.mVideoStatusEventListeners.size());
        }
        return true;
    }

    public int getVideoItem(int i2) {
        int videoItem;
        Log.d(TAG, "getVideoItem(), paras pictureItem = " + i2);
        try {
            videoItem = mService.getVideoItem(i2);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            videoItem = -1;
        }
        Log.d(TAG, "getVideoItem(), return int " + videoItem);
        return videoItem;
    }

    public int getVideoItemByInputSource(int i2, int i3) {
        int videoItemByInputSource;
        Log.d(TAG, "getVideoItemByInputSource(), paras pictureItem = " + i2 + ", inputSrc = " + i3);
        try {
            videoItemByInputSource = mService.getVideoItemByInputSource(i2, i3);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            videoItemByInputSource = -1;
        }
        Log.d(TAG, "getVideoItem(), return int = " + videoItemByInputSource);
        return videoItemByInputSource;
    }

    public boolean setVideoItem(int i2, int i3) {
        Log.d(TAG, "setVideoItem(), paras pictureItem = " + i2 + ", value = " + i3);
        try {
            return mService.setVideoItem(i2, i3);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            return false;
        }
    }

    public boolean setVideoItemByInputSource(int i2, int i3, int i4) {
        boolean videoItemByInputSource;
        Log.d(TAG, "setVideoItemByInputSource(), paras pictureItem = " + i2 + ", value = " + i3 + ", inputSrc = " + i4);
        try {
            videoItemByInputSource = mService.setVideoItemByInputSource(i2, i3, i4);
        } catch (RemoteException e2) {
            e2.printStackTrace();
            videoItemByInputSource = false;
        }
        Log.d(TAG, "setVideoItemByInputSource() return = " + videoItemByInputSource);
        return videoItemByInputSource;
    }
}
