Class: NvsVideoClip

NvsVideoClip()

Video clip, description of video file. The video clip source can be video or image. Each video clip can modify its trim in point, trim out point and playback speed, and can also set panning and scanning. When editing a video, you can add or insert multiple video effects according to different types of effects (built-in effects, wrapped effects, beauty effects). When adding resource pack effects, you have to install them first. After the installation is successful, you can use them only by obtaining the packageid, while builtin only needs to obtain the name of the effect.

Constructor

new NvsVideoClip()

Source:

Extends

Methods

appendBuiltinFx(fxName)

append builtin fx
Parameters:
Name Type Description
fxName fx name
Source:
Returns:

appendPackagedFx(fxPackageId)

append packaged fx
Parameters:
Name Type Description
fxPackageId fx package id
Source:
Returns:

appendRawBuiltinFx(fxName)

append raw builtin fx
Parameters:
Name Type Description
fxName fx name
Source:
Returns:

appendRawPackagedFx(fxPackageId)

append raw packaged fx
Parameters:
Name Type Description
fxPackageId package id
Source:
Returns:

changeCurvesVariableSpeed(curvesString, keepAudioPitch)

change variable speed of curves
Parameters:
Name Type Description
curvesString curves string
keepAudioPitch keep audio pitch
Overrides:
Source:
Returns:

changeSpeed(newSpeed, keepAudioPitch)

change speed
Parameters:
Name Type Description
newSpeed new speed
keepAudioPitch keep audio pitch
Overrides:
Source:
Returns:

changeTrimInPoint(newTrimInPoint, affectSibling)

change trim in point
Parameters:
Name Type Description
newTrimInPoint new trim in point
affectSibling affect sibling
Overrides:
Source:
Returns:

changeTrimOutPoint(newTrimOutPoint, affectSibling)

change trim out point
Parameters:
Name Type Description
newTrimOutPoint new trim out point
affectSibling affect sibling
Overrides:
Source:
Returns:

enableClipFreezeFrame(enabled)

enabled clip freeze frame
Parameters:
Name Type Description
enabled enabled
Source:
Returns:

enablePropertyVideoFx(enable)

enable property video fx
Parameters:
Name Type Description
enable enabled or not
Source:
Returns:

getClipFreezeFrameTrimPosition()

get trim position of clip freeze frame
Source:
Returns:

getClipPosByTimelinePosCurvesVariableSpeed(timelinePos)

get clip position according timeline position curve speed
Parameters:
Name Type Description
timelinePos timeline position
Overrides:
Source:
Returns:

getClipVariableSpeedCurvesString()

get curve character string of clip speed
Overrides:
Source:
Returns:

getClipWrapMode()

get wrap mode of clip
Source:
Returns:

getExtraVideoRotation()

get extra video rotation
Source:
Returns:

getFadeInDuration()

get duration of fade in
Overrides:
Source:
Returns:

getFadeOutDuration()

get duration of fade out
Overrides:
Source:
Returns:

getFilePath()

get file path
Overrides:
Source:
Returns:

getFxByIndex(fxIndex)

get fx by index
Parameters:
Name Type Description
fxIndex fx index
Source:
Returns:

getFxCount()

get fx count
Overrides:
Source:
Returns:

getImageMotionMode()

get motion mode of image
Source:
Returns:

getIndex()

get index
Overrides:
Source:
Returns:

getInPoint()

get in point
Overrides:
Source:
Returns:

getInternalObject() → {Num}

get internal object
Overrides:
Source:
Returns:
Type
Num

getOutPoint()

get out point
Overrides:
Source:
Returns:

getPanAndScan()

get pan and scan
Source:
Returns:

getPlayInReverse()

get play in reverse
Source:
Returns:

getPropertyVideoFx()

get property video fx
Source:
Returns:

getRawFxByIndex(fxIndex)

get raw fx by index
Parameters:
Name Type Description
fxIndex fx index
Source:
Returns:

getRawFxCount()

get count of raw fx
Source:
Returns:

getRoleInTheme()

get role in theme
Source:
Returns:

getSourceBackgroundColor()

get background color of source
Source:
Returns:

getSourceBackgroundMode()

