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 ANDROID_FILTERFW_JNI_GL_FRAME_H 18#define ANDROID_FILTERFW_JNI_GL_FRAME_H 19 20#include <jni.h> 21 22#ifdef __cplusplus 23extern "C" { 24#endif 25 26JNIEXPORT jboolean JNICALL 27Java_android_filterfw_core_GLFrame_nativeAllocate(JNIEnv* env, 28 jobject thiz, 29 jobject gl_env, 30 jint width, 31 jint height); 32 33JNIEXPORT jboolean JNICALL 34Java_android_filterfw_core_GLFrame_nativeAllocateWithTexture(JNIEnv* env, 35 jobject thiz, 36 jobject gl_env, 37 jint tex_id, 38 jint width, 39 jint height); 40 41JNIEXPORT jboolean JNICALL 42Java_android_filterfw_core_GLFrame_nativeAllocateWithFbo(JNIEnv* env, 43 jobject thiz, 44 jobject gl_env, 45 jint fbo_id, 46 jint width, 47 jint height); 48 49JNIEXPORT jboolean JNICALL 50Java_android_filterfw_core_GLFrame_nativeAllocateExternal(JNIEnv* env, 51 jobject thiz, 52 jobject gl_env); 53 54JNIEXPORT jboolean JNICALL 55Java_android_filterfw_core_GLFrame_nativeDeallocate(JNIEnv* env, jobject thiz); 56 57JNIEXPORT jboolean JNICALL 58Java_android_filterfw_core_GLFrame_setNativeInts(JNIEnv* env, jobject thiz, jintArray ints); 59 60JNIEXPORT jintArray JNICALL 61Java_android_filterfw_core_GLFrame_getNativeInts(JNIEnv* env, jobject thiz); 62 63JNIEXPORT jboolean JNICALL 64Java_android_filterfw_core_GLFrame_setNativeFloats(JNIEnv* env, jobject thiz, jfloatArray ints); 65 66JNIEXPORT jfloatArray JNICALL 67Java_android_filterfw_core_GLFrame_getNativeFloats(JNIEnv* env, jobject thiz); 68 69JNIEXPORT jboolean JNICALL 70Java_android_filterfw_core_GLFrame_setNativeData(JNIEnv* env, 71 jobject thiz, 72 jbyteArray data, 73 jint offset, 74 jint length); 75 76JNIEXPORT jbyteArray JNICALL 77Java_android_filterfw_core_GLFrame_getNativeData(JNIEnv* env, jobject thiz); 78 79JNIEXPORT jboolean JNICALL 80Java_android_filterfw_core_GLFrame_setNativeBitmap(JNIEnv* env, 81 jobject thiz, 82 jobject bitmap, 83 jint size); 84 85JNIEXPORT jboolean JNICALL 86Java_android_filterfw_core_GLFrame_getNativeBitmap(JNIEnv* env, jobject thiz, jobject bitmap); 87 88JNIEXPORT jboolean JNICALL 89Java_android_filterfw_core_GLFrame_setNativeViewport(JNIEnv* env, 90 jobject thiz, 91 jint x, 92 jint y, 93 jint width, 94 jint height); 95 96JNIEXPORT jint JNICALL 97Java_android_filterfw_core_GLFrame_getNativeTextureId(JNIEnv* env, jobject thiz); 98 99JNIEXPORT jint JNICALL 100Java_android_filterfw_core_GLFrame_getNativeFboId(JNIEnv* env, jobject thiz); 101 102JNIEXPORT jboolean JNICALL 103Java_android_filterfw_core_GLFrame_generateNativeMipMap(JNIEnv* env, jobject thiz); 104 105JNIEXPORT jboolean JNICALL 106Java_android_filterfw_core_GLFrame_setNativeTextureParam(JNIEnv* env, 107 jobject thiz, 108 jint param, 109 jint value); 110 111JNIEXPORT jboolean JNICALL 112Java_android_filterfw_core_GLFrame_nativeResetParams(JNIEnv* env, jobject thiz); 113 114JNIEXPORT jboolean JNICALL 115Java_android_filterfw_core_GLFrame_nativeCopyFromNative(JNIEnv* env, 116 jobject thiz, 117 jobject frame); 118 119JNIEXPORT jboolean JNICALL 120Java_android_filterfw_core_GLFrame_nativeCopyFromGL(JNIEnv* env, 121 jobject thiz, 122 jobject frame); 123 124JNIEXPORT jboolean JNICALL 125Java_android_filterfw_core_GLFrame_nativeFocus(JNIEnv* env, jobject thiz); 126 127JNIEXPORT jboolean JNICALL 128Java_android_filterfw_core_GLFrame_nativeReattachTexToFbo(JNIEnv* env, jobject thiz); 129 130JNIEXPORT jboolean JNICALL 131Java_android_filterfw_core_GLFrame_nativeDetachTexFromFbo(JNIEnv* env, jobject thiz); 132 133#ifdef __cplusplus 134} 135#endif 136 137#endif /* ANDROID_FILTERFW_JNI_GL_FRAME_H */ 138