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

compound caption. More...

Inheritance diagram for com.meicam.sdk.NvsCompoundCaption:
com.meicam.sdk.NvsFx com.meicam.sdk.NvsObject com.meicam.sdk.NvsCaptureCompoundCaption com.meicam.sdk.NvsClipCompoundCaption com.meicam.sdk.NvsTimelineCompoundCaption com.meicam.sdk.NvsTrackCompoundCaption

Public Member Functions

int getCaptionCount ()
 Gets number of sub-cpations in this compound caption. More...
 
void setText (int captionIndex, String text)
 Sets caption text. More...
 
String getText (int captionIndex)
 Get caption text. More...
 
void setFontFamily (int captionIndex, String family)
 Sets caption font family. More...
 
String getFontFamily (int captionIndex)
 Get the name of caption font. More...
 
void setTextColor (int captionIndex, NvsColor textColor)
 Sets caption text color. More...
 
NvsColor getTextColor (int captionIndex)
 Gets the color value of the caption. More...
 
void setCaptionTranslation (PointF translation)
 Sets the amount of caption translation. More...
 
PointF getCaptionTranslation ()
 Gets the amount of caption translation. More...
 
void translateCaption (PointF translationOffset)
 Translate caption. More...
 
void setAnchorPoint (PointF anchor)
 Sets caption anchor. More...
 
PointF getAnchorPoint ()
 Gets caption anchor. More...
 
void setScaleX (float scale)
 Sets horizontal scaling factor for caption. More...
 
float getScaleX ()
 Gets caption horizontal scaling factor. More...
 
void setScaleY (float scale)
 Sets vertical scaling factor for captions. More...
 
float getScaleY ()
 Gets caption vertical scaling factor. More...
 
void scaleCaption (float scaleFactor, PointF anchor)
 Zooms caption. More...
 
void setRotationZ (float angle)
 Sets the rotation angle for the caption. More...
 
float getRotationZ ()
 Gets caption rotation angle. More...
 
void rotateCaption (float angle, PointF anchor)
 Rotates captions. More...
 
void rotateCaptionAroundCenter (float angle, int boundingType)
 Rotates caption around center of the bounding. More...
 
List< PointF > getCaptionBoundingVertices (int captionIndex, int boundingType)
 Gets the transformed vertices position of the original caption bounding. More...
 
boolean isFrameCaption (int captionIndex)
 Determine if the subtitle is a border subtitle. More...
 
List< PointF > getCompoundBoundingVertices (int boundingType)
 Gets the transformed vertices position of the original compound caption bounding. More...
 
void setZValue (float value)
 Sets caption Z value. More...
 
float getZValue ()
 Gets caption Z value. More...
 
void setOpacity (float opacity)
 Set the caption opacity. More...
 
float getOpacity ()
 Get the caption opacity. More...
 
String getCaptionStylePackageId ()
 Gets the caption style package ID. More...
 
void setDrawOutline (boolean drawOutline, int captionIndex)
 Sets caption stroke. More...
 
boolean getDrawOutline (int captionIndex)
 Gets the caption stroke status. More...
 
void setOutlineColor (NvsColor outlineColor, int captionIndex)
 Sets the color of the caption stroke. More...
 
NvsColor getOutlineColor (int captionIndex)
 Gets the color value of the current caption stroke. More...
 
void setOutlineWidth (float outlineWidth, int captionIndex)
 Sets the width of the caption stroke. More...
 
float getOutlineWidth (int captionIndex)
 Gets the width of the current caption stroke. More...
 
void setBackgroundColor (NvsColor backgroundColor, int captionIndex)
 Set text background color. More...
 
NvsColor getBackgroundColor (int captionIndex)
 Get the current text background color value. More...
 
void setCurrentKeyFrameTime (long time)
 Set the compound caption KeyFrameTime. More...
 
boolean setControlPoint (String fxParam, NvsControlPointPair controlPointPair)
 Set the caption's control point pair. More...
 
NvsControlPointPair getControlPoint (String fxParam)
 Get the caption's key frame control point pair. 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...
 
void setDisableElegantTextHeight (int captionIndex, boolean disableElegantTextHeight)
 Due to historical factors, Meishe SDK uses the elegant text height feature in the horizontal text layout of the Android platform, which will cause the horizontal layout of the Android platform to be different from the line spacing of other platforms. Setting this property will disable the use of the elegant text height feature for Android horizontal layout. The default value is false. More...
 
