/*
* Copyright (C) 2009 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.example.hellojni;
import android.app.Activity;
import android.util.Log;
import android.widget.TextView;
import android.os.Bundle;
public class HelloJni extends Activity
{
/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState)
{
super.onCreate(savedInstanceState);
/* Create a TextView and set its content.
* the text is retrieved by calling a native
* function.
*/
TextView tv = new TextView(this);
tv.setText( stringFromJNI() );
setContentView(tv);
}
public static void transcodeFinishNotify()
{
Log.d("HelloJni","callback---from c++ To java.........\r\n");
Log.d("HelloJni","callback---from c++ To java.........\r\n");
Log.d("HelloJni","callback---from c++ To java.........\r\n");
Log.d("HelloJni","callback---from c++ To java.........\r\n");
Log.d("HelloJni","callback---from c++ To java.........\r\n");
Log.d("HelloJni","callback---from c++ To java.........\r\n");
Log.d("HelloJni","callback---from c++ To java.........\r\n");
}
/* A native method that is implemented by the
* 'hello-jni' native library, which is packaged
* with this application.
*/
public native String stringFromJNI();
/* This is another native method declaration that is *not*
* implemented by 'hello-jni'. This is simply to show that
* you can declare as many native methods in your Java code
* as you want, their implementation is searched in the
* currently loaded native libraries only the first time
* you call them.
*
* Trying to call this function will result in a
* java.lang.UnsatisfiedLinkError exception !
*/
public native String unimplementedStringFromJNI();
/* this is used to load the 'hello-jni' library on application
* startup. The library has already been unpacked into
* /data/data/com.example.hellojni/lib/libhello-jni.so at
* installation time by the package manager.
*/
static {
System.loadLibrary("hello-jni");
}
}
没有合适的资源?快使用搜索试试~ 我知道了~
ndk自带hello-jni工程测试ndk编译ffmpeg2.2的所有so库
共117个文件
h:83个
so:16个
xml:4个
5星 · 超过95%的资源 需积分: 9 53 下载量 78 浏览量
2015-07-01
18:39:55
上传
评论 1
收藏 9.4MB RAR 举报
温馨提示
针对之前有的小伙伴说使用hello-jni测试 NDK-r9编译好的最新的FFmpeg2.2的所有so库和头文件 的时候。在使用cygwin编译jni的时候会报错:”undefined reference to 'avcodec_version'“ 的问题,所以现在把本人在hello-jni的程序弄上来,供大家参考。 对应博客:http://www.cnblogs.com/wainiwann/p/3785485.html#3218685
资源推荐
资源详情
资源评论
收起资源包目录
ndk自带hello-jni工程测试ndk编译ffmpeg2.2的所有so库 (117个子文件)
hello-jni.c 1KB
HelloJniTest.class 672B
BuildConfig.class 361B
.classpath 475B
.classpath 475B
avcodec.h 173KB
avformat.h 94KB
avfilter.h 55KB
opt.h 31KB
pixfmt.h 28KB
frame.h 22KB
intreadwrite.h 18KB
avio.h 17KB
old_pix_fmts.h 14KB
common.h 14KB
mem.h 13KB
avstring.h 12KB
swscale.h 12KB
swresample.h 12KB
old_codec_ids.h 10KB
pixdesc.h 10KB
samplefmt.h 10KB
buffer.h 10KB
log.h 9KB
channel_layout.h 9KB
avdevice.h 9KB
avutil.h 8KB
imgutils.h 8KB
bprint.h 8KB
buffersink.h 7KB
parseutils.h 7KB
dict.h 6KB
vdpau.h 6KB
xvmc.h 6KB
timecode.h 5KB
eval.h 5KB
mathematics.h 5KB
version.h 5KB
buffersrc.h 5KB
error.h 5KB
cpu.h 5KB
fifo.h 5KB
version.h 4KB
audio_fifo.h 4KB
attributes.h 4KB
rational.h 4KB
vda.h 4KB
vaapi.h 4KB
avcodec.h 4KB
stereo3d.h 4KB
version.h 3KB
asrc_abuffer.h 3KB
downmix_info.h 3KB
avfft.h 3KB
bswap.h 3KB
postprocess.h 3KB
hmac.h 3KB
version.h 3KB
crc.h 3KB
timestamp.h 3KB
file.h 2KB
dxva2.h 2KB
blowfish.h 2KB
version.h 2KB
avassert.h 2KB
base64.h 2KB
lzo.h 2KB
sha512.h 2KB
ripemd.h 2KB
lfg.h 2KB
md5.h 2KB
sha.h 2KB
xtea.h 2KB
version.h 2KB
aes.h 2KB
intfloat.h 2KB
version.h 2KB
version.h 2KB
adler32.h 2KB
intfloat_readwrite.h 2KB
random_seed.h 1KB
time.h 1KB
murmur3.h 1KB
macros.h 1KB
avfiltergraph.h 975B
avconfig.h 251B
ffversion.h 119B
audioconvert.h 82B
HelloJni.java 3KB
HelloJniTest.java 655B
BuildConfig.java 168B
Android.mk 2KB
Application.mk 101B
.project 844B
.project 841B
project.properties 563B
project.properties 563B
libavcodec-55.so 7.6MB
libavcodec.so 7.6MB
libavformat-55.so 1.38MB
共 117 条
- 1
- 2
资源评论
- 7865359462015-07-04非常满意,可运行
- telecamera2015-09-16可以运行,但是不能断点调试。
- lianyfan2015-12-20亲测可用,谢谢。
你妹妹丫丫的
- 粉丝: 1
- 资源: 7
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功