MeiCam SDK For Android  3.10.0
Public Member Functions | List of all members
com.meicam.sdk.NvsCaptureAnimatedSticker Class Reference

Timeline animated sticker class. More...

Inheritance diagram for com.meicam.sdk.NvsCaptureAnimatedSticker:
com.meicam.sdk.NvsAnimatedSticker com.meicam.sdk.NvsFx com.meicam.sdk.NvsObject

Public Member Functions

long getOffsetPoint ()
 Get animated sticker's offset time. More...
 
long getDuration ()
 Get animated sticker's duration. More...
 
long changeOffsetPoint (long newOffset)
 Change the offset time of the animated sticker. The offset time is the capture time relative to the time when the animation sticker was added. More...
 
long changeDuration (long newOutPoint)
 Change the duration of the animated sticker. More...
 
void setStartTime (long startTime)
 Reset start time of the animated sticker. More...
 
void resetStartTime ()
 Reset start time of the animated sticker. More...
 
- Public Member Functions inherited from com.meicam.sdk.NvsAnimatedSticker
String getAnimatedStickerPackageId ()
 Get animated sticker's package ID. More...
 
void setScale (float scale)
 Set the scale value of the animated sticker. The scale value set by this function do not stack. More...
 
float getScale ()
 Get the scale value of the animated sticker. More...
 
void setHorizontalFlip (boolean flip)
 Set the horizontal flip of the animated sticker. More...
 
boolean getHorizontalFlip ()
 Get the horizontal flip state of the animated sticker. More...
 
void setVerticalFlip (boolean flip)
 Set the vertical flip of the animated sticker. More...
 
boolean getVerticalFlip ()
 Get the vertical flip state of the animated sticker. More...
 
void setRotationZ (float angle)
 Set the angle at which the animation sticker rotates clockwise along the Z-axis, which is perpendicular to the screen.The rotation Angle set by this function does not stack. More...
 
float getRotationZ ()
 Get the angle at which the animation sticker rotates clockwise along the Z-axis, which is perpendicular to the screen. More...
 
void setTranslation (PointF translation)
 Sets the translation position of the animated sticker in the timeline coordinate system.The translation coordinate set by this function do not stack.please refer to TimeLine and View Coordinate. More...
 
PointF getTranslation ()
 Get the translation position of the animated sticker in the timeline coordinate system. More...
 
void translateAnimatedSticker (PointF translationOffset)
 Tanslate animated sticker in the timeline coordinate system.The translation coordinates set by this function are stackable. More...
 
void scaleAnimatedSticker (float scaleFactor, PointF anchor)
 Scale animation sticker with the anchor point as the center. The scaling value set by this function is stackable. More...
 
void rotateAnimatedSticker (float angle, PointF anchor)
 Rotate the animation sticker around the anchor point. The rotation angle set by this function is stackable. More...
 
void rotateAnimatedSticker (float angle)
 Rotate the animation sticker with the center point of the animation sticker as the anchor point.The rotation angle set by this function is stackable. More...
 
RectF getOriginalBoundingRect ()
 Get the original bounding of the animated sticker in the timeline coordinate system.please refer to TimeLine and View Coordinate. More...
 
List< PointF > getBoundingRectangleVertices ()
 Get the vertex positions of the animated sticker's original bounding in the timeline coordinate system.please refer to TimeLine and View Coordinate. More...
 
boolean isPanoramic ()
 Determine whether the animated sticker is a panorama animated sticker or not. More...
 
void setCenterPolarAngle (float centerPolarAngle)
 Set the polar angle of the center point on the animated sticker. Only valid for panorama animated stickers. More...
 
float getCenterPolarAngle ()
 Get the polar angle of the center point of the animated sticker. It is only valid for panorama animated stickers. More...
 
void setCenterAzimuthAngle (float centerAzimuthAngle)
 Set the azimuth of the center point on the animated sticker. It is only valid for panorama animated stickers. More...
 
float getCenterAzimuthAngle ()
 Get the azimuth of the center point of the animated sticker. It is only valid for panorama animated stickers. More...
 