get background mode of source
Source:
Returns:

getSpeed()

get speed
Overrides:
Source:
Returns:

getTemplateAttachment(key) → {Num}

get template attachment according key
Parameters:
Name Type Description
key key
Overrides:
Source:
Returns:
Type
Num

getTimelinePosByClipPosCurvesVariableSpeed(clipPos)

get timeline position according curve speed of clip position
Parameters:
Name Type Description
clipPos clip position
Overrides:
Source:
Returns:

getTrimIn()

get trim in
Overrides:
Source:
Returns:

getTrimOut()

get trim out
Overrides:
Source:
Returns:

getType()

get type
Overrides:
Source:
Returns:

getVideoType()

get type of video
Source:
Returns:

getVolumeGain()

get volume gain
Overrides:
Source:
Returns:

insertBuiltinFx(fxName, fxIndex)

insert builtin fx
Parameters:
Name Type Description
fxName fx name
fxIndex fx index
Source:
Returns:

insertPackagedFx(fxPackageId, fxIndex)

insert packaged fx
Parameters:
Name Type Description
fxPackageId fx package id
fxIndex fx index
Source:
Returns:

insertRawBuiltinFx(fxName, fxIndex)

insert raw builtin fx
Parameters:
Name Type Description
fxName fx name
fxIndex fx index
Source:
Returns:

insertRawPackagedFx(fxPackageId, fxIndex)

insert raw packaged fx
Parameters:
Name Type Description
fxPackageId package id
fxIndex fx index
Source:
Returns:

isClipFreezeFrameEnabled()

enable clip freeze frame or not
Source:
Returns:

isImageMotionAnimationEnabled()

enable image animation of motion or not
Source:
Returns:

moveTrimPoint(offset)

move trim point
Parameters:
Name Type Description
offset offset
Overrides:
Source:
Returns:

removeAllFx()

remove all fx
Source:
Returns:

removeFx(fxIndex)

remove fx
Parameters:
Name Type Description
fxIndex fx index
Source:
Returns:

removeRawFx(fxIndex)

remove raw fx
Parameters:
Name Type Description
fxIndex fx index
Source:
Returns:

setClipFreezeFrameTrimPosition(trimPos)

set trim position of clip freeze frame
Parameters:
Name Type Description
trimPos trim position
Source:
Returns:

setClipWrapMode(wrapMode)

set wrap mode of clip
Parameters:
Name Type Description
wrapMode wrapMode
Source:
Returns:

setExtraVideoRotation(rotation)

set extra video rotation
Parameters:
Name Type Description
rotation rotation
Source:
Returns:

setFadeInDuration(duration)

set duration of fade in
Parameters:
Name Type Description
duration duration
Overrides:
Source:
Returns:

setFadeOutDuration(duration)

set duration of fade out
Parameters:
Name Type Description
duration duration
Overrides:
Source:
Returns:

setImageMotionAnimationEnabled(enabled)

set enabling of image motion animation
Parameters:
Name Type Description
enabled enabled
Source:
Returns:

setImageMotionMode(mode)

set motion mode of image
Parameters:
Name Type Description
mode mode
Source:
Returns:

setInternalObject(obj)

set internal object
Parameters:
Name Type Description
obj internal object
Overrides:
Source:
Returns:

setPanAndScan(pan, scan)

set pan and scan
Parameters:
Name Type Description
pan pan
scan scan
Source:
Returns:

setPlayInReverse(playInReverse)

set play in reverse
Parameters:
Name Type Description
playInReverse reverse of not
Source:
Returns:

setSourceBackgroundColor(color)

set background color of source
Parameters:
Name Type Description
color color
Source:
Returns:

setSourceBackgroundMode(mode)

set background color of source
Parameters:
Name Type Description
mode mode
Source:
Returns:

setTemplateAttachment(key, value)

get template attachment
Parameters:
Name Type Description
key key
value value
Overrides:
Source:
Returns:

setVolumeGain(leftVolumeGain, rightVolumeGain)

set volume gain
Parameters:
Name Type Description
leftVolumeGain left volume gain
rightVolumeGain right volume gain
Overrides:
Source:
Returns: