public class AliyunPasterControllerCompoundCaption extends AliyunPasterAbstractController<AliyunCaption>
| Modifier and Type | Field and Description |
|---|---|
static int |
AlignCenter |
static int |
AlignLeft |
static int |
AlignRight |
mModel, mRender| Modifier and Type | Method and Description |
|---|---|
int |
addFrameAnimation(ActionBase action)
Adds an animation to a stream or material.
|
void |
apply() |
int |
clearFrameAnimation()
Clear Animation
|
AliyunColor |
getBackgroundColor()
Get the background color of caption
Added in v3.23.0
|
java.lang.String |
getBubbleEffectTemplate()
Deprecated.
Use
getBubbleEffectTemplateSource() instead. |
ISource |
getBubbleEffectTemplateSource()
Get the template Source for bubble text
Added in v3.23.0
|
AliyunColor |
getColor()
Get the text color of caption
Added in v3.22.0
|
long |
getDuration()
Get Caption Render Duration in milliseconds
|
java.lang.String |
getFontEffectTemplate()
Deprecated.
Use
getFontEffectTemplateSource() instead. |
ISource |
getFontEffectTemplateSource()
Get the template Source for font effect
Added in v3.23.0
|
ISource |
getFontPath()
Get Font Source
Added in v3.24.0
|
AliyunFontStyle |
getFontStyle()
Deprecated.
|
AliyunTypeface |
getFontTypeface()
Set the font typeface style
Added in v3.24.0
|
java.util.List<ActionBase> |
getFrameAnimations()
Get Frame Animation List
Added in v3.22.0
|
AliyunColor |
getOutlineColor()
Get the text stroke color of caption
Added in v3.22.0
|
float |
getOutlineWidth()
Get the text stroke width, unit: pixel
Added in v3.22.0
|
PointF |
getPosition()
Get the center point position (x,y) of the Caption, the value of x and y is between [0-1]
|
float |
getRotate()
Get the radian of rotation of the caption
|
float |
getScale()
Get the scale value of caption, the default is 1.0
Added in v3.22.0
|
AliyunColor |
getShadowColor()
Get the shadow color of caption
Added in v3.22.0
|
PointF |
getShadowOffset()
Get the offset value of the shadow, including (x, y) two directions, unit: pixel,range: [0-32]
Added in v3.22.0
|
RectF |
getSize()
Get the size of the Caption, get the width and height through
android.graphics.RectF#width() and android.graphics.RectF#height() |
long |
getStartTime()
Get Caption Render Start Time in milliseconds
|
java.lang.String |
getText()
Get Caption Text
Added in v3.22.0
|
int |
getTextAlignment()
Get alignment of text
Added in v3.23.0
|
int |
getType()
Gets the sticker type.
|
int |
removeFrameAnimation(ActionBase action)
Removes an animation.
|
void |
setBackgroundColor(AliyunColor aColor)
Set the background color of Caption
Added in v3.23.0
|
void |
setBubbleEffectTemplate(Source aStyleTemplate)
Set the template for bubble text
Added in v3.23.0
|
void |
setBubbleEffectTemplate(java.lang.String aStyleTemplate)
Deprecated.
Use
setBubbleEffectTemplate(Source) instead. |
void |
setColor(AliyunColor aColor)
Set the text color of Caption
Added in v3.22.0
|
void |
setDuration(long aDuration)
Set Caption Render Duration in milliseconds
|
void |
setFontEffectTemplate(Source fontEffectSource)
Set the template for font effect
Added in v3.23.0
|
void |
setFontEffectTemplate(java.lang.String aStyleTemplate)
Deprecated.
Use
setFontEffectTemplate(Source) instead. |
void |
setFontPath(ISource aFontPath)
Set the font ttf of the caption
Added in v3.24.0
|
void |
setFontStyle(AliyunFontStyle aFontStyle)
Deprecated.
|
void |
setFontTypeface(AliyunTypeface aFontTypeface)
Set the font typeface of the caption
Added in v3.24.0
|
int |
setFrameAnimation(ActionBase action)
Adds an animation to a stream or material.
|
void |
setOutlineColor(AliyunColor aOutlineColor)
Set the text stroke color of caption
Added in v3.22.0
|
void |
setOutlineWidth(float aOutlineWidth)
Set the text stroke width, unit: pixel, range : [0-64]
Added in v3.22.0
|
void |
setPosition(PointF aPosition)
Set the center point position of the caption (x,y), the value of x and y are between [0-1]
|
void |
setRotate(float degree)
Set the radian of rotation of the caption
|
void |
setScale(float aScale)
Set caption scale value
Added in v3.22.0
|
void |
setShadowColor(AliyunColor aShadowColor)
Set the shadow color of caption
Added in v3.22.0
|
void |
setShadowOffset(PointF aShadowOffset)
Set the offset value of the shadow, including (x, y) two directions, unit: pixel, range: [0-32]
Added in v3.22.0
|
void |
setStartTime(long aStartTime)
Set Caption Render Start Time in milliseconds
|
void |
setText(java.lang.String aText)
Set Caption Text
Added in v3.22.0
|
void |
setTextAlignment(int aTextAlignment)
Set the alignemnt of text
Added in v3.23.0
|
public static final int AlignLeft
public static final int AlignRight
public static final int AlignCenter
public int getType()
AliyunIPasterControllerEffectPaster.PASTER_TYPE_GIF,
EffectPaster.PASTER_TYPE_TEXTpublic long getStartTime()
AliyunIPasterControllerpublic void setStartTime(long aStartTime)
AliyunIPasterControlleraStartTime - Start Time in millisecondspublic long getDuration()
AliyunIPasterControllerpublic void setDuration(long aDuration)
AliyunIPasterControlleraDuration - Duration in millisecondspublic PointF getPosition()
AliyunIPasterControllerpublic void setPosition(PointF aPosition)
AliyunIPasterControlleraPosition - center point position (x,y), the value of x and y is between [0-1]public RectF getSize()
AliyunIPasterControllerandroid.graphics.RectF#width() and android.graphics.RectF#height()android.graphics.RectFpublic float getRotate()
AliyunIPasterControllerpublic void setRotate(float degree)
AliyunIPasterControllerpublic java.lang.String getText()
public void setText(java.lang.String aText)
aText - Textpublic float getScale()
public void setScale(float aScale)
aScale - > 0@Deprecated public AliyunFontStyle getFontStyle()
AliyunFontStyle@Deprecated public void setFontStyle(AliyunFontStyle aFontStyle)
aFontStyle - the font styleAliyunFontStylepublic ISource getFontPath()
public void setFontPath(ISource aFontPath)
aFontPath - the font ttf pathpublic AliyunTypeface getFontTypeface()
public void setFontTypeface(AliyunTypeface aFontTypeface)
aFontTypeface - the font typefaceAliyunTypefacepublic int getTextAlignment()
public void setTextAlignment(int aTextAlignment)
aTextAlignment - the alignment of text
e.g.
AlignLeft = 1;
AlignRight = 2;
AlignHCenter = 4;AliyunFontStylepublic AliyunColor getColor()
AliyunColorpublic void setColor(AliyunColor aColor)
aColor - color valueAliyunColorpublic AliyunColor getBackgroundColor()
AliyunColorpublic void setBackgroundColor(AliyunColor aColor)
aColor - color valueAliyunColorpublic AliyunColor getOutlineColor()
AliyunColorpublic void setOutlineColor(AliyunColor aOutlineColor)
aOutlineColor - color valueAliyunColorpublic float getOutlineWidth()
public void setOutlineWidth(float aOutlineWidth)
aOutlineWidth - stroke width, unit: pixelpublic AliyunColor getShadowColor()
AliyunColorpublic void setShadowColor(AliyunColor aShadowColor)
aShadowColor - color valueAliyunColorpublic PointF getShadowOffset()
android.graphics.PointFpublic void setShadowOffset(PointF aShadowOffset)
aShadowOffset - The offset value of the shadow in (x,y)android.graphics.PointFpublic void setBubbleEffectTemplate(java.lang.String aStyleTemplate)
setBubbleEffectTemplate(Source) instead.aStyleTemplate - template pathpublic java.lang.String getBubbleEffectTemplate()
getBubbleEffectTemplateSource() instead.public void setBubbleEffectTemplate(Source aStyleTemplate)
aStyleTemplate - template Sourcepublic ISource getBubbleEffectTemplateSource()
public void setFontEffectTemplate(java.lang.String aStyleTemplate)
setFontEffectTemplate(Source) instead.aStyleTemplate - template pathpublic void setFontEffectTemplate(Source fontEffectSource)
fontEffectSource - template Sourcepublic java.lang.String getFontEffectTemplate()
getFontEffectTemplateSource() instead.public ISource getFontEffectTemplateSource()
public void apply()
public int addFrameAnimation(ActionBase action)
action - ActionBasepublic int removeFrameAnimation(ActionBase action)
action - public int setFrameAnimation(ActionBase action)
action, - if is null, will clean current animationsActionBasepublic int clearFrameAnimation()
public java.util.List<ActionBase> getFrameAnimations()