void setPolarAngleRange (float polarAngleRange)
 Set animated sticker's field angle, which is coplanar with the polar angle. It is only valid for panorama animated stickers. More...
 
float getPolarAngleRange ()
 Get animated sticker's field angle, which is coplanar with the polar angle. It is only valid for panorama animated stickers. More...
 
float getOrthoAngleRange ()
 Get the animated sticker’s field angle which is perpendicular to the polar angle. It is only valid for panorama animated stickers. More...
 
void setZValue (float value)
 Set the sticker Z value.The higher the Z value, the higher the sticker is. More...
 
float getZValue ()
 Get the sticker Z value. More...
 
boolean hasAudio ()
 Check whether the sticker contains audio. More...
 
void setVolumeGain (float leftVolumeGain, float rightVolumeGain)
 Set the sticker volume. More...
 
NvsVolume getVolumeGain ()
 Get volume information. More...
 
long getDefaultDuration ()
 Get the default duration of the sticker. More...
 
void setOpacity (float opacity)
 Set the sticker opacity,value range [0, 1]. More...
 
float getOpacity ()
 Get the sticker opacity. More...
 
void setCurrentKeyFrameTime (long time)
 Set the sticker's Key frame time. More...
 
boolean setControlPoint (String fxParam, NvsControlPointPair controlPointPair)
 Set the sticker's control point pair. More...
 
NvsControlPointPair getControlPoint (String fxParam)
 Get the sticker's key frame control point pair. More...
 
String getAnimatedStickerPeriodAnimationPackageId ()
 Gets the animated sticker period animation style package ID. More...
 
String getAnimatedStickerInAnimationPackageId ()
 Gets the animated sticker in-animation style package ID. More...
 
String getAnimatedStickerOutAnimationPackageId ()
 Gets the animated sticker out-animation style package ID. More...
 
boolean applyAnimatedStickerPeriodAnimation (String animatedStickerPeriodAnimationPackageId)
 Applys animated sticker loop-animation style. More...
 
boolean applyAnimatedStickerInAnimation (String animatedStickerInAnimationPackageId)
 Applys animated sticker in-animation style. Notes:please set loop-Animation to null before you set in-animation, otherwise it will NOT works. More...
 
boolean applyAnimatedStickerOutAnimation (String animatedStickerOutAnimationPackageId)
 Applys animated sticker out-animation style.Notes:please set loop-Animation to null before you set out-animation, otherwise it will NOT works. More...
 
void setAnimatedStickerAnimationPeriod (int periodInMS)
 Set animated sticker Animation Period. More...
 
int getAnimatedStickerAnimationPeriod ()
 Get animated sticker Animation Period. More...
 
void setAnimatedStickerInAnimationDuration (int inAnimationDurationInMS)
 Set animated sticker in-animation duration. More...
 
int getAnimatedStickerInAnimationDuration ()
 Get anmiated sticker in-animation duration. More...
 
void setAnimatedStickerOutAnimationDuration (int outAnimationDurationInMS)
 Set animated sticker out-animation duration. More...
 
int getAnimatedStickerOutAnimationDuration ()
 Get animated sticker out-animation duration. More...
 
void setSeperatedScaleX (float scaleX)
 Set the split horizontal scaling of animated stickers. More...
 
float getSeperatedScaleX ()
 Get the split horizontal scaling of animated stickers. More...
 
void setSeperatedScaleY (float scaleY)
 Set the split vertical scaling of animated stickers. More...
 
float getSeperatedScaleY ()
 Get the split vertical scaling of animated stickers. More...
 
void enableSeparateProgressMode (boolean enable)
 Set enable the separate effect settings from progress mode. More...
 
boolean isSeparateProgressModeEnabled ()
 Get whether enable the separate effect settings from progress mode. More...
 
- Public Member Functions inherited from com.meicam.sdk.NvsFx
NvsFxDescription getDescription ()
 Get decription of Fx. More...
 
void setIntVal (String fxParam, int val)
 Set the integer parameter of NvsFx. More...
 
