Go to the documentation of this file.
16 #import <CoreGraphics/CGGeometry.h>
159 - (int64_t)changeInPoint:(int64_t)newInPoint;
175 - (int64_t)changeOutPoint:(int64_t)newOutPoint;
189 - (void)movePosition:(int64_t)offset;
203 -(bool) applyCaptionStyle:(NSString*) captionStylePackageId;
219 -(bool) applyModularCaptionContext:(NSString*) captionContextPackageId;
235 -(bool) applyModularCaptionRenderer:(NSString*) captionRendererPackageId;
251 -(bool) applyModularCaptionAnimation:(NSString*) captionAnimationPackageId;
267 -(bool) applyModularCaptionInAnimation:(NSString*) captionInAnimationPackageId;
283 -(bool) applyModularCaptionOutAnimation:(NSString*) captionOutAnimationPackageId;
295 -(void) setModularCaptionAnimationPeroid:(
int)periodInMS;
319 -(void) setModularCaptionInAnimationDuration:(
int)inAnimationDurationInMS;
343 -(void) setModularCaptionOutAnimationDuration:(
int)outAnimationDurationInMS;
371 -(bool) applyCaptionStyleWithAssetDefaultParam:(NSString*) captionStylePackageId isUseDefaultAssetParam:(
NvsVideoEffectAssetDefaultParam)isUseDefaultAssetParam;
382 - (void)setText:(NSString *)text;
404 - (void)setVerticalLayout:(BOOL)verticalLayout;
474 - (void)setBold:(BOOL)bold;
496 - (void)setWeight:(
int)weight;
518 - (void)setItalic:(BOOL)italic;
540 - (void)setUnderline:(BOOL)underline;
577 - (void)setLetterSpacing:(
float)letterSpacing;
625 - (void)setLineSpacing:(
float)lineSpacing;
659 - (void)setDrawOutline:(BOOL)drawOutline;
703 - (void)setOutlineWidth:(
float)outlineWidth;
725 - (void)setDrawShadow:(BOOL)drawShadow;
769 - (void)setShadowOffset:(CGPoint)shadowOffset;
791 - (void)setShadowFeather:(
float)feather;
813 - (void)setFontSize:(
float)fontSize;
833 - (void)setFrameCaptionMaxFontSize:(
float)maxFontSize;
845 - (void)setFontWithFilePath:(NSString *)filePath;
879 - (void)setFontFamily:(NSString *)family;
891 - (void)setCaptionTranslation:(CGPoint)translation;
915 - (void)translateCaption:(CGPoint)translationOffset;
927 - (void)setAnchorPoint:(CGPoint)anchor;
952 - (void)setScaleX:(
float)scale;
978 - (void)setScaleY:(
float)scale;
1004 - (void)scaleCaption:(
float)scaleFactor anchor:(CGPoint)anchor;
1016 - (void)setRotationZ:(
float)angle;
1042 - (void)rotateCaption:(
float)angle anchor:(CGPoint)anchor;
1054 - (void)rotateCaption:(
float)angle;
1076 - (
NvsEffectRect)getTextBoundingRect:(BOOL)actualBoundingRect;
1100 - (void)setCenterPolarAngle:(
float)centerPolarAngle;
1133 - (void)setCenterAzimuthAngle:(
float)centerAzimuthAngle;
1167 - (void)setPolarAngleRange:(
float)polarAngleRange;
1222 - (void)setPanoramicScaleX:(
float)scaleX;
1244 - (void)setPanoramicScaleY:(
float)scaleY;
1266 - (void)setPanoramicRotation:(
float)rotationAngle;
1288 - (void)setZValue:(
float)value;
1310 - (void)setRecordingUserOperation:(BOOL)recordingUserOperation;
1321 - (void)setOpacity:(
float)opacity;
1344 - (void)setBackgroundColor:(const
NvsEffectColor *)backgroundColor;
1368 - (void)setBackgroundRadius:(
float)radius;
1414 - (void)setCurrentKeyFrameTime:(int64_t)time;
BOOL clipAffinityEnabled
Whether to enable the affinity with clip.
Definition: NvsVideoEffectCaption.h:122
float getOpacity()
Get the caption opacity.
float getCenterAzimuthAngle()
Gets the azimuth angle of the center point for the caption. It's only valid for the panorama caption.
NvsEffectColor getOutlineColor()
Gets the color of the outline for the caption.
BOOL isFrameCaption()
Gets whether the caption is a frame caption.
float getRotationZ()
Gets the rotation angle for the caption.
NvsVideoEffectTextAlignment getTextAlignment()
Gets the caption horizontal alignment method.
float getCenterPolarAngle()
Gets the polar angle of the center point for the caption. It's only valid for the panorama caption.
NvsVideoEffectCategory
Definition: NvsVideoEffectCaption.h:26
Rectangle.
Definition: NvsEffectCommonDef.h:120
@ NvsVideoEffectLetterSpacingTypePercentage
Definition: NvsVideoEffectCaption.h:99
BOOL isPanoramic
Whether it is a panorama caption.
Definition: NvsVideoEffectCaption.h:120
float getShadowFeather()
Gets the feathering degree of the caption shadow.
float getZValue()
Gets the Z value of the caption.
CGPoint getAnchorPoint()
Gets the caption anchor.
float getBackgroundRadius()
Get the current text background rectangle's corner radius value.
captions.
Definition: NvsVideoEffectCaption.h:119
float getTextCenterPolarAngle()
Gets the polar angle of the center point for the caption text. It's only valid for the panorama capti...
float getPanoramicRotation()
Gets the rotation angle for the caption. It's only valid for the panorama caption.
@ NvsVideoEffectTextAlignmentTop
Definition: NvsVideoEffectCaption.h:56
BOOL getDrawOutline()
Gets the status whether the caption draws the outline.
int getModularCaptionInAnimationDuration()
Get modular caption in-animation duration.
CGPoint getShadowOffset()
Gets the offset of the caption shadow.
float getTextCenterAzimuthAngle()
Gets the azimuth angle of the center point for the caption text. It's only valid for the panorama cap...
float getScaleX()
Gets the horizontal scaling factor for the caption.
float getPolarAngleRange()
Gets the ranging angle of the polar angle for the caption. It's only valid for the panorama caption.
NSString * modularCaptionContextPackageId
The package ID of the modular caption context style.
Definition: NvsVideoEffectCaption.h:128
NvsVideoEffectCategory category
Clip type.
Definition: NvsVideoEffectCaption.h:126
float getTextOrthoAngleRange()
Gets the ranging angle of which is perpendicular with the polar angle for the caption text....
NvsVideoEffectRoleInTheme
The role of the clip in the theme.
Definition: NvsVideoEffectCaption.h:39
NSString * modularCaptionRendererPackageId
The package ID of the modular caption render style.
Definition: NvsVideoEffectCaption.h:129
@ NvsVideoEffectTextAlignmentBottom
Definition: NvsVideoEffectCaption.h:57
BOOL getUnderline()
Gets the caption under line.
NvsVideoEffectTextAlignment
Text alignment style.
Definition: NvsVideoEffectCaption.h:52
@ NvsVideoEffectDefaultCategory
Default type.
Definition: NvsVideoEffectCaption.h:27
int getModularCaptionAnimationPeroid()
Get modular caption Animation Peroid.
@ NvsVideoEffectBoundingType_Frame
The whole bounding including decoration.
Definition: NvsVideoEffectCaption.h:86
float getLineSpacing()
Gets caption line spacing.
NvsEffectColor getSecondaryColor()
Gets the current color value of the caption.
@ NvsVideoEffectTextAlignmentCenter
Definition: NvsVideoEffectCaption.h:54
@ VIDEO_EFFECT_NOT_USE_ASSET_DEFAULT_PARAM
Definition: NvsVideoEffectCaption.h:70
@ NvsVideoEffectRoleInThemeTrailer
Trailer.
Definition: NvsVideoEffectCaption.h:42
float getFontSize()
Gets the font size of the caption.
@ NvsVideoEffectBoundingType_Text
The actual text bounding.
Definition: NvsVideoEffectCaption.h:84
CGPoint getCaptionTranslation()
Gets the translation amount of the caption.
BOOL getBold()
Gets the state whether the caption font is bold.
NvsVideoEffectAssetDefaultParam
Uses the default caption package.
Definition: NvsVideoEffectCaption.h:68
float getLetterSpacing()
Gets caption word spacing.
NvsVideoEffectTextAlignment getTextVerticalAlignment()
Gets the caption vertical alignment method.
@ NvsVideoEffectBoundingType_Typographic_Text
The typographic text bounding.
Definition: NvsVideoEffectCaption.h:88
float getOrthoAngleRange()
Gets the ranging angle which is perpendicular with the polar angle for the caption....
NvsVideoEffectBoundingType
Definition: NvsVideoEffectCaption.h:83
NSString * captionStylePackageId
The package ID of the caption style.
Definition: NvsVideoEffectCaption.h:127
@ VIDEO_EFFECT_USE_ASSET_DEFAULT_PARAM
Definition: NvsVideoEffectCaption.h:69
NSString * modularCaptionAnimationPackageId
The package ID of the modular caption animation style.
Definition: NvsVideoEffectCaption.h:130
int64_t inPoint
The in point of the caption on the timeline(in microseconds)
Definition: NvsVideoEffectCaption.h:123
BOOL getItalic()
Gets the state whether the caption font is italic.
int getModularCaptionOutAnimationDuration()
Get modular caption out-animation duration.
NvsEffectColor getTextColor()
Gets the current color value of the caption font.
Self-defined color.
Definition: NvsEffectCommonDef.h:55
@ NvsVideoEffectBoundingType_Text_Origin_Frame
Text frame bounding that has not been transformed.
Definition: NvsVideoEffectCaption.h:87
@ NvsVideoEffectTextAlignmentLeft
Definition: NvsVideoEffectCaption.h:53
float getOutlineWidth()
Gets the width of the outline for the caption.
@ NvsVideoEffectTextAlignmentVCenter
Definition: NvsVideoEffectCaption.h:58
NvsVideoEffectRoleInTheme roleInTheme
The role of captions in the theme (general, title, and trailer.)
Definition: NvsVideoEffectCaption.h:125
NSString * modularCaptionInAnimationPackageId
The package ID of the modular caption in-animation style.
Definition: NvsVideoEffectCaption.h:131
@ NvsVideoEffectThemeCategory
Theme category.
Definition: NvsVideoEffectCaption.h:29
NSString * modularCaptionOutAnimationPackageId
The package ID of the modular caption out-animation style.
Definition: NvsVideoEffectCaption.h:132
NvsEffectColor getBackgroundColor()
Get the current text background color value.
BOOL isModular
whether the current caption is a modular caption
Definition: NvsVideoEffectCaption.h:121
#define NVS_EXPORT
Definition: NvsCommonDef.h:20
Special effects.
Definition: NvsEffect.h:46
NvsVideoEffectLetterSpacingType getLetterSpacingType()
Gets caption word spacing type.
NSString * getFontFamily()
Gets the caption font.
Video resolution.
Definition: NvsEffectCommonDef.h:39
float getScaleY()
Gets the vertical scaling factor for the caption.
int64_t outPoint
The out point of the caption on the timeline (in microseconds)
Definition: NvsVideoEffectCaption.h:124
float getPanoramicScaleY()
Gets the vertical scaling factor for the caption. It's only valid for the panorama caption.
NvsVideoEffectLetterSpacingType
letter spacing type
Definition: NvsVideoEffectCaption.h:98
float getTextPolarAngleRange()
Gets the ranging angle of the polar angle for the caption text. It's only valid for the panorama capt...
@ NvsVideoEffectRoleInThemeTitle
Title.
Definition: NvsVideoEffectCaption.h:41
@ NvsVideoEffectLetterSpacingTypeAbsolute
Definition: NvsVideoEffectCaption.h:100
BOOL getDrawShadow()
Gets the state of the current caption shadow.
@ NvsVideoEffectTextAlignmentRight
Definition: NvsVideoEffectCaption.h:55
@ NvsVideoEffectRoleInThemeGeneral
General.
Definition: NvsVideoEffectCaption.h:40
NSString * getFontFilePath()
Gets the file path of the caption font.
BOOL getVerticalLayout()
Gets the state whether the caption is vertical layout.
int getWeight()
Gets the caption weight.
NSString * getText()
Gets the caption text.
@ NvsVideoEffectUserCategory
User-defined type.
Definition: NvsVideoEffectCaption.h:28
NvsEffectColor getShadowColor()
Gets the color of the caption shadow.
float getPanoramicScaleX()
Gets the horizontal scaling factor for the caption. It's only valid for the panorama caption.
@ NvsVideoEffectBoundingType_Text_Frame
Text frame bounding.
Definition: NvsVideoEffectCaption.h:85