Tizen Native API  7.0

The Effect API provides functions to manage layers.

Required Header

#include <media_editor.h>

Overview

The Mediaeditor Effect API allows you to:

  • add/remove effect
  • add transition effect where clips are overlapped

Functions

int mediaeditor_add_transition (mediaeditor_h editor, mediaeditor_transition_type_e type, unsigned int layer_id, unsigned int start, unsigned int duration)
 Adds transition effect to the overlapped clip section.
int mediaeditor_add_effect (mediaeditor_h editor, mediaeditor_effect_type_e type, unsigned int layer_id, unsigned int start, unsigned int duration, unsigned int *effect_id)
 Adds a new effect.
int mediaeditor_remove_effect (mediaeditor_h editor, unsigned int effect_id)
 Removes an effect from timeline.

Enumeration Type Documentation

Enumeration for the effect type.

Since :
7.0
Remarks:
MEDIAEDITOR_EFFECT_AUDIO_TYPE_FADE_IN and MEDIAEDITOR_EFFECT_AUDIO_TYPE_FADE_OUT Can not be rolled back *
Enumerator:
MEDIAEDITOR_EFFECT_TYPE_NONE 

None

MEDIAEDITOR_EFFECT_VIDEO_TYPE_EDGETV 

Applies edge detect on video

MEDIAEDITOR_EFFECT_VIDEO_TYPE_AGINGTV 

Adds age to video input using scratches and dust

MEDIAEDITOR_EFFECT_VIDEO_TYPE_DICETV 

Dices the screen up into many small squares

MEDIAEDITOR_EFFECT_VIDEO_TYPE_WARPTV 

Realtime goo'ing of the video input

MEDIAEDITOR_EFFECT_VIDEO_TYPE_SHAGADELICTV 

Makes images shagadelic

MEDIAEDITOR_EFFECT_VIDEO_TYPE_VERTIGOTV 

A loopback alpha blending effector with rotating and scaling

MEDIAEDITOR_EFFECT_VIDEO_TYPE_REVTV 

A video waveform monitor for each line of video processed

MEDIAEDITOR_EFFECT_VIDEO_TYPE_QUARKTV 

Motion dissolver

MEDIAEDITOR_EFFECT_VIDEO_TYPE_OPTV 

Optical art meets real-time video effect

MEDIAEDITOR_EFFECT_VIDEO_TYPE_RADIOACTV 

Detects a difference from previous frame and blurs it

MEDIAEDITOR_EFFECT_VIDEO_TYPE_STREAKTV 

Makes after images of moving objects

MEDIAEDITOR_EFFECT_VIDEO_TYPE_RIPPLETV 

Makes ripple mark effect on the video input

MEDIAEDITOR_EFFECT_AUDIO_TYPE_FADE_IN 

Audio fade in

MEDIAEDITOR_EFFECT_AUDIO_TYPE_FADE_OUT 

Audio fade out

MEDIAEDITOR_EFFECT_AUDIO_TYPE_ECHO 

Adds an echo or reverb effect to an audio stream

Enumeration for the transition type.

Since :
7.0
Enumerator:
MEDIAEDITOR_TRANSITION_TYPE_NONE 

Transition none

MEDIAEDITOR_TRANSITION_TYPE_BAR_WIPE_LR 

A bar moves from left to right

MEDIAEDITOR_TRANSITION_TYPE_BAR_WIPE_TB 

A bar moves from top to bottom

MEDIAEDITOR_TRANSITION_TYPE_BOX_WIPE_TL 

A box expands from the upper-left corner to the lower-right corner

MEDIAEDITOR_TRANSITION_TYPE_BOX_WIPE_TR 

A box expands from the upper-right corner to the lower-left corner

MEDIAEDITOR_TRANSITION_TYPE_BOX_WIPE_BR 

A box expands from the lower-right corner to the upper-left corner

MEDIAEDITOR_TRANSITION_TYPE_BOX_WIPE_BL 

A box expands from the lower-left corner to the upper-right corner

MEDIAEDITOR_TRANSITION_TYPE_FOUR_BOX_WIPE_CI 

A box shape expands from each of the four corners toward the center

MEDIAEDITOR_TRANSITION_TYPE_FOUR_BOX_WIPE_CO 

A box shape expands from the center of each quadrant toward the corners of each quadrant

MEDIAEDITOR_TRANSITION_TYPE_BARNDOOR_V 

A central, vertical line splits and expands toward the left and right edges

MEDIAEDITOR_TRANSITION_TYPE_BARNDOOR_H 

A central, horizontal line splits and expands toward the top and bottom edges

MEDIAEDITOR_TRANSITION_TYPE_BOX_WIPE_TC 

A box expands from the top edge's midpoint to the bottom corners

MEDIAEDITOR_TRANSITION_TYPE_BOX_WIPE_RC 

A box expands from the right edge's midpoint to the left corners

MEDIAEDITOR_TRANSITION_TYPE_BOX_WIPE_BC 

A box expands from the bottom edge's midpoint to the top corners

MEDIAEDITOR_TRANSITION_TYPE_BOX_WIPE_LC 

A box expands from the left edge's midpoint to the right corners

MEDIAEDITOR_TRANSITION_TYPE_DIAGONAL_TL 

A diagonal line moves from the upper-left corner to the lower-right corner

MEDIAEDITOR_TRANSITION_TYPE_DIAGONAL_TR 

A diagonal line moves from the upper right corner to the lower-left corner

MEDIAEDITOR_TRANSITION_TYPE_BOWTIE_V 

Two wedge shapes slide in from the top and bottom edges toward the center

MEDIAEDITOR_TRANSITION_TYPE_BOWTIE_H 

Two wedge shapes slide in from the left and right edges toward the center

MEDIAEDITOR_TRANSITION_TYPE_BARNDOOR_DBL 

A diagonal line from the lower-left to upper-right corners splits and expands toward the opposite corners

MEDIAEDITOR_TRANSITION_TYPE_BARNDOOR_DTL 

A diagonal line from upper-left to lower-right corners splits and expands toward the opposite corners

MEDIAEDITOR_TRANSITION_TYPE_MISC_DIAGONAL_DBD 

Four wedge shapes split from the center and retract toward the four edges

MEDIAEDITOR_TRANSITION_TYPE_MISC_DIAGONAL_DD 

A diamond connecting the four edge midpoints simultaneously contracts toward the center and expands toward the edges

MEDIAEDITOR_TRANSITION_TYPE_VEE_D 

A wedge shape moves from top to bottom

MEDIAEDITOR_TRANSITION_TYPE_VEE_L 

A wedge shape moves from right to left

MEDIAEDITOR_TRANSITION_TYPE_VEE_U 

A wedge shape moves from bottom to top

MEDIAEDITOR_TRANSITION_TYPE_VEE_R 

A wedge shape moves from left to right

MEDIAEDITOR_TRANSITION_TYPE_BARNVEE_D 

A 'V' shape extending from the bottom edge's midpoint to the opposite corners contracts toward the center and expands toward the edges

MEDIAEDITOR_TRANSITION_TYPE_BARNVEE_L 

A 'V' shape extending from the left edge's midpoint to the opposite corners contracts toward the center and expands toward the edges

MEDIAEDITOR_TRANSITION_TYPE_BARNVEE_U 

A 'V' shape extending from the top edge's midpoint to the opposite corners contracts toward the center and expands toward the edges

MEDIAEDITOR_TRANSITION_TYPE_BARNVEE_R 

A 'V' shape extending from the right edge's midpoint to the opposite corners contracts toward the center and expands toward the edges

MEDIAEDITOR_TRANSITION_TYPE_IRIS_RECT 

A rectangle expands from the center.

MEDIAEDITOR_TRANSITION_TYPE_CLOCK_CW12 

A radial hand sweeps clockwise from the twelve o'clock position

MEDIAEDITOR_TRANSITION_TYPE_CLOCK_CW3 

A radial hand sweeps clockwise from the three o'clock position

MEDIAEDITOR_TRANSITION_TYPE_CLOCK_CW6 

A radial hand sweeps clockwise from the six o'clock position

MEDIAEDITOR_TRANSITION_TYPE_CLOCK_CW9 

A radial hand sweeps clockwise from the nine o'clock position

MEDIAEDITOR_TRANSITION_TYPE_PINWHEEL_TBV 

Two radial hands sweep clockwise from the twelve and six o'clock positions

MEDIAEDITOR_TRANSITION_TYPE_PINWHEEL_TBH 

Two radial hands sweep clockwise from the nine and three o'clock positions