int getIntVal (String fxParam)
 Get the integer parameter of NvsFx. More...
 
void setIntValAtTime (String fxParam, int val, long time)
 Set the NvsFx's integer parameter at a specified time point. More...
 
int getIntValAtTime (String fxParam, long time)
 Get the NvsFx's integer parameter at a specified time point. More...
 
void setFloatVal (String fxParam, double val)
 Set the float parameter of NvsFx. More...
 
double getFloatVal (String fxParam)
 Get the float parameter of NvsFx. More...
 
void setFloatValAtTime (String fxParam, double val, long time)
 Set the NvsFx's float parameter at a specified time point. More...
 
double getFloatValAtTime (String fxParam, long time)
 Get the NvsFx's float parameter at a specified time point. More...
 
void setBooleanVal (String fxParam, boolean val)
 Set the boolean parameter of NvsFx. More...
 
boolean getBooleanVal (String fxParam)
 Get the boolean parameter of NvsFx. More...
 
void setBooleanValAtTime (String fxParam, boolean val, long time)
 Set the NvsFx’s boolean parameter at a specified time point. More...
 
boolean getBooleanValAtTime (String fxParam, long time)
 Get the NvsFx's boolean parameter at a specified time point. More...
 
void setStringVal (String fxParam, String val)
 Set the string parameter of NvsFx. More...
 
String getStringVal (String fxParam)
 Get the string parameter of NvsFx. More...
 
void setStringValAtTime (String fxParam, String val, long time)
 Set the NvsFx's string parameter at a specified time point. More...
 
String getStringValAtTime (String fxParam, long time, int flags)
 Get the NvsFx's string parameter at a specified time point. More...
 
void setColorVal (String fxParam, NvsColor val)
 Set the color parameter of NvsFx. More...
 
NvsColor getColorVal (String fxParam)
 Get the color parameter of NvsFx. More...
 
void setColorValAtTime (String fxParam, NvsColor val, long time)
 Set the NvsFx's color parameter at a specified time point. More...
 
NvsColor getColorValAtTime (String fxParam, long time)
 Get the NvsFx's color parameter at a specified time point. More...
 
void setPosition2DVal (String fxParam, NvsPosition2D val)
 Set the two dimentional coordinates parameter of NvsFx. More...
 
NvsPosition2D getPosition2DVal (String fxParam)
 Get the two dimentional coordinates parameter of NvsFx. More...
 
void setPosition2DValAtTime (String fxParam, NvsPosition2D val, long time)
 Set the NvsFx's two dimentional coordinates parameter at a specified time point. More...
 
NvsPosition2D getPosition2DValAtTime (String fxParam, long time)
 Get the NvsFx's two dimentional coordinates parameter at a specified time point. More...
 
void setPosition3DVal (String fxParam, NvsPosition3D val)
 Set the three dimentional coordinates parameter of NvsFx. More...
 
NvsPosition3D getPosition3DVal (String fxParam)
 Get the three dimentional coordinates parameter of NvsFx. More...
 
void setPosition3DValAtTime (String fxParam, NvsPosition3D val, long time)
 Set the NvsFx's three dimentional coordinates parameter at a specified time point. More...
 
NvsPosition3D getPosition3DValAtTime (String fxParam, long time)
 Get the NvsFx's three dimentional coordinates parameter at a specified time point. More...
 
void setMenuVal (String fxParam, String val)
 Set the menu parameter of NvsFx. More...
 
String getMenuVal (String fxParam)
 Get the menu parameter of NvsFx. More...
 
void setMenuValAtTime (String fxParam, String val, long time)
 Set the NvsFx's menu parameter at a specified time point. More...
 
String getMenuValAtTime (String fxParam, long time)
 Get the NvsFx menu parameter at a specified time point. More...
 
void setArbDataVal (String fxParam, NvsArbitraryData val)
 Set custom data parameter value. More...
 
NvsArbitraryData getArbDataVal (String fxParam)
 Get custom data parameter value. More...
 
