public class NativeAdaptiveUtil
extends AbstractNativeLoader
Constructor and Description |
---|
NativeAdaptiveUtil() |
Modifier and Type | Method and Description |
---|---|
static void |
decoderAdaptiveList(java.lang.String[] models,
int[] versions)
Adds a model to the whitelist.
|
static void |
disableHardDecoderAdaptiveList(java.lang.String[] models,
int[] versions)
Adds a model to the blacklist.
|
static void |
encoderAdaptiveList(java.lang.String[] models,
int[] versions)
Adds a model to the blacklist.
|
static boolean |
isDeviceDecoderEnable()
Gets whether a device is in the whitelist.
|
static void |
setFastEncode(boolean isFaster)
Deprecated.
It is not recommended to call this method.
|
static void |
setHWDecoderEnable(boolean hwDecoderEnable)
Enables or disables hardware decoding.
|
static void |
setHWEncoderEnable(boolean hwEncoderEnable)
Enables or disables hardware encoding.
|
public static void decoderAdaptiveList(java.lang.String[] models, int[] versions)
models
- The model list. Build#MODEL
versions
- The OS version list. Build.VERSION#SDK_INT
Enter 0 if there is no need to match models with OS versions.setHWDecoderEnable(boolean)
public static void disableHardDecoderAdaptiveList(java.lang.String[] models, int[] versions)
models
- The model list. Build#MODEL
versions
- The OS version list. Build.VERSION#SDK_INT
Enter 0 if there is no need to match models with OS versions.setHWDecoderEnable(boolean)
public static void setHWDecoderEnable(boolean hwDecoderEnable)
hwDecoderEnable
- true indicates enable hardware decoding. false indicates disable hardware decoding.decoderAdaptiveList(String[], int[])
public static void encoderAdaptiveList(java.lang.String[] models, int[] versions)
models
- The model list. Build#MODEL
versions
- The OS version list. Build.VERSION#SDK_INT
Enter 0 if there is no need to match models with OS versions.public static void setHWEncoderEnable(boolean hwEncoderEnable)
hwEncoderEnable
- true indicates enable hardware encoding. false indicates disable hardware encoding.encoderAdaptiveList(String[], int[])
public static boolean isDeviceDecoderEnable()
public static void setFastEncode(boolean isFaster)
isFaster
-