MEDIAEDITOR_TRANSITION_TYPE_PINWHEEL_FB 

Four radial hands sweep clockwise

MEDIAEDITOR_TRANSITION_TYPE_FAN_CT 

A fan unfolds from the top edge, the fan axis at the center

MEDIAEDITOR_TRANSITION_TYPE_FAN_CR 

A fan unfolds from the right edge, the fan axis at the center

MEDIAEDITOR_TRANSITION_TYPE_DOUBLEFAN_FOV 

Two fans, their axes at the center, unfold from the top and bottom

MEDIAEDITOR_TRANSITION_TYPE_DOUBLEFAN_FOH 

Two fans, their axes at the center, unfold from the left and right

MEDIAEDITOR_TRANSITION_TYPE_SINGLESWEEP_CWT 

A radial hand sweeps clockwise from the top edge's midpoint

MEDIAEDITOR_TRANSITION_TYPE_SINGLESWEEP_CWR 

A radial hand sweeps clockwise from the right edge's midpoint

MEDIAEDITOR_TRANSITION_TYPE_SINGLESWEEP_CWB 

A radial hand sweeps clockwise from the bottom edge's midpoint

MEDIAEDITOR_TRANSITION_TYPE_SINGLESWEEP_CWL 

A radial hand sweeps clockwise from the left edge's midpoint

MEDIAEDITOR_TRANSITION_TYPE_DOUBLESWEEP_PV 

Two radial hands sweep clockwise and counter-clockwise from the top and bottom edges' midpoints

MEDIAEDITOR_TRANSITION_TYPE_DOUBLESWEEP_PD 

Two radial hands sweep clockwise and counter-clockwise from the left and right edges' midpoints

MEDIAEDITOR_TRANSITION_TYPE_DOUBLESWEEP_OV 

Two radial hands attached at the top and bottom edges' midpoints sweep from right to left

MEDIAEDITOR_TRANSITION_TYPE_DOUBLESWEEP_OH 

Two radial hands attached at the left and right edges' midpoints sweep from top to bottom

MEDIAEDITOR_TRANSITION_TYPE_FAN_T 

A fan unfolds from the bottom, the fan axis at the top edge's midpoint

MEDIAEDITOR_TRANSITION_TYPE_FAN_R 

A fan unfolds from the left, the fan axis at the right edge's midpoint

MEDIAEDITOR_TRANSITION_TYPE_FAN_B 

A fan unfolds from the top, the fan axis at the bottom edge's midpoint

MEDIAEDITOR_TRANSITION_TYPE_FAN_L 

A fan unfolds from the right, the fan axis at the left edge's midpoint

MEDIAEDITOR_TRANSITION_TYPE_DOUBLEFAN_FIV 

Two fans, their axes at the top and bottom, unfold from the center

MEDIAEDITOR_TRANSITION_TYPE_DOUBLEFAN_FIH 

Two fans, their axes at the left and right, unfold from the center

MEDIAEDITOR_TRANSITION_TYPE_SINGLESWEEP_CWTL 

A radial hand sweeps clockwise from the upper-left corner

MEDIAEDITOR_TRANSITION_TYPE_SINGLESWEEP_CCWBL 

A radial hand sweeps counter-clockwise from the lower-left corner

MEDIAEDITOR_TRANSITION_TYPE_SINGLESWEEP_CWBR 

A radial hand sweeps clockwise from the lower-right corner

MEDIAEDITOR_TRANSITION_TYPE_SINGLESWEEP_CCWTR 

A radial hand sweeps counter-clockwise from the upper-right corner

MEDIAEDITOR_TRANSITION_TYPE_DOUBLESWEEP_PDTL 

Two radial hands attached at the upper-left and lower-right corners sweep down and up

MEDIAEDITOR_TRANSITION_TYPE_DOUBLESWEEP_PDBL 

Two radial hands attached at the lower-left and upper-right corners sweep down and up

MEDIAEDITOR_TRANSITION_TYPE_SALOONDOOR_T 

Two radial hands attached at the upper-left and upper-right corners sweep down

MEDIAEDITOR_TRANSITION_TYPE_SALOONDOOR_L 

Two radial hands attached at the upper-left and lower-left corners sweep to the right

MEDIAEDITOR_TRANSITION_TYPE_SALOONDOOR_B 

Two radial hands attached at the lower-left and lower-right corners sweep up

MEDIAEDITOR_TRANSITION_TYPE_SALOONDOOR_R 

Two radial hands attached at the upper-right and lower-right corners sweep to the left

MEDIAEDITOR_TRANSITION_TYPE_WINDSHIELD_R 

Two radial hands attached at the midpoints of the top and bottom halves sweep from right to left

MEDIAEDITOR_TRANSITION_TYPE_WINDSHIELD_U 

Two radial hands attached at the midpoints of the left and right halves sweep from top to bottom

MEDIAEDITOR_TRANSITION_TYPE_WINDSHIELD_V 

Two sets of radial hands attached at the midpoints of the top and bottom halves sweep from top to bottom and bottom to top

MEDIAEDITOR_TRANSITION_TYPE_WINDSHIELD_H 

Two sets of radial hands attached at the midpoints of the left and right halves sweep from left to right and right to left

MEDIAEDITOR_TRANSITION_TYPE_CROSSFADE 

Crossfade


Function Documentation

int mediaeditor_add_effect ( mediaeditor_h  editor,
mediaeditor_effect_type_e  type,
unsigned int  layer_id,
unsigned int  start,
unsigned int  duration,
unsigned int *  effect_id 
)

Adds a new effect.

Since :
7.0
Remarks:
MEDIAEDITOR_EFFECT_AUDIO_TYPE_FADE_IN and MEDIAEDITOR_EFFECT_AUDIO_TYPE_FADE_OUT can not be rolled back using mediaeditor_remove_effect().
Parameters:
[in]editorThe media editor handle
[in]typeThe effect type
[in]layer_idThe layer priority
[in]startThe starting position of effect which is placed in timeline (in milliseconds)
[in]durationThe duration of effect (in milliseconds)
[out]effect_idThe effect ID
Returns:
0 on success, otherwise a negative error value
Return values:
MEDIAEDITOR_ERROR_NONESuccessful
MEDIAEDITOR_ERROR_INVALID_PARAMETERInvalid parameter
MEDIAEDITOR_ERROR_INVALID_OPERATIONInvalid operation
MEDIAEDITOR_ERROR_INVALID_STATEInvalid state
Precondition:
editor state must be set to MEDIAEDITOR_STATE_IDLE.
See also:
mediaeditor_remove_effect()
int mediaeditor_add_transition ( mediaeditor_h  editor,
mediaeditor_transition_type_e  type,
unsigned int  layer_id,
unsigned int  start,
unsigned int  duration 
)

Adds transition effect to the overlapped clip section.

Since :
7.0
Remarks:
Note that clips should be already overlapped. If not, error will be occurred.
Only one transition effect can be applied in the overlapped section.
For each overlapped section, this function should be called to apply transition effect.
Parameters:
[in]editorThe media editor handle
[in]typeThe transition type
[in]layer_idThe layer ID
[in]startThe start position of overlapped clip area to be applied transition effect
[in]durationThe duration of overlapped clip area to be applied transition effect
Returns:
0 on success, otherwise a negative error value
Return values:
MEDIAEDITOR_ERROR_NONESuccessful
MEDIAEDITOR_ERROR_INVALID_PARAMETERInvalid parameter
MEDIAEDITOR_ERROR_INVALID_OPERATIONInvalid operation
MEDIAEDITOR_ERROR_INVALID_STATEInvalid state
Precondition:
editor state must be set to MEDIAEDITOR_STATE_IDLE.
See also:
mediaeditor_add_layer()
mediaeditor_add_clip()
int mediaeditor_remove_effect ( mediaeditor_h  editor,
unsigned int  effect_id 
)

Removes an effect from timeline.

Since :
7.0
Parameters:
[in]editorThe media editor handle
[in]effect_idThe effect ID
Returns:
0 on success, otherwise a negative error value
Return values:
MEDIAEDITOR_ERROR_NONESuccessful
MEDIAEDITOR_ERROR_INVALID_PARAMETERInvalid parameter
MEDIAEDITOR_ERROR_INVALID_OPERATIONInvalid operation
MEDIAEDITOR_ERROR_INVALID_STATEInvalid state
Precondition:
editor state must be set to MEDIAEDITOR_STATE_IDLE.
See also:
mediaeditor_add_effect()