void setArbDataValAtTime (String fxParam, NvsArbitraryData val, long time)
 Sets custom data parameter value. More...
 
NvsArbitraryData getArbDataValAtTime (String fxParam, NvsArbitraryData val, long time)
 Get custom data parameter value at a specified time point. More...
 
boolean removeKeyframeAtTime (String fxParam, long time)
 Remove key frame at a specified time point from key frame list. More...
 
boolean removeAllKeyframe (String fxParam)
 Remove all key frames from key frame list. More...
 
boolean hasKeyframeList (String fxParam)
 Check whether the parameter has key frame list or not. More...
 
long findKeyframeTime (String fxParam, long time, int flags)
 Get key frame at a specified time point. More...
 
boolean setKeyFrameControlPoint (String fxParam, long time, NvsControlPointPair controlPointPair)
 Set key frame control point pair. More...
 
NvsControlPointPair getKeyFrameControlPoint (String fxParam, long time)
 Get key frame control point pair. More...
 
boolean setKeyFrameControlPointMode (String fxParam, long time, NvsControlPointModePair controlPointModePair)
 Set key frame control point mode pair. More...
 
NvsControlPointModePair getKeyFrameControlPointMode (String fxParam, long time)
 Get key frame control point mode pair. More...
 
void setFilterIntensity (float intensity)
 Set the intensity of the filter. More...
 
float getFilterIntensity ()
 Get the intensity of the filter. More...
 
void setFilterMask (boolean useMask)
 Set the mask of the filter. More...
 
boolean getFilterMask ()
 Get the usage of the filter's mask. More...
 
void setRegional (boolean isRegional)
 Set whether the filter is regional. More...
 
boolean getRegional ()
 Get whether the filter is regional. More...
 
void setIgnoreBackground (boolean isIgnoreBackground)
 Set whether the regional filter ignores background. More...
 
boolean getIgnoreBackground ()
 Get whether the regional filter ignores background. More...
 
void setInverseRegion (boolean isInverseRegion)
 Set whether the regional filter inverses region. More...
 
boolean getInverseRegion ()
 Get whether the regional filter inverses region. More...
 
void setRegion (float[] region)
 Set the region of this regional filter. More...
 
float[] getRegion ()
 Get the region of this regional filter. More...
 
void setRegionInfo (NvsMaskRegionInfo info)
 Set the mask region informations of the regional filter. More...
 
NvsMaskRegionInfo getRegionInfo ()
 Get the mask region informations of the regional filter. More...
 
void setRegionInfoAtTime (NvsMaskRegionInfo info, long time)
 Set the regional filter's mask region informations at a specified time point. More...
 
NvsMaskRegionInfo getRegionInfoAtTime (long time)
 Get the the regional filter's mask region informations at a specified time. More...
 
void setRegionalFeatherWidth (float featherWidth)
 Set the feather width of the regional filter. More...
 
float getRegionalFeatherWidth ()
 Get the feather width of the regional filter. More...
 
void setRegionalFeatherWidthAtTime (float featherWidth, long time)
 Set the regional filter's feather width at a specified time point. More...
 
float getRegionalFeatherWidthAtTime (long time)
 Get the regional filter's feather width at a specified time point. More...
 
void setRegionCoordinateSystemType (int type)
 Set the coordinate system of the region. More...
 
int getRegionCoordinateSystemType ()
 Get the coordinate system type of the region. More...
 
NvsParticleSystemContext getParticleSystemContext ()
 Get the particle effect context object.Please refer to NvsParticleSystemContext. More...
 
NvsARFaceContext getARFaceContext ()
 Get face effect context object.Please refer to NvsARFaceContext. More...
 
NvsPaintingEffectContext getPaintingEffectContext ()
 Get the particle effect context object.Please refer to NvsPaintingEffectContext. More...
 
NvsARSceneManipulate getARSceneManipulate ()
 Get the AR scene operation object.Please refer to NvsARSceneManipulate. More...
 
void setExprVar (String varName, double varValue)
 Set the value of the defined parameter in the expression. More...
 