boolean getDisableElegantTextHeight (int captionIndex)
 Get is prohibit elegant text height. More...
 
void setWeight (int captionIndex, int weight)
 Sets caption weight. More...
 
int getWeight (int captionIndex)
 Get caption weight. More...
 
void setItalic (int captionIndex, boolean italic)
 Sets caption italic. More...
 
boolean getItalic (int captionIndex)
 Is set caption italic. More...
 
void setBold (int captionIndex, boolean bold)
 Sets whether the caption font is bold. More...
 
boolean getBold (int captionIndex)
 Gets the state whether the caption font is bold. 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 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...
 

Static Public Attributes

Bounding type

static final int BOUNDING_TYPE_TEXT = 0
 The actual text bounding. More...
 
static final int BOUNDING_TYPE_TEXT_FRAME = 1
 Text frame bounding. More...
 
static final int BOUNDING_TYPE_FRAME = 2
 
- 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"
 

Additional Inherited Members

- 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

compound caption.

Timeline compound captions are compound caption that is superimposed on the video, each compound caption may composed of several sub-captions. When editing a video, users can add or remove compound captions and adjust the captions position. User can also set its properties such as font family, text color, etc.

Warning
In the NvsCompoundCaption class, all public APIs should be used in the UI thread!!!
Since
2.9.0

Member Function Documentation

◆ findKeyframeTime()

long com.meicam.sdk.NvsCompoundCaption.findKeyframeTime ( String  fxParam,
long  time,
int  flags 
)
inline

Get key frame at a specified time point.

Parameters
fxParamThe type of custom data parameter for the effect.
timetime point (In microseconds).
flagsflag of finding mode, Please refer to [KEY_FRAME_FIND_MODE].
Returns
Return key frame time point near the specified time point, If there is no key frame near this time point, return - 1

Reimplemented from com.meicam.sdk.NvsFx.

◆ getAnchorPoint()

PointF com.meicam.sdk.NvsCompoundCaption.getAnchorPoint ( )
inline

Gets caption anchor.

Returns
Returns caption anchor.
See also
setAnchorPoint

◆ getBackgroundColor()

NvsColor com.meicam.sdk.NvsCompoundCaption.getBackgroundColor ( int  captionIndex)
inline

Get the current text background color value.

Parameters
captionIndexcaption index
Returns
Returns the NvsColor object representing the current background color.
See also
setBackgroundColor
Since
3.2.0

◆ getBold()

boolean com.meicam.sdk.NvsCompoundCaption.getBold ( int  captionIndex)
inline

Gets the state whether the caption font is bold.

Parameters
captionIndexcaption index
Returns
Returns the state whether the caption font is bold. YES means it is bold, NO means it is not.
See also
setBold: captionIndex:
Since
3.7.3

◆ getCaptionBoundingVertices()

List<PointF> com.meicam.sdk.NvsCompoundCaption.getCaptionBoundingVertices ( int  captionIndex,
int  boundingType 
)
inline

Gets the transformed vertices position of the original caption bounding.

Parameters
captionIndexCaption index to get vertices positions
boundingTypeBounding type. Please refer to Bounding Type
Returns
Returns a List<PointF> object containing four vertices positions, which correspond to the top left, bottom left, bottom right, and top right vertices of the original bounding.

◆ getCaptionCount()

int com.meicam.sdk.NvsCompoundCaption.getCaptionCount ( )
inline

Gets number of sub-cpations in this compound caption.

Returns
Returns number of sub-cpations

◆ getCaptionStylePackageId()

String com.meicam.sdk.NvsCompoundCaption.getCaptionStylePackageId ( )
inline

Gets the caption style package ID.

Returns
Returns the obtained caption style resource package ID.
Since
2.17.1

◆ getCaptionTranslation()

PointF com.meicam.sdk.NvsCompoundCaption.getCaptionTranslation ( )
inline

Gets the amount of caption translation.

Returns
Returns PointF object indicating the amount of caption translation obtained.
See also
setCaptionTranslation

◆ getCompoundBoundingVertices()

List<PointF> com.meicam.sdk.NvsCompoundCaption.getCompoundBoundingVertices ( int  boundingType)
inline

Gets the transformed vertices position of the original compound caption bounding.

Parameters
boundingTypeBounding type. Please refer to Bounding Type
Returns
Returns a List<PointF> object containing four vertices positions, which correspond to the top left, bottom left, bottom right, and top right vertices of the original bounding.

◆ getControlPoint()

NvsControlPointPair com.meicam.sdk.NvsCompoundCaption.getControlPoint ( String  fxParam)
inline

Get the caption's key frame control point pair.

Parameters
fxParamThe type of data parameter for the caption.
Returns
return control point data.NvsControlPointPair对象
See also
setControlPoint
Since
3.2.1

◆ getDisableElegantTextHeight()

boolean com.meicam.sdk.NvsCompoundCaption.getDisableElegantTextHeight ( int  captionIndex)
inline

Get is prohibit elegant text height.

Since
3.5.2

◆ getDrawOutline()

boolean com.meicam.sdk.NvsCompoundCaption.getDrawOutline ( int  captionIndex)
inline

Gets the caption stroke status.

Parameters
captionIndexcaption index
Returns
Returns boolean value, true means it is stroked, and false means it is not stroked.
Since
3.2.0
See also
setDrawOutline

◆ getFontFamily()

String com.meicam.sdk.NvsCompoundCaption.getFontFamily ( int  captionIndex)
inline

Get the name of caption font.

Parameters
captionIndexcaption index to get font family
Returns
Returns the name of caption font.
See also
setFontFamily

◆ getItalic()

boolean com.meicam.sdk.NvsCompoundCaption.getItalic ( int  captionIndex)
inline

Is set caption italic.

Parameters
captionIndexcaption index
Returns
Is italic.
See also
setItalic
Since
3.6.1

◆ getOpacity()

float com.meicam.sdk.NvsCompoundCaption.getOpacity ( )
inline

Get the caption opacity.

Returns
Return the caption opacity.
See also
setOpacity
Since
2.14.0

◆ getOutlineColor()

NvsColor com.meicam.sdk.NvsCompoundCaption.getOutlineColor ( int  captionIndex)
inline

Gets the color value of the current caption stroke.

Parameters
captionIndexcaption index
Returns
Returns the NvsColor object representing the color of the resulting caption stroke.
Since
3.2.0
See also
setOutlineColor

◆ getOutlineWidth()

float com.meicam.sdk.NvsCompoundCaption.getOutlineWidth ( int  captionIndex)
inline

Gets the width of the current caption stroke.

Parameters
captionIndexcaption index
Returns
Returns the width value of the obtained caption stroke.
Since
3.2.0
See also
setOutlineWidth

◆ getRotationZ()

float com.meicam.sdk.NvsCompoundCaption.getRotationZ ( )
inline

Gets caption rotation angle.

Returns
Returns caption rotation angle.
See also
setRotationZ

◆ getScaleX()

float com.meicam.sdk.NvsCompoundCaption.getScaleX ( )
inline

Gets caption horizontal scaling factor.

Returns
Returns caption horizontal scaling factor.
See also
setScaleX
getScaleY

◆ getScaleY()

float com.meicam.sdk.NvsCompoundCaption.getScaleY ( )
inline

Gets caption vertical scaling factor.

Returns
Returns caption vertical scaling factor.
See also
setScaleY
getScaleX

◆ getText()

String com.meicam.sdk.NvsCompoundCaption.getText ( int  captionIndex)
inline

Get caption text.

Parameters
captionIndexcaption index to get text
Returns
Returns caption text.
See also
setText

◆ getTextColor()

NvsColor com.meicam.sdk.NvsCompoundCaption.getTextColor ( int  captionIndex)
inline

Gets the color value of the caption.

Parameters
captionIndexcaption index to get text color
Returns
Return NvsColor object which is the text color
See also
setTextColor

◆ getWeight()

int com.meicam.sdk.NvsCompoundCaption.getWeight ( int  captionIndex)
inline

Get caption weight.

Parameters
captionIndexcaption index
Returns
weight the value in opentype weight integer.
See also
setWeight
Since
3.5.2

◆ getZValue()

float com.meicam.sdk.NvsCompoundCaption.getZValue ( )
inline

Gets caption Z value.

Returns
Returns caption Z value.

◆ hasKeyframeList()

boolean com.meicam.sdk.NvsCompoundCaption.hasKeyframeList ( String  fxParam)
inline

Check whether the parameter has key frame list or not.

Parameters
fxParamThe type of custom data parameter for the effect.
Returns
Return exist or not.

Reimplemented from com.meicam.sdk.NvsFx.

◆ isFrameCaption()

boolean com.meicam.sdk.NvsCompoundCaption.isFrameCaption ( int  captionIndex)
inline

Determine if the subtitle is a border subtitle.

Parameters
captionIndexSub caption index
Returns
Is frame caption

◆ removeAllKeyframe()

boolean com.meicam.sdk.NvsCompoundCaption.removeAllKeyframe ( String  fxParam)
inline

Remove all key frames from key frame list.

Parameters
fxParamThe type of custom data parameter for the effect.
Returns
Return success or not

Reimplemented from com.meicam.sdk.NvsFx.

◆ removeKeyframeAtTime()

boolean com.meicam.sdk.NvsCompoundCaption.removeKeyframeAtTime ( String  fxParam,
long  time 
)
inline

Remove key frame at a specified time point from key frame list.

Parameters
fxParamThe type of custom data parameter for the effect.
timetime point (In microseconds).
Returns
Return success or not

Reimplemented from com.meicam.sdk.NvsFx.

◆ rotateCaption()

void com.meicam.sdk.NvsCompoundCaption.rotateCaption ( float  angle,
PointF  anchor 
)
inline

Rotates captions.

Parameters
angleAngle of caption rotation.
anchorAnchor of caption rotation.

◆ rotateCaptionAroundCenter()

void com.meicam.sdk.NvsCompoundCaption.rotateCaptionAroundCenter ( float  angle,
int  boundingType 
)
inline

Rotates caption around center of the bounding.

Parameters
angleAngle of rotation, in degree
boundingTypeBounding type to calculate center point. Please refer to Bounding Type

◆ scaleCaption()

void com.meicam.sdk.NvsCompoundCaption.scaleCaption ( float  scaleFactor,
PointF  anchor 
)
inline

Zooms caption.

Parameters
scaleFactorCaption scaling factor.
anchorCaption zoom anchor.

◆ setAnchorPoint()

void com.meicam.sdk.NvsCompoundCaption.setAnchorPoint ( PointF  anchor)
inline

Sets caption anchor.

Parameters
anchorAnchor.
See also
getAnchorPoint

◆ setBackgroundColor()

void com.meicam.sdk.NvsCompoundCaption.setBackgroundColor ( NvsColor  backgroundColor,
int  captionIndex 
)
inline

Set text background color.

Parameters
backgroundColorBackground color value.
captionIndexcaption index
See also
getBackgroundColor
Since
3.2.0

◆ setBold()

void com.meicam.sdk.NvsCompoundCaption.setBold ( int  captionIndex,
boolean  bold 
)
inline

Sets whether the caption font is bold.

Parameters
captionIndexcaption index
boldIndicates whether the caption font is bold.YES means it is bold, NO means it is not.
See also
getBold:
Since
3.7.3

◆ setCaptionTranslation()

void com.meicam.sdk.NvsCompoundCaption.setCaptionTranslation ( PointF  translation)
inline

Sets the amount of caption translation.

Parameters
translationThe horizontal and vertical translation of the caption.
See also
getCaptionTranslation

◆ setControlPoint()

boolean com.meicam.sdk.NvsCompoundCaption.setControlPoint ( String  fxParam,
NvsControlPointPair  controlPointPair 
)
inline

Set the caption's control point pair.

Parameters
fxParamThe type of data parameter for the caption.
controlPointPaircontrol point pair.
See also
getControlPoint
Since
3.2.1

◆ setCurrentKeyFrameTime()

void com.meicam.sdk.NvsCompoundCaption.setCurrentKeyFrameTime ( long  time)
inline

Set the compound caption KeyFrameTime.

See also
setCurrentKeyFrameTime
Since
3.2.1

◆ setDisableElegantTextHeight()

void com.meicam.sdk.NvsCompoundCaption.setDisableElegantTextHeight ( int  captionIndex,
boolean  disableElegantTextHeight 
)
inline

Due to historical factors, Meishe SDK uses the elegant text height feature in the horizontal text layout of the Android platform, which will cause the horizontal layout of the Android platform to be different from the line spacing of other platforms. Setting this property will disable the use of the elegant text height feature for Android horizontal layout. The default value is false.

Parameters
disableElegantTextHeight
Since
3.5.2

◆ setDrawOutline()

void com.meicam.sdk.NvsCompoundCaption.setDrawOutline ( boolean  drawOutline,
int  captionIndex 
)
inline

Sets caption stroke.

Parameters
drawOutlineWhether to stroke the captions. True means it strokes the caption. False means it does not stroke the edges.
captionIndexcaption index to set text
Since
3.2.0
See also
getDrawOutline

◆ setFontFamily()

void com.meicam.sdk.NvsCompoundCaption.setFontFamily ( int  captionIndex,
String  family 
)
inline

Sets caption font family.

Parameters
captionIndexcaption index to set font family
familyCaption font family name. It will be set to default font if family is an empty string
See also
getFontFamily

◆ setItalic()

void com.meicam.sdk.NvsCompoundCaption.setItalic ( int  captionIndex,
boolean  italic 
)
inline

Sets caption italic.

Parameters
captionIndexcaption index
Isitalic.
See also
getItalic
Since
3.6.1

◆ setOpacity()

void com.meicam.sdk.NvsCompoundCaption.setOpacity ( float  opacity)
inline

Set the caption opacity.

Parameters
opacitycaption opacity.
See also
getOpacity
Since
2.14.0

◆ setOutlineColor()

void com.meicam.sdk.NvsCompoundCaption.setOutlineColor ( NvsColor  outlineColor,
int  captionIndex 
)
inline

Sets the color of the caption stroke.

Parameters
outlineColorCaption stroke color value.
captionIndexcaption index
Since
3.2.0
See also
getOutlineColor

◆ setOutlineWidth()

void com.meicam.sdk.NvsCompoundCaption.setOutlineWidth ( float  outlineWidth,
int  captionIndex 
)
inline

Sets the width of the caption stroke.

Parameters
outlineWidthThe width of the caption stroke.
captionIndexcaption index
Since
3.2.0
See also
getOutlineWidth

◆ setRotationZ()

void com.meicam.sdk.NvsCompoundCaption.setRotationZ ( float  angle)
inline

Sets the rotation angle for the caption.

Parameters
angleRotation angle.
See also
getRotationZ

◆ setScaleX()

void com.meicam.sdk.NvsCompoundCaption.setScaleX ( float  scale)
inline

Sets horizontal scaling factor for caption.

Parameters
scaleHorizontal scaling factor.
See also
getScaleX
setScaleY

◆ setScaleY()

void com.meicam.sdk.NvsCompoundCaption.setScaleY ( float  scale)
inline

Sets vertical scaling factor for captions.

Parameters
scaleVertical scaling factor.
See also
getScaleY
setScaleX

◆ setText()

void com.meicam.sdk.NvsCompoundCaption.setText ( int  captionIndex,
String  text 
)
inline

Sets caption text.

Parameters
captionIndexcaption index to set text
textCaption text
See also
getText

◆ setTextColor()

void com.meicam.sdk.NvsCompoundCaption.setTextColor ( int  captionIndex,
NvsColor  textColor 
)
inline

Sets caption text color.

Parameters
captionIndexcaption index to set text color
textColorCaption text color value.
See also
getTextColor

◆ setWeight()

void com.meicam.sdk.NvsCompoundCaption.setWeight ( int  captionIndex,
int  weight 
)
inline

Sets caption weight.

Parameters
captionIndexcaption index
weightthe value in opentype weight integer.
See also
getWeight
Since
3.5.2

◆ setZValue()

void com.meicam.sdk.NvsCompoundCaption.setZValue ( float  value)
inline

Sets caption Z value.

Parameters
valueZ value

◆ translateCaption()

void com.meicam.sdk.NvsCompoundCaption.translateCaption ( PointF  translationOffset)
inline

Translate caption.

Parameters
translationOffsetHorizontal and vertical offset values for caption.
See also
setCaptionTranslation
getCaptionTranslation

Member Data Documentation

◆ BOUNDING_TYPE_FRAME

final int com.meicam.sdk.NvsCompoundCaption.BOUNDING_TYPE_FRAME = 2
static

The whole bounding including decoration

◆ BOUNDING_TYPE_TEXT

final int com.meicam.sdk.NvsCompoundCaption.BOUNDING_TYPE_TEXT = 0
static

The actual text bounding.

◆ BOUNDING_TYPE_TEXT_FRAME

final int com.meicam.sdk.NvsCompoundCaption.BOUNDING_TYPE_TEXT_FRAME = 1
static

Text frame bounding.


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