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 VIDEO_EDITOR_OSAL_H
18#define VIDEO_EDITOR_OSAL_H
19
20#include <jni.h>
21#include <JNIHelp.h>
22
23extern "C" {
24#include <M4OSA_Error.h>
25#include <M4OSA_Thread.h>
26#include <M4OSA_FileReader.h>
27#include <M4OSA_FileWriter.h>
28};
29
30const char*
31videoEditOsal_getResultString(
32                M4OSA_ERR                           result);
33
34void*
35videoEditOsal_alloc(
36                bool*                               pResult,
37                JNIEnv*                             pEnv,
38                size_t                              size,
39                const char*                         pDescription);
40
41void
42videoEditOsal_free(
43                void*                               pData);
44
45void
46videoEditOsal_startThread(
47                bool*                               pResult,
48                JNIEnv*                             pEnv,
49                int                                 stackSize,
50                M4OSA_ThreadDoIt                    callback,
51                M4OSA_Context*                      pContext,
52                void*                               pParam);
53
54void
55videoEditOsal_stopThread(
56                bool*                               pResult,
57                JNIEnv*                             pEnv,
58                M4OSA_Context*                      pContext);
59
60void
61videoEditOsal_getFilePointers ( M4OSA_FileReadPointer *pOsaFileReadPtr,
62                                M4OSA_FileWriterPointer *pOsaFileWritePtr);
63
64#endif // VIDEO_EDITOR_OSAL_H
65
66