double getExprVar (String varName)
 Get the value of the defined parameter in the expression. More...
 
void setExprStringVar (String varName, String varValue)
 Set the value of the defined parameter in the expression. More...
 
String getExprStringVar (String varName)
 Get the value of the defined parameter in the expression. More...
 
void setExprObjectVar (String varName, Object varValue)
 Set the value of the defined parameter in the expression. More...
 
Object getExprObjectVar (String varName)
 Get the value of the defined parameter in the expression. More...
 
void clearExprVar (String varName)
 Clear the value of the defined parameter in the expression and set it to the default value of 0. More...
 
void clearExprVarCtx ()
 Clear all parameter values defined in the expression and set them to the default value of 0. More...
 
- Public Member Functions inherited from com.meicam.sdk.NvsObject
void setAttachment (String key, Object value)
 Adds additional data to the NvsObject object to identify the NvsObject object or for other purpose. More...
 
void setTemplateAttachment (String key, String value)
 Adds additional template data to the NvsObject object to identify the NvsObject template object. More...
 
Object getAttachment (String key)
 Gets an attachment to NvsObject. More...
 
String getTemplateAttachment (String key)
 Gets an template attachment to NvsObject. More...
 

Additional Inherited Members

- Static Public Attributes inherited from com.meicam.sdk.NvsFx
static final int KEY_FRAME_FIND_MODE_INPUT_TIME_BEFORE = 1
 find key frame before current time More...
 
static final int KEY_FRAME_FIND_MODE_INPUT_TIME_AFTER = 2
 
static final int REGION_COORDINATE_SYSTEM_TYPE_NDC = 0
 NDC coordinate system. More...
 
static final int REGION_COORDINATE_SYSTEM_TYPE_TIMELINE = 1
 
static final int FACE_WARP_EFFECT_STRATEGY_CUSTOM = 0x7FFFFFFF
 
- Static Public Attributes inherited from com.meicam.sdk.NvsObject
static final String TEMPLATE_KEY_REPLACE_ID = "MSTemplate-ReplaceId"
 
static final String TEMPLATE_KEY_FOOTAGE_CAN_REPLACE = "MSTemplate-FootageCanReplace"
 
static final String TEMPLATE_KEY_FOOTAGE_ID = "MSTemplate-FootageId"
 
static final String TEMPLATE_KEY_FOOTAGE_NAME = "MSTemplate-FootageName"
 
static final String TEMPLATE_KEY_FOOTAGE_M3U8_NAME = "MSTemplate-FootageM3U8Name"
 
static final String TEMPLATE_KEY_FOOTAGE_TAGS = "MSTemplate-FootageTags"
 
static final String TEMPLATE_KEY_FOOTAGE_TYPE = "MSTemplate-FootageType"
 
static final String TEMPLATE_KEY_FOOTAGE_NEED_REVERSE = "MSTemplate-FootageNeedReverse"
 
static final String TEMPLATE_KEY_CLIP_RAW_WIDTH = "MSTemplate-ClipRawWidth"
 
static final String TEMPLATE_KEY_CLIP_RAW_HEIGHT = "MSTemplate-ClipRawHeight"
 
static final String TEMPLATE_KEY_VOLUME_TYPE = "MSTemplate-VolumeType"
 
static final String TEMPLATE_KEY_FX_GROUP = "MSTemplate-FxGroup"
 
static final String TEMPLATE_KEY_BEST_SEEK_TIME = "MSTemplate-BestSeekTime"
 
static final String TEMPLATE_KEY_MASK_TYPE = "MSTemplate-MaskType"
 
static final String TEMPLATE_VALUE_MASK_TYPE_LINE = "MSTemplate-MaskType-Line"
 
static final String TEMPLATE_VALUE_MASK_TYPE_MIRROR = "MSTemplate-MaskType-Mirror"
 
static final String TEMPLATE_VALUE_MASK_TYPE_CIRCLE = "MSTemplate-MaskType-Circle"
 
static final String TEMPLATE_VALUE_MASK_TYPE_RECT = "MSTemplate-MaskType-Rect"
 
