MeiCam SDK For Android
1.0.0
|
Resource package manager, managing resource bundles in video scenarios. More...
Classes | |
interface | AssetPackageManagerCallback |
Resource package management callback interface. More... | |
Public Member Functions | |
NvsAssetPackageManager (boolean isEffectSdk) | |
void | setInternalObject (long internalObject) |
void | setCallbackInterface (AssetPackageManagerCallback callback) |
Sets the package manager callback interface. More... | |
String | getAssetPackageIdFromAssetPackageFilePath (String assetPackageFilePath) |
Gets the ID of the resource package from the file path of the resource package. More... | |
int | getAssetPackageVersionFromAssetPackageFilePath (String assetPackageFilePath) |
Gets the version of the resource package from the file path of the resource package. More... | |
int | installAssetPackage (String assetPackageFilePath, String licenseFilePath, int type, boolean synchronous, StringBuilder assetPackageId) |
Installs resource package. More... | |
int | upgradeAssetPackage (String assetPackageFilePath, String licenseFilePath, int type, boolean synchronous, StringBuilder assetPackageId) |
Upgrades resource package. More... | |
int | uninstallAssetPackage (String assetPackageId, int type) |
Uninstalls resource package. More... | |
int | getAssetPackageStatus (String assetPackageId, int type) |
Gets the version of the resource package from the file path of the resource package. More... | |
int | getAssetPackageVersion (String assetPackageId, int type) |
Gets the version of the resource bundle. More... | |
int | getAssetPackageSupportedAspectRatio (String assetPackageId, int type) |
Gets the supported aspect ratio of the resource package. More... | |
List< String > | getAssetPackageListOfType (int type) |
Gets a list of resource packages of a certain type. More... | |
boolean | isCustomAnimatedSticker (String uuidString) |
Determines if it is a custom sticker. More... | |
boolean | isParticleFX (String uuidString) |
Determines whether it is a particle effect. More... | |
boolean | isThemeContainMusic (String uuidString) |
Check whether a theme package contain music. More... | |
String | getVideoFxAssetPackageDescription (String uuidString) |
Gets the resource description of the VideoFx type. More... | |
Static Public Attributes | |
resource package type | |
static final int | ASSET_PACKAGE_TYPE_VIDEOFX = 0 |
Video effect type. More... | |
static final int | ASSET_PACKAGE_TYPE_VIDEOTRANSITION = 1 |
Video transition type. More... | |
static final int | ASSET_PACKAGE_TYPE_CAPTIONSTYLE = 2 |
Caption style type. More... | |
static final int | ASSET_PACKAGE_TYPE_ANIMATEDSTICKER = 3 |
Animated sticker type. More... | |
static final int | ASSET_PACKAGE_TYPE_THEME = 4 |
Theme type. More... | |
static final int | ASSET_PACKAGE_TYPE_CAPTURESCENE = 5 |
Capture scene type. More... | |
static final int | ASSET_PACKAGE_TYPE_ARSCENE = 6 |
AR scene type. More... | |
resource package state | |
static final int | ASSET_PACKAGE_STATUS_NOTINSTALLED = 0 |
Uninstalled state. More... | |
static final int | ASSET_PACKAGE_STATUS_INSTALLING = 1 |
Installing status. More... | |
static final int | ASSET_PACKAGE_STATUS_READY = 2 |
Preparation status. More... | |
static final int | ASSET_PACKAGE_STATUS_UPGRADING = 3 |
Upgrading status. More... | |
Resource package management error type | |
static final int | ASSET_PACKAGE_MANAGER_ERROR_NO_ERROR = 0 |
Installed successfully. More... | |
static final int | ASSET_PACKAGE_MANAGER_ERROR_NAME = 1 |
Wrong name. More... | |
static final int | ASSET_PACKAGE_MANAGER_ERROR_ALREADY_INSTALLED = 2 |
Already installed. More... | |
static final int | ASSET_PACKAGE_MANAGER_ERROR_WORKING_INPROGRESS = 3 |
Installation or upgrade in progress. More... | |
static final int | ASSET_PACKAGE_MANAGER_ERROR_NOT_INSTALLED = 4 |
Not installed yet. More... | |
static final int | ASSET_PACKAGE_MANAGER_ERROR_IMPROPER_STATUS = 5 |
Incorrect status. More... | |
static final int | ASSET_PACKAGE_MANAGER_ERROR_DECOMPRESSION = 6 |
Decompression error. More... | |
static final int | ASSET_PACKAGE_MANAGER_ERROR_INVALID_PACKAGE = 7 |
Invalid package. More... | |
static final int | ASSET_PACKAGE_MANAGER_ERROR_ASSET_TYPE = 8 |
Resource type error. More... | |
static final int | ASSET_PACKAGE_MANAGER_ERROR_PERMISSION = 9 |
License error. More... | |
static final int | ASSET_PACKAGE_MANAGER_ERROR_META_CONTENT = 10 |
Meta content error. More... | |
static final int | ASSET_PACKAGE_MANAGER_ERROR_SDK_VERSION = 11 |
SDK version error. More... | |
static final int | ASSET_PACKAGE_MANAGER_ERROR_UPGRADE_VERSION = 12 |
Upgrade version error. More... | |
static final int | ASSET_PACKAGE_MANAGER_ERROR_IO = 13 |
Input and output error. More... | |
static final int | ASSET_PACKAGE_MANAGER_ERROR_RESOURCE = 14 |
Resource error. More... | |
Aspect ratio supported by the resource package | |
static final int | ASSET_PACKAGE_ASPECT_RATIO_16v9 = 1 |
static final int | ASSET_PACKAGE_ASPECT_RATIO_1v1 = 2 |
static final int | ASSET_PACKAGE_ASPECT_RATIO_9v16 = 4 |
static final int | ASSET_PACKAGE_ASPECT_RATIO_4v3 = 8 |
static final int | ASSET_PACKAGE_ASPECT_RATIO_3v4 = 16 |
static final int | ASSET_PACKAGE_ASPECT_RATIO_18v9 = 32 |
static final int | ASSET_PACKAGE_ASPECT_RATIO_9v18 = 64 |
Resource package manager, managing resource bundles in video scenarios.
In the development of the SDK, the resource package manager unifies the various special resource packages including subtitles, themes, animation stickers, etc. for installation, upgrade, and uninstallation. When installing, upgrading, and uninstalling, there will be a corresponding error type for errors to be quickly located and resolved.
|
inline |
|
inline |
Gets the ID of the resource package from the file path of the resource package.
assetPackageFilePath | Resource file path |
|
inline |
Gets a list of resource packages of a certain type.
type | Resource package type. Note: The parameter to be entered is a value of static int type, and is prefixed with ASSET_PACKAGE_TYPE. Please refer to resource package type. |
|
inline |
Gets the version of the resource package from the file path of the resource package.
assetPackageId | Resource package ID to be checked. |
type | The type of the resource package to be queried. Note: The parameter to be entered is a value of static int type and is prefixed with ASSET_PACKAGE_TYPE. Please refer to resource package type. |
Note: The return value is a static int value prefixed with ASSET_PACKAGE_STATUS. 0, namely ASSET_PACKAGE_STATUS_NOTINSTALLED, indicates that the package has not been installed. Please refer to resource package status.
|
inline |
Gets the supported aspect ratio of the resource package.
assetPackageId | Resource package ID |
type | Resource package type. Note: The parameter to be entered is a value of static int type, and is prefixed with ASSET_PACKAGE_TYPE. Please refer to resource package type. |
|
inline |
Gets the version of the resource bundle.
assetPackageId | Resource package ID |
type | Resource package type. Note: The parameter to be entered is a value of static int type, and is prefixed with ASSET_PACKAGE_TYPE. Please refer to resource package type. |
|
inline |
Gets the version of the resource package from the file path of the resource package.
assetPackageFilePath | Resource file path |
|
inline |
Gets the resource description of the VideoFx type.
uuidString | special effect uuid |
|
inline |
Installs resource package.
assetPackageFilePath | File path of the resource package to be installed. |
licenseFilePath | Authorization file path of the resource package to be installed. |
type | The type of resource package to be installed. Note: The parameter to be entered is the value of the static int attribute prefixed with ASSET_PACKAGE_TYPE. Please refer to resource package type |
synchronous | Whether to install synchronously. A value of true means the installation process will block the current thread until it succeeds or fails, false means that the result of the installation process is asynchronously notified by the delegate (It can also be notified by the current thread). |
assetPackageId | Output parameter, which returns the resource package ID. |
Note: Note: The return value is of the static int type, and is prefixed with ASSET_PACKAGE_MANAGER_ERROR. "ASSET_PACKAGE_MANAGER_ERROR_NO_ERROR" indicates a successful installation (this may only be returned if the installation is synchronized), while any other value suggests an error. Please refer to Resource Package Management Error Type.
|
inline |
Determines if it is a custom sticker.
uuidString | sticker uuid |
|
inline |
Determines whether it is a particle effect.
uuidString | particle effect uuid |
|
inline |
Check whether a theme package contain music.
uuidString | theme package uuid |
|
inline |
Sets the package manager callback interface.
callback | Package manager callback interface |
|
inline |
|
inline |
Uninstalls resource package.
assetPackageId | ID of the resource package to be uninstalled |
type | The type of resource package to be uninstalled. Note: The parameter to be entered is a value of static int type and is prefixed with ASSET_PACKAGE_TYPE. Please refer to resource package type |
Note: The return value is a value of static int type and is prefixed with ASSET_PACKAGE_MANAGER_ERROR. If ASSET_PACKAGE_MANAGER_ERROR_NO_ERROR is returned, the uninstallation is successful, otherwise the uninstallation fails. Please refer to Resource Package Management Error Type.
|
inline |
Upgrades resource package.
assetPackageFilePath | File path of the resource package to be upgraded |
licenseFilePath | Authorization file path of the resource bundle to be upgraded |
type | The type of resource bundle to be upgraded. Note: The parameter to be entered is a value of static int attribute prefixed with ASSET_PACKAGE_TYPE. Please refer to Resource Type. |
synchronous | Whether to upgrade synchronously. If the value is true, the upgrade process will block the current thread until it succeeds or fails. If it is false, the result of the upgrade process is asynchronously notified by the delegate (It can also be notified by the current thread). |
assetPackageId | Output parameter, which returns the resource package ID |
Note: The return value is of static int type and is prefixed with ASSET_PACKAGE_MANAGER_ERROR. "ASSET_PACKAGE_MANAGER_ERROR_NO_ERROR:" indicates a successful upgrade (This may only be returned if the upgrade is synchronized), while any other value suggests a upgrade error. Please refer to Resource Package Management Error Type.
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
Already installed.
|
static |
Resource type error.
|
static |
Decompression error.
|
static |
Incorrect status.
|
static |
Invalid package.
|
static |
Input and output error.
|
static |
Meta content error.
|
static |
Wrong name.
|
static |
Installed successfully.
|
static |
Not installed yet.
|
static |
License error.
|
static |
Resource error.
|
static |
SDK version error.
|
static |
Upgrade version error.
|
static |
Installation or upgrade in progress.
|
static |
Installing status.
|
static |
Uninstalled state.
|
static |
Preparation status.
|
static |
Upgrading status.
|
static |
Animated sticker type.
|
static |
AR scene type.
|
static |
Caption style type.
|
static |
Capture scene type.
|
static |
Theme type.
|
static |
Video effect type.
|
static |
Video transition type.