M4xVSS_API.h revision b5c7784c96a606890eb8a8b560153ef4a5d1a0d9
1/*
2 * Copyright (C) 2011 The Android Open Source Project
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 *      http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17#ifndef __M4XVSS_API_H__
18#define __M4XVSS_API_H__
19
20#ifdef __cplusplus
21extern "C" {
22#endif
23/**
24 ******************************************************************************
25 * @file    M4xVSS_API.h
26 * @brief    API of Video Studio 2.1
27 * @note
28 ******************************************************************************
29*/
30
31#define M4VSS_SUPPORT_EXTENDED_FEATURES
32
33#include "M4VSS3GPP_API.h"
34#include "M4VSS3GPP_Extended_API.h"
35
36/* Errors codes */
37
38/**
39 * End of analyzing => the user can call M4xVSS_PreviewStart or M4xVSS_SaveStart */
40#define M4VSS3GPP_WAR_ANALYZING_DONE                  M4OSA_ERR_CREATE( M4_WAR, M4VS, 0x0001)
41
42/**
43 * End of preview generating => the user can launch vps to see preview. Once preview is over,
44   the user must call M4xVSS_PreviewStop() to be able to save edited file, or to call another
45   M4xVSS_SendCommand() */
46#define M4VSS3GPP_WAR_PREVIEW_READY                   M4OSA_ERR_CREATE( M4_WAR, M4VS, 0x0002)
47
48/**
49 * End of saved file generation => the user must call M4xVSS_SaveStop() */
50#define M4VSS3GPP_WAR_SAVING_DONE                     M4OSA_ERR_CREATE( M4_WAR, M4VS, 0x0003)
51
52/**
53 * Transcoding is necessary to go further -> if the user does not want to continue,
54  he must call M4xVSS_sendCommand() */
55#define M4VSS3GPP_WAR_TRANSCODING_NECESSARY           M4OSA_ERR_CREATE( M4_WAR, M4VS, 0x0004)
56
57/**
58 * In case of MMS, the output file size won't be reached */
59#define M4VSS3GPP_WAR_OUTPUTFILESIZE_EXCEED           M4OSA_ERR_CREATE( M4_WAR, M4VS, 0x0005)
60
61/**
62 * JPG input file dimensions are too high */
63#define M4VSS3GPP_ERR_JPG_TOO_BIG                     M4OSA_ERR_CREATE( M4_ERR, M4VS, 0x0001)
64
65/**
66 * UTF Conversion, warning on the size of the temporary converted buffer*/
67#define M4xVSSWAR_BUFFER_OUT_TOO_SMALL                M4OSA_ERR_CREATE( M4_WAR, M4VS, 0x0006)
68
69/**
70 * SWIKAR :Error whan NO_MORE_SPACE*/
71#define M4xVSSERR_NO_MORE_SPACE                       M4OSA_ERR_CREATE( M4_ERR, M4VS, 0x0007)
72
73/**
74 ******************************************************************************
75 * enum     M4xVSS_VideoEffectType
76 * @brief   This enumeration defines the video effect types of the xVSS
77 ******************************************************************************
78*/
79typedef enum
80{
81    M4xVSS_kVideoEffectType_BlackAndWhite = M4VSS3GPP_kVideoEffectType_External+1, /* 257 */
82    M4xVSS_kVideoEffectType_Pink,                                                  /* 258 */
83    M4xVSS_kVideoEffectType_Green,                                                 /* 259 */
84    M4xVSS_kVideoEffectType_Sepia,                                                 /* 260 */
85    M4xVSS_kVideoEffectType_Negative,                                              /* 261 */
86    M4xVSS_kVideoEffectType_Framing,                                               /* 262 */
87    M4xVSS_kVideoEffectType_Text, /* Text overlay */                               /* 263 */
88    M4xVSS_kVideoEffectType_ZoomIn,                                                /* 264 */
89    M4xVSS_kVideoEffectType_ZoomOut,                                               /* 265 */
90    M4xVSS_kVideoEffectType_Fifties,                                                /*266 */
91    M4xVSS_kVideoEffectType_ColorRGB16,                                                /*267 */
92    M4xVSS_kVideoEffectType_Gradient                                                /*268*/
93} M4xVSS_VideoEffectType;
94
95/**
96 ******************************************************************************
97 * enum     M4xVSS_VideoTransitionType
98 * @brief   This enumeration defines the video effect that can be applied during a transition.
99 ******************************************************************************
100*/
101typedef enum
102{
103    M4xVSS_kVideoTransitionType_External = M4VSS3GPP_kVideoTransitionType_External, /*256*/
104    M4xVSS_kVideoTransitionType_AlphaMagic,
105    M4xVSS_kVideoTransitionType_SlideTransition,
106    M4xVSS_kVideoTransitionType_FadeBlack
107
108} M4xVSS_VideoTransitionType;
109
110/**
111 ******************************************************************************
112 * struct    M4xVSS_PreviewSettings
113 * @brief    This structure gathers all the information needed by the VPS for preview
114 ******************************************************************************
115*/
116typedef struct
117{
118    M4OSA_Void                                *p3gpPreviewFile;
119    M4OSA_Void                                *pPCMFile;
120    M4VIDEOEDITING_AudioSamplingFrequency    outPCM_ASF;
121    M4OSA_Bool                                bAudioMono;
122    M4VSS3GPP_EffectSettings                   *Effects;
123    M4OSA_UInt8                                nbEffects;
124
125} M4xVSS_PreviewSettings;
126
127/**
128 ******************************************************************************
129 * prototype    M4xVSS_toUTF8Fct
130 * @brief        This prototype defines the function implemented by the integrator
131 *                to convert a string encoded in any format to an UTF8 string.
132 * @note
133 *
134 * @param    pBufferIn        IN            Buffer containing the string to convert to UTF8
135 * @param    pBufferOut        IN            Buffer containing the UTF8 converted string
136 * @param    bufferOutSize    IN/OUT    IN:     Size of the given output buffer
137 *                                    OUT: Size of the converted buffer
138 *
139 ******************************************************************************
140*/
141typedef M4OSA_ERR (*M4xVSS_toUTF8Fct)
142(
143    M4OSA_Void            *pBufferIn,
144    M4OSA_UInt8            *pBufferOut,
145    M4OSA_UInt32        *bufferOutSize
146);
147
148
149/**
150 ******************************************************************************
151 * prototype    M4xVSS_fromUTF8Fct
152 * @brief        This prototype defines the function implemented by the integrator
153 *                to convert an UTF8 string to a string encoded in any format.
154 * @note
155 *
156 * @param    pBufferIn        IN            Buffer containing the UTF8 string to convert
157 *                                        to the desired format.
158 * @param    pBufferOut        IN            Buffer containing the converted string
159 * @param    bufferOutSize    IN/OUT    IN:     Size of the given output buffer
160 *                                    OUT: Size of the converted buffer
161 *
162 ******************************************************************************
163*/
164typedef M4OSA_ERR (*M4xVSS_fromUTF8Fct)
165(
166    M4OSA_UInt8            *pBufferIn,
167    M4OSA_Void            *pBufferOut,
168    M4OSA_UInt32        *bufferOutSize
169);
170
171
172
173
174/**
175 ******************************************************************************
176 * struct    M4xVSS_InitParams
177 * @brief    This structure defines parameters for xVSS.
178 * @note
179 ******************************************************************************
180*/
181typedef struct
182{
183    M4OSA_FileReadPointer*            pFileReadPtr;
184    M4OSA_FileWriterPointer*        pFileWritePtr;
185    M4OSA_Void*                        pTempPath;
186    /*Function pointer on an external text conversion function */
187    M4xVSS_toUTF8Fct                pConvToUTF8Fct;
188    /*Function pointer on an external text conversion function */
189    M4xVSS_fromUTF8Fct                pConvFromUTF8Fct;
190
191
192
193} M4xVSS_InitParams;
194
195/**
196 ******************************************************************************
197 * prototype    M4xVSS_Init
198 * @brief        This function initializes the xVSS
199 * @note        Initializes the xVSS edit operation (allocates an execution context).
200 *
201 * @param    pContext            (OUT) Pointer on the xVSS edit context to allocate
202 * @param    params                (IN) Parameters mandatory for xVSS
203 * @return    M4NO_ERROR:            No error
204 * @return    M4ERR_PARAMETER:    At least one parameter is M4OSA_NULL
205 * @return    M4ERR_ALLOC:        Memory allocation has failed
206 ******************************************************************************
207*/
208M4OSA_ERR M4xVSS_Init(M4OSA_Context* pContext, M4xVSS_InitParams* params);
209
210/**
211 ******************************************************************************
212 * prototype    M4xVSS_ReduceTranscode
213 * @brief        This function changes the given editing structure in order to
214 *                minimize the transcoding time.
215 * @note        The xVSS analyses this structure, and if needed, changes the
216 *                output parameters (Video codec, video size, audio codec,
217 *                audio nb of channels) to minimize the transcoding time.
218 *
219 * @param    pContext            (OUT) Pointer on the xVSS edit context to allocate
220 * @param    pSettings            (IN) Edition settings (allocated by the user)
221 * @return    M4NO_ERROR:            No error
222 * @return    M4ERR_PARAMETER:    At least one parameter is M4OSA_NULL
223 * @return    M4ERR_ALLOC:        Memory allocation has failed
224 * @return    M4ERR_STATE:        This function cannot not be called at this time
225 ******************************************************************************
226*/
227M4OSA_ERR M4xVSS_ReduceTranscode(M4OSA_Context pContext, M4VSS3GPP_EditSettings* pSettings);
228
229/**
230 ******************************************************************************
231 * prototype    M4xVSS_SendCommand
232 * @brief        This function gives to the xVSS an editing structure
233 * @note        The xVSS analyses this structure, and prepare edition
234 *                This function must be called after M4xVSS_Init, after
235 *                M4xVSS_CloseCommand, or after M4xVSS_PreviewStop.
236 *                After this function, the user must call M4xVSS_Step until
237 *                it returns another error than M4NO_ERROR.
238 *
239 * @param    pContext            (IN) Pointer on the xVSS edit context
240 * @param    pSettings            (IN) Edition settings (allocated by the user)
241 * @return    M4NO_ERROR:            No error
242 * @return    M4ERR_PARAMETER:    At least one parameter is M4OSA_NULL
243 * @return    M4ERR_ALLOC:        Memory allocation has failed
244 * @return    M4ERR_STATE:        This function cannot not be called at this time
245 ******************************************************************************
246*/
247M4OSA_ERR M4xVSS_SendCommand(M4OSA_Context pContext, M4VSS3GPP_EditSettings* pSettings);
248
249/**
250 ******************************************************************************
251 * prototype    M4xVSS_PreviewStart
252 * @brief        This function prepare the preview
253 * @note        The xVSS create 3GP preview file and fill pPreviewSettings with
254 *                preview parameters.
255 *                This function must be called once M4xVSS_Step has returned
256 *                M4VSS3GPP_WAR_ANALYZING_DONE
257 *                After this function, the user must call M4xVSS_Step until
258 *                it returns another error than M4NO_ERROR.
259 *
260 * @param    pContext            (IN) Pointer on the xVSS edit context
261 * @param    pPreviewSettings    (IN) Preview settings (allocated by the user)
262 * @return    M4NO_ERROR:            No error
263 * @return    M4ERR_PARAMETER:    At least one parameter is M4OSA_NULL
264 * @return    M4ERR_ALLOC:        Memory allocation has failed
265 * @return    M4ERR_STATE:        This function cannot not be called at this time
266 ******************************************************************************
267*/
268M4OSA_ERR M4xVSS_PreviewStart(M4OSA_Context pContext, M4xVSS_PreviewSettings* pPreviewSettings);
269
270/**
271 ******************************************************************************
272 * prototype    M4xVSS_PreviewStop
273 * @brief        This function unallocate preview ressources and change xVSS
274 *                internal state to allow saving or resend an editing command
275 * @note        This function must be called once M4xVSS_Step has returned
276 *                M4VSS3GPP_WAR_PREVIEW_READY
277 *
278 * @param    pContext            (IN) Pointer on the xVSS edit context
279 * @return    M4NO_ERROR:            No error
280 * @return    M4ERR_PARAMETER:    At least one parameter is M4OSA_NULL
281 * @return    M4ERR_STATE:        This function cannot not be called at this time
282 ******************************************************************************
283*/
284M4OSA_ERR M4xVSS_PreviewStop(M4OSA_Context pContext);
285
286/**
287 ******************************************************************************
288 * prototype    M4xVSS_SaveStart
289 * @brief        This function prepare the save
290 * @note        The xVSS create 3GP edited final file
291 *                This function must be called once M4xVSS_Step has returned
292 *                M4VSS3GPP_WAR_ANALYZING_DONE
293 *                After this function, the user must call M4xVSS_Step until
294 *                it returns another error than M4NO_ERROR.
295 *
296 * @param    pContext            (IN) Pointer on the xVSS edit context
297 * @param    pFilePath            (IN) If the user wants to provide a different
298 *                                output filename, else can be NULL (allocated by the user)
299 * @return    M4NO_ERROR:            No error
300 * @return    M4ERR_PARAMETER:    At least one parameter is M4OSA_NULL
301 * @return    M4ERR_ALLOC:        Memory allocation has failed
302 * @return    M4ERR_STATE:        This function cannot not be called at this time
303 ******************************************************************************
304*/
305M4OSA_ERR M4xVSS_SaveStart(M4OSA_Context pContext, M4OSA_Void* pFilePath,
306                            M4OSA_UInt32 filePathSize);
307
308/**
309 ******************************************************************************
310 * prototype    M4xVSS_SaveStop
311 * @brief        This function unallocate save ressources and change xVSS
312 *                internal state.
313 * @note        This function must be called once M4xVSS_Step has returned
314 *                M4VSS3GPP_WAR_SAVING_DONE
315 *
316 * @param    pContext            (IN) Pointer on the xVSS edit context
317 * @return    M4NO_ERROR:            No error
318 * @return    M4ERR_PARAMETER:    At least one parameter is M4OSA_NULL
319 * @return    M4ERR_STATE:        This function cannot not be called at this time
320 ******************************************************************************
321*/
322M4OSA_ERR M4xVSS_SaveStop(M4OSA_Context pContext);
323
324/**
325 ******************************************************************************
326 * prototype    M4xVSS_Step
327 * @brief        This function executes differents tasks, depending of xVSS
328 *                internal state.
329 * @note        This function:
330 *                    - analyses editing structure if called after M4xVSS_SendCommand
331 *                    - generates preview file if called after M4xVSS_PreviewStart
332 *                    - generates final edited file if called after M4xVSS_SaveStart
333 *
334 * @param    pContext                        (IN) Pointer on the xVSS edit context
335 * @param    pContext                        (OUT) Progress indication from 0 to 100
336 * @return    M4NO_ERROR:                        No error, the user must call M4xVSS_Step again
337 * @return    M4ERR_PARAMETER:                At least one parameter is M4OSA_NULL
338 * @return    M4ERR_STATE:                    This function cannot not be called at this time
339 * @return    M4VSS3GPP_WAR_PREVIEW_READY:    Preview file is generated
340 * @return    M4VSS3GPP_WAR_SAVING_DONE:        Final edited file is generated
341 * @return    M4VSS3GPP_WAR_ANALYZING_DONE:    Analyse is done
342 ******************************************************************************
343*/
344M4OSA_ERR M4xVSS_Step(M4OSA_Context pContext, M4OSA_UInt8 *pProgress);
345
346/**
347 ******************************************************************************
348 * prototype    M4xVSS_CloseCommand
349 * @brief        This function deletes current editing profile, unallocate
350 *                ressources and change xVSS internal state.
351 * @note        After this function, the user can call a new M4xVSS_SendCommand
352 *
353 * @param    pContext            (IN) Pointer on the xVSS edit context
354 * @return    M4NO_ERROR:            No error
355 * @return    M4ERR_PARAMETER:    At least one parameter is M4OSA_NULL
356 * @return    M4ERR_STATE:        This function cannot not be called at this time
357 ******************************************************************************
358*/
359M4OSA_ERR M4xVSS_CloseCommand(M4OSA_Context pContext);
360
361/**
362 ******************************************************************************
363 * prototype    M4xVSS_CleanUp
364 * @brief        This function deletes all xVSS ressources
365 * @note        This function must be called after M4xVSS_CloseCommand.
366 *
367 * @param    pContext            (IN) Pointer on the xVSS edit context
368 * @return    M4NO_ERROR:            No error
369 * @return    M4ERR_PARAMETER:    At least one parameter is M4OSA_NULL
370 * @return    M4ERR_STATE:        This function cannot not be called at this time
371 ******************************************************************************
372*/
373M4OSA_ERR M4xVSS_CleanUp(M4OSA_Context pContext);
374
375/**
376 ******************************************************************************
377 * prototype    M4xVSS_GetVersion(M4_VersionInfo *pVersion)
378 * @brief        This function get the version of the Video Studio 2.1
379 *
380 * @param    pVersion            (IN) Pointer on the version info struct
381 * @return    M4NO_ERROR:            No error
382 * @return    M4ERR_PARAMETER:    At least one parameter is M4OSA_NULL
383 ******************************************************************************
384*/
385M4OSA_ERR M4xVSS_GetVersion(M4_VersionInfo *pVersion);
386
387/**
388 ******************************************************************************
389 * prototype    M4VSS3GPP_externalVideoEffectColor(M4OSA_Void *pFunctionContext,
390 *                                                    M4VIFI_ImagePlane *PlaneIn,
391 *                                                    M4VIFI_ImagePlane *PlaneOut,
392 *                                                    M4VSS3GPP_ExternalProgress *pProgress,
393 *                                                    M4OSA_UInt32 uiEffectKind)
394 *
395 * @brief    This function apply a color effect on an input YUV420 planar frame
396 * @note    The prototype of this effect function is exposed because it needs to
397 *            called by the VPS during the preview
398 * @param    pFunctionContext(IN) Contains which color to apply (not very clean ...)
399 * @param    PlaneIn            (IN) Input YUV420 planar
400 * @param    PlaneOut        (IN/OUT) Output YUV420 planar
401 * @param    pProgress        (IN/OUT) Progress indication (0-100)
402 * @param    uiEffectKind    (IN) Unused
403 *
404 * @return    M4VIFI_OK:    No error
405 ******************************************************************************
406*/
407M4OSA_ERR M4VSS3GPP_externalVideoEffectColor
408(
409    M4OSA_Void *pFunctionContext,
410    M4VIFI_ImagePlane *pInputPlanes,
411    M4VIFI_ImagePlane *pOutputPlanes,
412    M4VSS3GPP_ExternalProgress *pProgress,
413    M4OSA_UInt32 uiEffectKind
414);
415
416/**
417 ******************************************************************************
418 * prototype    M4VSS3GPP_externalVideoEffectFraming(M4OSA_Void *pFunctionContext,
419 *                                                    M4VIFI_ImagePlane *PlaneIn,
420 *                                                    M4VIFI_ImagePlane *PlaneOut,
421 *                                                    M4VSS3GPP_ExternalProgress *pProgress,
422 *                                                    M4OSA_UInt32 uiEffectKind)
423 *
424 * @brief    This function add a fixed or animated image on an input YUV420 planar frame
425 * @note    The prototype of this effect function is exposed because it needs to
426 *            called by the VPS during the preview
427 * @param    pFunctionContext(IN) Contains which color to apply (not very clean ...)
428 * @param    PlaneIn            (IN) Input YUV420 planar
429 * @param    PlaneOut        (IN/OUT) Output YUV420 planar
430 * @param    pProgress        (IN/OUT) Progress indication (0-100)
431 * @param    uiEffectKind    (IN) Unused
432 *
433 * @return    M4VIFI_OK:    No error
434 ******************************************************************************
435*/
436M4OSA_ERR M4VSS3GPP_externalVideoEffectFraming
437(
438    M4OSA_Void *pFunctionContext,
439    M4VIFI_ImagePlane *pInputPlanes,
440    M4VIFI_ImagePlane *pOutputPlanes,
441    M4VSS3GPP_ExternalProgress *pProgress,
442    M4OSA_UInt32 uiEffectKind
443);
444
445/**
446 ******************************************************************************
447 * prototype    M4VSS3GPP_externalVideoEffectFifties(M4OSA_Void *pFunctionContext,
448 *                                                    M4VIFI_ImagePlane *PlaneIn,
449 *                                                    M4VIFI_ImagePlane *PlaneOut,
450 *                                                    M4VSS3GPP_ExternalProgress *pProgress,
451 *                                                    M4OSA_UInt32 uiEffectKind)
452 *
453 * @brief    This function make a video look as if it was taken in the fifties
454 * @note
455 * @param    pUserData       (IN) Context
456 * @param    pPlaneIn        (IN) Input YUV420 planar
457 * @param    pPlaneOut        (IN/OUT) Output YUV420 planar
458 * @param    pProgress        (IN/OUT) Progress indication (0-100)
459 * @param    uiEffectKind    (IN) Unused
460 *
461 * @return    M4VIFI_OK:            No error
462 * @return  M4ERR_PARAMETER:    pFiftiesData, pPlaneOut or pProgress are NULL (DEBUG only)
463 ******************************************************************************
464*/
465M4OSA_ERR M4VSS3GPP_externalVideoEffectFifties
466(
467    M4OSA_Void *pUserData,
468    M4VIFI_ImagePlane *pInputPlanes,
469    M4VIFI_ImagePlane *pPlaneOut,
470    M4VSS3GPP_ExternalProgress *pProgress,
471    M4OSA_UInt32 uiEffectKind
472);
473
474
475/**
476 ******************************************************************************
477 * prototype    M4VSS3GPP_externalVideoEffectZoom(M4OSA_Void *pFunctionContext,
478 *                                                    M4VIFI_ImagePlane *PlaneIn,
479 *                                                    M4VIFI_ImagePlane *PlaneOut,
480 *                                                    M4VSS3GPP_ExternalProgress *pProgress,
481 *                                                    M4OSA_UInt32 uiEffectKind)
482 *
483 * @brief    This function add a fixed or animated image on an input YUV420 planar frame
484 * @note    The prototype of this effect function is exposed because it needs to
485 *            called by the VPS during the preview
486 * @param    pFunctionContext(IN) Contains which zoom to apply (In/Out)
487 * @param    PlaneIn            (IN) Input YUV420 planar
488 * @param    PlaneOut        (IN/OUT) Output YUV420 planar
489 * @param    pProgress        (IN/OUT) Progress indication (0-100)
490 * @param    uiEffectKind    (IN) Unused
491 *
492 * @return    M4VIFI_OK:    No error
493 ******************************************************************************
494*/
495M4OSA_ERR M4VSS3GPP_externalVideoEffectZoom
496(
497    M4OSA_Void *pFunctionContext,
498    M4VIFI_ImagePlane *pInputPlanes,
499    M4VIFI_ImagePlane *pOutputPlanes,
500    M4VSS3GPP_ExternalProgress *pProgress,
501    M4OSA_UInt32 uiEffectKind
502);
503
504/**
505 ******************************************************************************
506 * M4OSA_ERR M4xVSS_CreateClipSettings()
507 * @brief    Allows filling a clip settings structure with default values
508 *
509 * @note    WARNING: pClipSettings->Effects[ ] will be allocated in this function.
510 *                   pClipSettings->pFile      will be allocated in this function.
511 *
512 * @param    pClipSettings        (IN) Pointer to a valid M4VSS3GPP_ClipSettings structure
513 * @param   pFile               (IN) Clip file name
514 * @param   filePathSize        (IN) Size of the clip path (needed for the UTF16 conversion)
515 * @param    nbEffects           (IN) Nb of effect settings to allocate
516 * @return    M4NO_ERROR:            No error
517 * @return    M4ERR_PARAMETER:    pClipSettings is M4OSA_NULL (debug only)
518 ******************************************************************************
519*/
520M4OSA_ERR M4xVSS_CreateClipSettings(M4VSS3GPP_ClipSettings *pClipSettings, M4OSA_Void* pFile,
521                                    M4OSA_UInt32 filePathSize, M4OSA_UInt8 nbEffects);
522
523/**
524 ******************************************************************************
525 * M4OSA_ERR M4xVSS_DuplicateClipSettings()
526 * @brief    Duplicates a clip settings structure, performing allocations if required
527 *
528 * @param    pClipSettingsDest    (IN) Pointer to a valid M4VSS3GPP_ClipSettings structure
529 * @param    pClipSettingsOrig    (IN) Pointer to a valid M4VSS3GPP_ClipSettings structure
530 * @param   bCopyEffects        (IN) Flag to know if we have to duplicate effects
531 * @return    M4NO_ERROR:            No error
532 * @return    M4ERR_PARAMETER:    pClipSettings is M4OSA_NULL (debug only)
533 ******************************************************************************
534*/
535M4OSA_ERR M4xVSS_DuplicateClipSettings(M4VSS3GPP_ClipSettings *pClipSettingsDest,
536                                         M4VSS3GPP_ClipSettings *pClipSettingsOrig,
537                                         M4OSA_Bool bCopyEffects);
538
539/**
540 ******************************************************************************
541 * M4OSA_ERR M4xVSS_FreeClipSettings()
542 * @brief    Free the pointers allocated in the ClipSetting structure (pFile, Effects).
543 *
544 * @param    pClipSettings        (IN) Pointer to a valid M4VSS3GPP_ClipSettings structure
545 * @return    M4NO_ERROR:            No error
546 * @return    M4ERR_PARAMETER:    pClipSettings is M4OSA_NULL (debug only)
547 ******************************************************************************
548*/
549M4OSA_ERR M4xVSS_FreeClipSettings(M4VSS3GPP_ClipSettings *pClipSettings);
550
551/**
552 ******************************************************************************
553 * prototype    M4OSA_ERR M4xVSS_getMCSContext(M4OSA_Context pContext, M4OSA_Context* mcsContext)
554 * @brief        This function returns the MCS context within the xVSS internal context
555 * @note        This function must be called only after VSS state has moved to analyzing state
556 *                or beyond
557 *
558 * @param    pContext            (IN) Pointer on the xVSS edit context
559 * @param    mcsContext        (OUT) Pointer to pointer of mcs context to return
560 * @return    M4NO_ERROR:        No error
561 * @return    M4ERR_PARAMETER:    At least one parameter is M4OSA_NULL
562 * @return    M4ERR_STATE:        This function cannot not be called at this time
563 ******************************************************************************
564*/
565M4OSA_ERR M4xVSS_getMCSContext(M4OSA_Context pContext, M4OSA_Context* mcsContext);
566
567/**
568 ******************************************************************************
569 * prototype    M4OSA_ERR M4xVSS_getVSS3GPPContext(M4OSA_Context pContext,
570 *                                                     M4OSA_Context* mcsContext)
571 * @brief        This function returns the VSS3GPP context within the xVSS internal context
572 * @note        This function must be called only after VSS state has moved to Generating
573 *                preview or beyond
574 *
575 * @param    pContext            (IN) Pointer on the xVSS edit context
576 * @param    vss3gppContext        (OUT) Pointer to pointer of vss3gpp context to return
577 * @return    M4NO_ERROR:        No error
578 * @return    M4ERR_PARAMETER:    At least one parameter is M4OSA_NULL
579 * @return    M4ERR_STATE:        This function cannot not be called at this time
580 ******************************************************************************
581*/
582M4OSA_ERR M4xVSS_getVSS3GPPContext(M4OSA_Context pContext, M4OSA_Context* vss3gppContext);
583
584#ifdef __cplusplus
585}
586#endif /* __cplusplus */
587#endif /* __M4XVSS_API_H__ */
588
589