static final String TEMPLATE_VALUE_MASK_TYPE_HEART = "MSTemplate-MaskType-Heart"
 
static final String TEMPLATE_VALUE_MASK_TYPE_STAR = "MSTemplate-MaskType-Star"
 
static final String TEMPLATE_KEY_TRANS_TYPE_CUT = "MSTemplate-TransType-Cut"
 
static final String TEMPLATE_KEY_CURVE_SPEED_TYPE = "MSTemplate-CurveSpeedType"
 
static final String TEMPLATE_VALUE_CURVE_SPEED_TYPE_CUSTOM = "MSTemplate-CurveSpeedType-Custom"
 
static final String TEMPLATE_VALUE_CURVE_SPEED_TYPE_MONTAGE = "MSTemplate-CurveSpeedType-Montage"
 
static final String TEMPLATE_VALUE_CURVE_SPEED_TYPE_HERO = "MSTemplate-CurveSpeedType-Hero"
 
static final String TEMPLATE_VALUE_CURVE_SPEED_TYPE_BULLET = "MSTemplate-CurveSpeedType-bullet"
 
static final String TEMPLATE_VALUE_CURVE_SPEED_TYPE_PLUS = "MSTemplate-CurveSpeedType-Plus"
 
static final String TEMPLATE_VALUE_CURVE_SPEED_TYPE_IN = "MSTemplate-CurveSpeedType-In"
 
static final String TEMPLATE_VALUE_CURVE_SPEED_TYPE_OUT = "MSTemplate-CurveSpeedType-Out"
 
- Protected Member Functions inherited from com.meicam.sdk.NvsObject
void setInternalObject (long internalObject)
 
long getInternalObject ()
 
- Protected Attributes inherited from com.meicam.sdk.NvsObject
long m_internalObject = 0
 

Detailed Description

Timeline animated sticker class.

Users can add and remove animated stickers for Catpure, the start time is the current shooting time and the given offset time to start loading the animation sticker. The end time is the sum of time position, offset time and duration.
Note: The offset-point and duration units of the animated sticker are both in microseconds.
Note1: The default start time of the animated sticker is capture time that was added, the datault start time is zero if it was added before StartCapturePreview called

Warning
In the NvsCaptureAnimatedSticker class, all public APIs are used in the UI thread! ! !
Since
2.21.0

Member Function Documentation

◆ changeDuration()

long com.meicam.sdk.NvsCaptureAnimatedSticker.changeDuration ( long  newOutPoint)
inline

Change the duration of the animated sticker.

Parameters
newOutPointThe expected duration of the animated sticker(in microseconds).
Returns
Return the duraiton of the animated sticker(in microseconds).

◆ changeOffsetPoint()

long com.meicam.sdk.NvsCaptureAnimatedSticker.changeOffsetPoint ( long  newOffset)
inline

Change the offset time of the animated sticker. The offset time is the capture time relative to the time when the animation sticker was added.

Parameters
newInPointThe new offset time of the animated sticker(in microseconds).
Returns
Return the offset time of the animated sticker(in microseconds).
See also
changeDuration
getOffsetPoint

◆ getDuration()

long com.meicam.sdk.NvsCaptureAnimatedSticker.getDuration ( )
inline

Get animated sticker's duration.

Returns
Return the duration of the animated sticker (in microseconds).
See also
getOffsetPoint
changeDuration

◆ getOffsetPoint()

long com.meicam.sdk.NvsCaptureAnimatedSticker.getOffsetPoint ( )
inline

Get animated sticker's offset time.

Returns
Return the offset of the animated sticker(in microseconds).
See also
getDuration
changeOffsetPoint

◆ resetStartTime()

void com.meicam.sdk.NvsCaptureAnimatedSticker.resetStartTime ( )
inline

Reset start time of the animated sticker.

◆ setStartTime()

void com.meicam.sdk.NvsCaptureAnimatedSticker.setStartTime ( long  startTime)
inline

Reset start time of the animated sticker.

Since
3.4.0

The documentation for this class was generated from the following file: