Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
FFmpeg using with NDK
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  Messages 1 - 25 of 35 - Collapse all  -  Translate all to Translated (View all originals)   Newer >
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
baris atbas  
View profile  
 More options Dec 30 2010, 10:49 am
From: baris atbas <barisat...@gmail.com>
Date: Thu, 30 Dec 2010 07:49:28 -0800 (PST)
Local: Thurs, Dec 30 2010 10:49 am
Subject: FFmpeg using with NDK
Hi everyone,

I have a little knowledege about android ndk.  In my application, I
will use FFmpeg library.

I am able to configure FFmpeg library and create the libffmpeg.so  by
the following link  :

http://androidcore.com/android-programming-tutorials/641-how-to-compi...

In my jni folder, I have ffmpeg library , Android.mk , FFmpegTest.c .

I made some changes in Android.mk after some research about ndk. but I
couldnt compile the test code with ndk. I think Android.mk file is
wrong. here is my android.mk

LOCAL_PATH := $(call my-dir)
include $(CLEAR_VARS)

LOCAL_MODULE    := ffmpg
LOCAL_SRC_FILES := ffmpegTest.c
LOCAL_LDLIBS := -libffmpeg
include $(BUILD_SHARED_LIBRARY)

I will be so glad, if you give some example codes about android.mk and
ffmpeg. I created the .a and .so files but I couldn't use them. I only
need main Android.mk and test code using ffmpeg library.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
alan  
View profile  
 More options Dec 31 2010, 4:21 am
From: alan <a...@birtles.org.uk>
Date: Fri, 31 Dec 2010 01:21:12 -0800 (PST)
Local: Fri, Dec 31 2010 4:21 am
Subject: Re: FFmpeg using with NDK
"I couldnt compile the test code with ndk" isn't very useful, what is
the exact problem you are having? what error messages are displayed

On Dec 30, 3:49 pm, baris atbas <barisat...@gmail.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
baris atbas  
View profile  
 More options Dec 31 2010, 4:58 am
From: baris atbas <barisat...@gmail.com>
Date: Fri, 31 Dec 2010 01:58:11 -0800 (PST)
Local: Fri, Dec 31 2010 4:58 am
Subject: Re: FFmpeg using with NDK
baris@ubuntu:~/workspace/FFmpegTest$ /home/baris/ndk/ndk-build
Install        : libffmpeg.so => /home/baris/workspace/FFmpegTest/libs/
armeabi
make: *** No rule to make target `/home/baris/workspace/FFmpegTest/jni/
ffmpeg/libswscale/FFmpegTest.c', needed by `/home/baris/workspace/
FFmpegTest/obj/local/armeabi/objs/ffmpg/FFmpegTest.o'.  Stop.
baris@ubuntu:~/workspace/FFmpegTest$

it is the error. I think ndk is searching my native code in wrong
place.

LOCAL_PATH := $(call my-dir)
include $(all-subdir-makefiles)
include $(CLEAR_VARS)
LOCAL_MODULE    := ffmpg
LOCAL_SRC_FILES := FFmpegTest.c
LOCAL_LDLIBS := -libffmpeg
include $(BUILD_SHARED_LIBRARY)

it is the Android.mk

here is my native code. I found this code in a webpage and configured
according to my project.

#include <ffmpeg/avcodec.h>
#include <ffmpeg/avformat.h>

#include <stdio.h>

void SaveFrame(AVFrame *pFrame, int width, int height, int iFrame) {
  FILE *pFile;
  char szFilename[32];
  int  y;

  // Open file
  sprintf(szFilename, "frame%d.ppm", iFrame);
  pFile=fopen(szFilename, "wb");
  if(pFile==NULL)
    return;

  // Write header
  fprintf(pFile, "P6\n%d %d\n255\n", width, height);

  // Write pixel data
  for(y=0; y<height; y++)
    fwrite(pFrame->data[0]+y*pFrame->linesize[0], 1, width*3, pFile);

  // Close file
  fclose(pFile);

}

jint Java_com_test_Test_decodeVideo(JNIEnv* env, jobject
javaThis,jstring filename) {
  AVFormatContext *pFormatCtx;
  int             i, videoStream;
  AVCodecContext  *pCodecCtx;
  AVCodec         *pCodec;
  AVFrame         *pFrame;
  AVFrame         *pFrameRGB;
  AVPacket        packet;
  int             frameFinished;
  int             numBytes;
  uint8_t         *buffer;

  // Register all formats and codecs
  av_register_all();

  // Open video file
  if(av_open_input_file(&pFormatCtx, filename, NULL, 0, NULL)!=0)
    return -1; // Couldn't open file

  // Retrieve stream information
  if(av_find_stream_info(pFormatCtx)<0)
    return -1; // Couldn't find stream information

  // Dump information about file onto standard error
  dump_format(pFormatCtx, 0, filename, 0);

  // Find the first video stream
  videoStream=-1;
  for(i=0; i<pFormatCtx->nb_streams; i++)
    if(pFormatCtx->streams[i]->codec->codec_type==CODEC_TYPE_VIDEO) {
      videoStream=i;
      break;
    }
  if(videoStream==-1)
    return -1; // Didn't find a video stream

  // Get a pointer to the codec context for the video stream
  pCodecCtx=pFormatCtx->streams[videoStream]->codec;

  // Find the decoder for the video stream
  pCodec=avcodec_find_decoder(pCodecCtx->codec_id);
  if(pCodec==NULL) {
    fprintf(stderr, "Unsupported codec!\n");
    return -1; // Codec not found
  }
  // Open codec
  if(avcodec_open(pCodecCtx, pCodec)<0)
    return -1; // Could not open codec

  // Allocate video frame
  pFrame=avcodec_alloc_frame();

  // Allocate an AVFrame structure
  pFrameRGB=avcodec_alloc_frame();
  if(pFrameRGB==NULL)
    return -1;

  // Determine required buffer size and allocate buffer
  numBytes=avpicture_get_size(PIX_FMT_RGB24, pCodecCtx->width,
                              pCodecCtx->height);
  buffer=(uint8_t *)av_malloc(numBytes*sizeof(uint8_t));

  // Assign appropriate parts of buffer to image planes in pFrameRGB
  // Note that pFrameRGB is an AVFrame, but AVFrame is a superset
  // of AVPicture
  avpicture_fill((AVPicture *)pFrameRGB, buffer, PIX_FMT_RGB24,
                 pCodecCtx->width, pCodecCtx->height);

  // Read frames and save first five frames to disk
  i=0;
  while(av_read_frame(pFormatCtx, &packet)>=0) {
    // Is this a packet from the video stream?
    if(packet.stream_index==videoStream) {
      // Decode video frame
      avcodec_decode_video(pCodecCtx, pFrame, &frameFinished,
                           packet.data, packet.size);

      // Did we get a video frame?
      if(frameFinished) {
        // Convert the image from its native format to RGB
        img_convert((AVPicture *)pFrameRGB, PIX_FMT_RGB24,
                    (AVPicture*)pFrame, pCodecCtx->pix_fmt, pCodecCtx-

>width,

                    pCodecCtx->height);

        // Save the frame to phone memory

         SaveFrame(pFrameRGB, pCodecCtx->width, pCodecCtx->height, ++i);
      }
    }

    // Free the packet that was allocated by av_read_frame
    av_free_packet(&packet);
  }

  // Free the RGB image
  av_free(buffer);
  av_free(pFrameRGB);

  // Free the YUV frame
  av_free(pFrame);

  // Close the codec
  avcodec_close(pCodecCtx);

  // Close the video file
  av_close_input_file(pFormatCtx);

  return 0;

}

On 31 Aralık, 11:21, alan <a...@birtles.org.uk> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
David Turner  
View profile  
 More options Dec 31 2010, 5:17 am
From: David Turner <di...@android.com>
Date: Fri, 31 Dec 2010 11:17:35 +0100
Local: Fri, Dec 31 2010 5:17 am
Subject: Re: FFmpeg using with NDK

Try putting the include all-subdir-makefiles at the end of your Android.mk,
otherwise LOCAL_PATH will be redefined to a different value and your later
module declaration will not find the sources in the correct location.

See the description of the my-dir function in docs/ANDROID-MK.html for more
details


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
baris atbas  
View profile  
 More options Dec 31 2010, 5:30 am
From: baris atbas <barisat...@gmail.com>
Date: Fri, 31 Dec 2010 02:30:39 -0800 (PST)
Local: Fri, Dec 31 2010 5:30 am
Subject: Re: FFmpeg using with NDK
baris@ubuntu:~/workspace/FFmpegTest$ /home/baris/ndk/ndk-build
make: *** No rule to make target `/FFmpegTest.c', needed by `/home/
baris/workspace/FFmpegTest/obj/local/armeabi/objs/ffmpg/
FFmpegTest.o'.  Stop.

I got this error when I put the include all-subdir-makefiles at the
end of my Android.mk  ...

On 31 Aralık, 12:17, David Turner <di...@android.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
David Turner  
View profile  
 More options Dec 31 2010, 5:48 am
From: David Turner <di...@android.com>
Date: Fri, 31 Dec 2010 11:48:34 +0100
Local: Fri, Dec 31 2010 5:48 am
Subject: Re: FFmpeg using with NDK

It looks like your LOCAL_PATH is not defined. Did you keep the "LOCAL_PATH
:= $(call my-dir)" line at the top of your Android.mk ?


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
baris atbas  
View profile  
 More options Dec 31 2010, 5:55 am
From: baris atbas <barisat...@gmail.com>
Date: Fri, 31 Dec 2010 02:55:05 -0800 (PST)
Local: Fri, Dec 31 2010 5:55 am
Subject: Re: FFmpeg using with NDK
yes, I only changed the location of include all subdir files command.

LOCAL_PATH := $(call my-dir)
include $(CLEAR_VARS)
LOCAL_MODULE    := ffmpg
LOCAL_SRC_FILES := FFmpegTest.c
LOCAL_LDLIBS := -libffmpeg
include $(BUILD_SHARED_LIBRARY)
include $(all-subdir-makefiles)

On 31 Aralık, 12:48, David Turner <di...@android.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
David Turner  
View profile  
 More options Dec 31 2010, 6:26 am
From: David Turner <di...@android.com>
Date: Fri, 31 Dec 2010 12:26:27 +0100
Local: Fri, Dec 31 2010 6:26 am
Subject: Re: FFmpeg using with NDK

mmm, can you try a "ndk-build clean" first then try to build again. It might
be related to a bad dependency file that was generated on a previous pass.

...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
baris atbas  
View profile  
 More options Dec 31 2010, 6:41 am
From: baris atbas <barisat...@gmail.com>
Date: Fri, 31 Dec 2010 03:41:30 -0800 (PST)
Local: Fri, Dec 31 2010 6:41 am
Subject: Re: FFmpeg using with NDK
I got this errors. Files that compiler couldnt find exist in the
ffmpeg folder.

baris@ubuntu:~/workspace/FFmpegTest$ /home/baris/ndk/ndk-build
Compile thumb  : ffmpg <= /home/baris/workspace/FFmpegTest/jni/
FFmpegTest.c
In file included from /home/baris/workspace/FFmpegTest/jni/
FFmpegTest.c:1:
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:
30:33: error: libavcore/samplefmt.h: No such file or directory
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:
31:30: error: libavutil/avutil.h: No such file or directory
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:
32:27: error: libavutil/cpu.h: No such file or directory
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:
437:36: error: libavcore/audioconvert.h: No such file or directory
In file included from /home/baris/workspace/FFmpegTest/jni/
FFmpegTest.c:1:
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:779:
error: expected specifier-qualifier-list before 'int16_t'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:1048:
error: expected specifier-qualifier-list before 'int64_t'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:1102:
error: expected specifier-qualifier-list before 'uint8_t'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:1117:
error: expected ':', ',', ';', '}' or '__attribute__' before '*' token
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:2801:
error: field 'type' has incomplete type
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:2805:
error: expected declaration specifiers or '...' before 'uint8_t'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:2819:
error: expected ':', ',', ';', '}' or '__attribute__' before '*' token
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:2849:
error: field 'type' has incomplete type
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:2863:
error: field 'pix_fmt' has incomplete type
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:2887:
error: expected ';', ',' or ')' before '*' token
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:2900:
error: expected ';' before 'int'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:2928:
error: expected specifier-qualifier-list before 'uint8_t'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:2955:
error: expected '=', ',', ';', 'asm' or '__attribute__' before
'attribute_deprecated'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3001:
error: expected specifier-qualifier-list before 'uint16_t'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3014:
error: expected '=', ',', ';', 'asm' or '__attribute__' before 'void'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3078:
error: expected '=', ',', ';', 'asm' or '__attribute__' before
'ReSampleContext'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3102:
warning: 'enum AVSampleFormat' declared inside parameter list
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3102:
warning: its scope is only this definition or declaration, which is
probably not what you want
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3181:
error: expected declaration specifiers or '...' before 'uint8_t'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3217:
error: expected '=', ',', ';', 'asm' or '__attribute__' before 'enum'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3234:
error: expected '=', ',', ';', 'asm' or '__attribute__' before
'av_get_codec_tag_string'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3285:
error: expected ')' before 'pix_fmt_mask'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3293:
error: expected '=', ',', ';', 'asm' or '__attribute__' before 'void'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3347:
error: expected '=', ',', ';', 'asm' or '__attribute__' before 'void'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3490:
error: expected '=', ',', ';', 'asm' or '__attribute__' before 'int'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3544:
error: expected '=', ',', ';', 'asm' or '__attribute__' before 'int'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3588:
error: expected declaration specifiers or '...' before 'int16_t'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3606:
error: expected '=', ',', ';', 'asm' or '__attribute__' before 'int'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3659:
error: expected '=', ',', ';', 'asm' or '__attribute__' before 'int'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3691:
error: expected declaration specifiers or '...' before 'uint8_t'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3693:
error: expected declaration specifiers or '...' before 'uint8_t'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3714:
error: expected declaration specifiers or '...' before 'uint8_t'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3729:
error: expected declaration specifiers or '...' before 'uint8_t'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3731:
error: expected declaration specifiers or '...' before 'uint8_t'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3778:
error: expected '=', ',', ';', 'asm' or '__attribute__' before 'int'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3785:
error: expected specifier-qualifier-list before 'int64_t'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3916:
error: expected ';', ',' or ')' before '*' token
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3918:
error: expected ';' before 'void'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3930:
error: expected '=', ',', ';', 'asm' or '__attribute__' before 'int'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3967:
error: expected declaration specifiers or '...' before 'uint8_t'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3968:
error: expected ';', ',' or ')' before '*' token
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3974:
error: expected declaration specifiers or '...' before 'uint8_t'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3975:
error: expected ';', ',' or ')' before '*' token
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3992:
error: expected declaration specifiers or '...' before 'uint8_t'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3993:
error: expected ';', ',' or ')' before '*' token
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3994:
error: expected ';' before 'void'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:4002:
error: expected declaration specifiers or '...' before 'uint8_t'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:4003:
error: expected ';', ',' or ')' before '*' token
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:4036:
error: expected '=', ',', ';', 'asm' or '__attribute__' before 'void'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:4074:
error: expected '=', ',', ';', 'asm' or '__attribute__' before 'int'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:4081:
error: expected '=', ',', ';', 'asm' or '__attribute__' before 'int'
In file included from /home/baris/workspace/FFmpegTest/jni/
FFmpegTest.c:2:
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavformat/avformat.h:
106:32: error: libavcodec/avcodec.h: No such file or directory
In file included from /home/baris/workspace/FFmpegTest/jni/ffmpeg/
libavformat/avformat.h:108,
                 from /home/baris/workspace/FFmpegTest/jni/
FFmpegTest.c:2:
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavformat/avio.h:33:30:
error: libavutil/common.h: No such file or directory
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavformat/avio.h:34:27:
error: libavutil/log.h: No such file or directory
In file included from /home/baris/workspace/FFmpegTest/jni/ffmpeg/
libavformat/avformat.h:108,
                 from /home/baris/workspace/FFmpegTest/jni/
FFmpegTest.c:2:
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavformat/avio.h:273:
error: expected ':', ',', ';', '}' or '__attribute__' before '*' token
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavformat/avio.h:293:
error: expected '=', ',', ';', 'asm' or '__attribute__' before 'int'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavformat/avio.h:298:
error: expected '=', ',', ';', 'asm' or '__attribute__' before 'int'
In file included from /home/baris/workspace/FFmpegTest/jni/
FFmpegTest.c:2:
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavformat/avformat.h:
206: error: expected '=', ',', ';', 'asm' or '__attribute__' before
'int'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavformat/avformat.h:
225: error: expected '=', ',', ';', 'asm' or '__attribute__' before
'void'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavformat/avformat.h:
293: error: expected specifier-qualifier-list before 'AVRational'
In file included from /home/baris/workspace/FFmpegTest/jni/
FFmpegTest.c:2:
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavformat/avformat.h:
436: error: expected specifier-qualifier-list before
'attribute_deprecated'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavformat/avformat.h:
543: error: expected specifier-qualifier-list before 'AVRational'
/home/baris/workspace/FFmpegTest/jni/ffmpeg/libavformat/avformat.h:
694: error: expected specifier-qualifier-list before ...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
David Turner  
View profile  
 More options Dec 31 2010, 6:43 am
From: David Turner <di...@android.com>
Date: Fri, 31 Dec 2010 12:43:46 +0100
Local: Fri, Dec 31 2010 6:43 am
Subject: Re: FFmpeg using with NDK

By default, source files will be searched under $(LOCAL_PATH), so if you
have files elsewhere, you should set LOCAL_C_INCLUDES to point to the
corresponding directory.

If these are part of an imported module, consider using
LOCAL_EXPORT_C_INCLUDES when declaring the module itself so that other
modules that use it have the corresponding paths added to their own
LOCAL_C_INCLUDES automatically.

...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
baris atbas  
View profile  
 More options Dec 31 2010, 6:56 am
From: baris atbas <barisat...@gmail.com>
Date: Fri, 31 Dec 2010 03:56:41 -0800 (PST)
Local: Fri, Dec 31 2010 6:56 am
Subject: Re: FFmpeg using with NDK
I changed the Android.mk like that :

LOCAL_PATH := $(call my-dir)
include $(CLEAR_VARS)
LOCAL_MODULE    := ffmpg
LOCAL_SRC_FILES := FFmpegTest.c
LOCAL_LDLIBS := -libffmpeg
LOCAL_C_INCLUDES := $(LOCAL_PATH)/ffmpeg/
include $(BUILD_SHARED_LIBRARY)
include $(all-subdir-makefiles)

but still there are errors.
baris@ubuntu:~/workspace/FFmpegTest$ /home/baris/ndk/ndk-build
Compile thumb  : ffmpg <= /home/baris/workspace/FFmpegTest/jni/
FFmpegTest.c
/home/baris/workspace/FFmpegTest/jni/FFmpegTest.c: In function
'Java_com_test_Test_decodeVideo':
/home/baris/workspace/FFmpegTest/jni/FFmpegTest.c:103: warning:
'avcodec_decode_video' is deprecated (declared at /home/baris/
workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3606)
SharedLibrary  : libffmpg.so
/home/baris/ndk/build/prebuilt/linux-x86/arm-eabi-4.4.0/bin/../lib/gcc/
arm-eabi/4.4.0/../../../../arm-eabi/bin/ld: cannot find -libffmpeg
collect2: ld returned 1 exit status
make: *** [/home/baris/workspace/FFmpegTest/obj/local/armeabi/
libffmpg.so] Error 1

On 31 Aralık, 13:43, David Turner <di...@android.com> wrote:

...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Udayakumar Rayala  
View profile  
 More options Dec 31 2010, 7:41 am
From: Udayakumar Rayala <uday.ray...@gmail.com>
Date: Fri, 31 Dec 2010 18:11:08 +0530
Local: Fri, Dec 31 2010 7:41 am
Subject: Re: FFmpeg using with NDK

You would have to specify LOCAL_SHARED_LIBRARIES parameter instead of
LOCAL_LDLIBS.

LOCAL_SHARED_LIBRARIES := ffmpeg

Assuming that in the sub directories, you are building a shared library with
module name ffmpeg (as mentioned in
http://androidcore.com/android-programming-tutorials/641-how-to-compi...
).

Below is an example of Android.mk, i have done in one my projects:

======================================================================
MY_LOCAL_PATH := $(call my-dir)
include $(MY_LOCAL_PATH)/ffmpeg/FFMpeg.mk

LOCAL_PATH :=$(MY_LOCAL_PATH)
include $(CLEAR_VARS)
LOCAL_MODULE    := takepics
LOCAL_SRC_FILES := takepics.c
LOCAL_C_INCLUDES := $(MY_LOCAL_PATH) $(MY_LOCAL_PATH)/ffmpeg
LOCAL_SHARED_LIBRARIES := ffmpeg
LOCAL_LDLIBS += -lz -llog
include $(BUILD_SHARED_LIBRARY)
======================================================================

- Uday.

...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
baris atbas  
View profile  
 More options Dec 31 2010, 10:54 am
From: baris atbas <barisat...@gmail.com>
Date: Fri, 31 Dec 2010 07:54:25 -0800 (PST)
Local: Fri, Dec 31 2010 10:54 am
Subject: Re: FFmpeg using with NDK
I added the local shared lib statement but there are still errors :

baris@ubuntu:~/workspace/FFmpegTest$ /home/baris/ndk/ndk-build
Compile thumb  : ffmpg <= /home/baris/workspace/FFmpegTest/jni/
FFmpegTest.c
/home/baris/workspace/FFmpegTest/jni/FFmpegTest.c: In function
'Java_com_test_Test_decodeVideo':
/home/baris/workspace/FFmpegTest/jni/FFmpegTest.c:104: warning:
'avcodec_decode_video' is deprecated (declared at /home/baris/
workspace/FFmpegTest/jni/ffmpeg/libavcodec/avcodec.h:3606)
SharedLibrary  : libffmpg.so
/home/baris/workspace/FFmpegTest/obj/local/armeabi/objs/ffmpg/
FFmpegTest.o: In function `Java_com_test_Test_decodeVideo':
/home/baris/workspace/FFmpegTest/jni/FFmpegTest.c:43: undefined
reference to `av_register_all'
/home/baris/workspace/FFmpegTest/jni/FFmpegTest.c:46: undefined
reference to `av_open_input_file'
/home/baris/workspace/FFmpegTest/jni/FFmpegTest.c:50: undefined
reference to `av_find_stream_info'
/home/baris/workspace/FFmpegTest/jni/FFmpegTest.c:54: undefined
reference to `dump_format'
/home/baris/workspace/FFmpegTest/jni/FFmpegTest.c:70: undefined
reference to `avcodec_find_decoder'
/home/baris/workspace/FFmpegTest/jni/FFmpegTest.c:76: undefined
reference to `avcodec_open'
/home/baris/workspace/FFmpegTest/jni/FFmpegTest.c:80: undefined
reference to `avcodec_alloc_frame'
/home/baris/workspace/FFmpegTest/jni/FFmpegTest.c:83: undefined
reference to `avcodec_alloc_frame'
/home/baris/workspace/FFmpegTest/jni/FFmpegTest.c:88: undefined
reference to `avpicture_get_size'
/home/baris/workspace/FFmpegTest/jni/FFmpegTest.c:90: undefined
reference to `av_malloc'
/home/baris/workspace/FFmpegTest/jni/FFmpegTest.c:95: undefined
reference to `avpicture_fill'
/home/baris/workspace/FFmpegTest/jni/FFmpegTest.c:121: undefined
reference to `av_free_packet'
/home/baris/workspace/FFmpegTest/jni/FFmpegTest.c:100: undefined
reference to `av_read_frame'
/home/baris/workspace/FFmpegTest/jni/FFmpegTest.c:125: undefined
reference to `av_free'
/home/baris/workspace/FFmpegTest/jni/FFmpegTest.c:126: undefined
reference to `av_free'
/home/baris/workspace/FFmpegTest/jni/FFmpegTest.c:129: undefined
reference to `av_free'
/home/baris/workspace/FFmpegTest/jni/FFmpegTest.c:132: undefined
reference to `avcodec_close'
/home/baris/workspace/FFmpegTest/jni/FFmpegTest.c:135: undefined
reference to `av_close_input_file'
/home/baris/workspace/FFmpegTest/jni/FFmpegTest.c:104: undefined
reference to `avcodec_decode_video'
/home/baris/workspace/FFmpegTest/jni/FFmpegTest.c:110: undefined
reference to `img_convert'
collect2: ld returned 1 exit status
make: *** [/home/baris/workspace/FFmpegTest/obj/local/armeabi/
libffmpg.so] Error 1

here is my last Android.mk

LOCAL_PATH := $(call my-dir)
include $(CLEAR_VARS)
# Here we give our module name and source file(s)
LOCAL_MODULE    := ffmpg
LOCAL_SRC_FILES := FFmpegTest.c
LOCAL_SHARED_LIBRARIES := ffmpeg
LOCAL_C_INCLUDES := $(LOCAL_PATH)/ffmpeg/
LOCAL_LDLIBS += -lz -llog
include $(BUILD_SHARED_LIBRARY)
include $(all-subdir-makefiles)

On 31 Aralık, 14:41, Udayakumar Rayala <uday.ray...@gmail.com> wrote:

...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Udayakumar Rayala  
View profile  
 More options Dec 31 2010, 8:52 pm
From: Udayakumar Rayala <uday.ray...@gmail.com>
Date: Sat, 1 Jan 2011 07:22:46 +0530
Local: Fri, Dec 31 2010 8:52 pm
Subject: Re: FFmpeg using with NDK

Try ndk-build with V=1 command line option. This will show the exact command
executed to compile.

Most probably, the LOCAL_C_INCLUDES might not have been set properly. That
is the reason why i had to create a variable called MY_LOCAL_PATH.

Try the following build file. If this doesnt work post the log file from
this command *~/workspace/FFmpegTest$ /home/baris/ndk/ndk-build V=1*

> MY_LOCAL_PATH := $(call my-dir)
> LOCAL_PATH :=$(MY_LOCAL_PATH)

include $(CLEAR_VARS)
# Here we give our module name and source file(s)
LOCAL_MODULE    := ffmpg
LOCAL_SRC_FILES := FFmpegTest.c
LOCAL_SHARED_LIBRARIES := ffmpeg
LOCAL_C_INCLUDES := $(MY_LOCAL_PATH)/ffmpeg/
LOCAL_LDLIBS += -lz -llog
include $(BUILD_SHARED_LIBRARY)
include $(all-subdir-makefiles)

...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
baris atbas  
View profile  
 More options Jan 1 2011, 3:43 am
From: baris atbas <barisat...@gmail.com>
Date: Sat, 1 Jan 2011 00:43:51 -0800 (PST)
Local: Sat, Jan 1 2011 3:43 am
Subject: Re: FFmpeg using with NDK
I optimized my ffmpeg test code to understand where is the error:

#include <ffmpeg/libavcodec/avcodec.h>
#include <ffmpeg/libavformat/avformat.h>
#include <jni.h>
#include <stdio.h>

jint Java_com_test_Test_decodeVideo(JNIEnv* env, jobject
javaThis,jstring filename) {
  AVFormatContext *pFormatCtx;
  av_register_all();
  if(av_open_input_file(&pFormatCtx, filename, NULL, 0, NULL)!=0)
    return -1; // Couldn't open file
  return 0;

}

and also change the android.mk according to your comments then ndk-
build V=1   ,it is the log file :

baris@ubuntu:~/workspace/FFmpegTest$ /home/baris/ndk/ndk-build V=1
rm -f /home/baris/workspace/FFmpegTest/libs/armeabi/lib*.so /home/
baris/workspace/FFmpegTest/libs/armeabi-v7a/lib*.so /home/baris/
workspace/FFmpegTest/libs/x86/lib*.so
rm -f /home/baris/workspace/FFmpegTest/libs/armeabi/gdbserver /home/
baris/workspace/FFmpegTest/libs/armeabi-v7a/gdbserver /home/baris/
workspace/FFmpegTest/libs/x86/gdbserver
rm -f /home/baris/workspace/FFmpegTest/libs/armeabi/gdb.setup /home/
baris/workspace/FFmpegTest/libs/armeabi-v7a/gdb.setup /home/baris/
workspace/FFmpegTest/libs/x86/gdb.setup
Compile thumb  : ffmpg <= /home/baris/workspace/FFmpegTest/jni/
FFmpegTest.c
/home/baris/ndk/build/prebuilt/linux-x86/arm-eabi-4.4.0/bin/arm-eabi-
gcc -I/home/baris/ndk/build/platforms/android-8/arch-arm/usr/include -
fpic -mthumb-interwork -ffunction-sections -funwind-tables -fstack-
protector -fno-short-enums -D__ARM_ARCH_5__ -D__ARM_ARCH_5T__ -
D__ARM_ARCH_5E__ -D__ARM_ARCH_5TE__  -Wno-psabi -march=armv5te -
mtune=xscale -msoft-float -mthumb -Os -fomit-frame-pointer -fno-strict-
aliasing -finline-limit=64 -I/home/baris/workspace/FFmpegTest/jni/
ffmpeg/ -I/home/baris/workspace/FFmpegTest/jni -DANDROID  -Wa,--
noexecstack -O2 -DNDEBUG -g -c -MMD -MP -MF /home/baris/workspace/
FFmpegTest/obj/local/armeabi/objs/ffmpg/FFmpegTest.o.d /home/baris/
workspace/FFmpegTest/jni/FFmpegTest.c -o /home/baris/workspace/
FFmpegTest/obj/local/armeabi/objs/ffmpg/FFmpegTest.o
SharedLibrary  : libffmpg.so
/home/baris/ndk/build/prebuilt/linux-x86/arm-eabi-4.4.0/bin/arm-eabi-
gcc -nostdlib -Wl,-soname,libffmpg.so -Wl,-shared,-Bsymbolic  /home/
baris/workspace/FFmpegTest/obj/local/armeabi/objs/ffmpg/FFmpegTest.o -
Wl,--whole-archive  -Wl,--no-whole-archive  /home/baris/ndk/build/
prebuilt/linux-x86/arm-eabi-4.4.0/bin/../lib/gcc/arm-eabi/4.4.0/
libgcc.a /home/baris/workspace/FFmpegTest/obj/local/armeabi/
libffmpeg.so /home/baris/ndk/build/platforms/android-8/arch-arm/usr/
lib/libc.so /home/baris/ndk/build/platforms/android-8/arch-arm/usr/lib/
libstdc++.so /home/baris/ndk/build/platforms/android-8/arch-arm/usr/
lib/libm.so    -Wl,--no-undefined -Wl,-z,noexecstack -L/home/baris/ndk/
build/platforms/android-8/arch-arm/usr/lib  -lz -llog -Wl,-rpath-link=/
home/baris/ndk/build/platforms/android-8/arch-arm/usr/lib -o /home/
baris/workspace/FFmpegTest/obj/local/armeabi/libffmpg.so
/home/baris/workspace/FFmpegTest/obj/local/armeabi/objs/ffmpg/
FFmpegTest.o: In function `Java_com_test_Test_decodeVideo':
/home/baris/workspace/FFmpegTest/jni/FFmpegTest.c:17: undefined
reference to `av_register_all'
/home/baris/workspace/FFmpegTest/jni/FFmpegTest.c:19: undefined
reference to `av_open_input_file'
collect2: ld returned 1 exit status
make: *** [/home/baris/workspace/FFmpegTest/obj/local/armeabi/
libffmpg.so] Error 1

On 1 Ocak, 03:52, Udayakumar Rayala <uday.ray...@gmail.com> wrote:

...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Udayakumar Rayala  
View profile  
 More options Jan 1 2011, 5:23 am
From: Udayakumar Rayala <uday.ray...@gmail.com>
Date: Sat, 1 Jan 2011 15:53:45 +0530
Local: Sat, Jan 1 2011 5:23 am
Subject: Re: FFmpeg using with NDK

I tried modifying my Android.mk file to include $(all-subdir-makefiles) at
the end of the file but it didnt work. I had to add it before my module
definition. I am surprised it worked for you.

I usually delete obj and libs folders before doing ndk-build or use -B
option with ndk-build so that it doesnt use the files from the previous
compile. I see from your log output that libffmpeg is not build in this run.
Does your Android.mk files look exactly the one which are posted in the
previous link?

- Uday,

...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
baris atbas  
View profile  
 More options Jan 1 2011, 6:05 am
From: baris atbas <barisat...@gmail.com>
Date: Sat, 1 Jan 2011 03:05:15 -0800 (PST)
Local: Sat, Jan 1 2011 6:05 am
Subject: Re: FFmpeg using with NDK
I tried to change my android.mk like yours. and it looks like that :

MY_LOCAL_PATH := $(call my-dir)
include $(MY_LOCAL_PATH)/ffmpeg/Android.mk
LOCAL_PATH := $(MY_LOCAL_PATH)
include $(CLEAR_VARS)
# Here we give our module name and source file(s)
LOCAL_MODULE    := ffmpg
LOCAL_SRC_FILES := FFmpegTest.c
LOCAL_SHARED_LIBRARIES := ffmpeg
LOCAL_C_INCLUDES := $(MY_LOCAL_PATH)/ffmpeg/
LOCAL_LDLIBS += -lz -llog
include $(BUILD_SHARED_LIBRARY)

then ndk-build command :

....
Compile thumb  : swscale <= utils.c
Compile thumb  : swscale <= yuv2rgb.c
StaticLibrary  : libswscale.a
SharedLibrary  : libffmpeg.so
Install        : libffmpeg.so => libs/armeabi/libffmpeg.so
SharedLibrary  : libffmpg.so
/home/baris/workspace/FFmpegTest/obj/local/armeabi/objs/ffmpg/
FFmpegTest.o: In function `Java_com_test_Test_decodeVideo':
/home/baris/workspace/FFmpegTest/jni/FFmpegTest.c:17: undefined
reference to `av_register_all'
/home/baris/workspace/FFmpegTest/jni/FFmpegTest.c:19: undefined
reference to `av_open_input_file'
collect2: ld returned 1 exit status
make: *** [/home/baris/workspace/FFmpegTest/obj/local/armeabi/
libffmpg.so] Error 1

same error occured. maybe in native function I dont use ffmpeg
correctly. and last time I post you include all subdir makefiles
command is at the end of the android.mk

On 1 Ocak, 12:23, Udayakumar Rayala <uday.ray...@gmail.com> wrote:

...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
baris atbas  
View profile  
 More options Jan 1 2011, 4:41 pm
From: baris atbas <barisat...@gmail.com>
Date: Sat, 1 Jan 2011 13:41:30 -0800 (PST)
Local: Sat, Jan 1 2011 4:41 pm
Subject: Re: FFmpeg using with NDK
Thanks to your useful comments, Problem is solved :)

On 1 Ocak, 13:05, baris atbas <barisat...@gmail.com> wrote:

...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
soulseek  
View profile  
 More options Jan 5 2011, 3:35 am
From: soulseek <markus.brou...@gmail.com>
Date: Wed, 5 Jan 2011 00:35:34 -0800 (PST)
Local: Wed, Jan 5 2011 3:35 am
Subject: Re: FFmpeg using with NDK
Could you please post your Android.mk file how it looks like now?
Because I have a the same problem and don`t know how to fix it. I
tried out to take your makefile from the post before but I also get
always the "undefined reference" errors.

For further information, I also followed the tutorial from your 1st
post.

My C-file looks like:
=========================================================================== =============
#include <jni.h>
#include <string.h>
#include <stdlib.h>
#include <android/log.h>
#include "libavformat/avformat.h"

void Java_mercedes_ui_Main_helloLog(JNIEnv * env, jobject this,
jstring file)
{
  jboolean isCopy;
  char * mediaFile = (*env)->GetStringUTFChars(env, file, &isCopy);

  AVFormatContext *format_ctx;
  av_register_all();
  if (av_open_input_file(&format_ctx, mediaFile, NULL, 0, NULL) < 0) {
      printf ("Cannot open file %s\n", mediaFile);
      exit(1);
  }

  dump_format(format_ctx, 0, mediaFile, 0);
  AVMetadataTag *tag = NULL;
  while ((tag=av_metadata_get(format_ctx->metadata, "", tag,
AV_METADATA_IGNORE_SUFFIX)))
    __android_log_print(ANDROID_LOG_INFO, tag->key, tag->value);

  (*env)->ReleaseStringUTFChars(env, file, mediaFile);

}

=========================================================================== =============
And my Android.mk
=========================================================================== =============
LOCAL_PATH := $(call my-dir)
include $(CLEAR_VARS)
LOCAL_C_INCLUDES := $(LOCAL_PATH)/ffmpeg/
LOCAL_LDLIBS := -L /media/Linux/SW_Projekt/AndroidCarStreamer/obj/
local/armeabi -lffmpeg -llog
LOCAL_STATIC_LIBRARIES += avformat avcodec avutil postproc swscale
LOCAL_MODULE    := mediaServer
LOCAL_SRC_FILES := idTagReader.c
include $(BUILD_SHARED_LIBRARY)
=========================================================================== =============

Thanks in advance!

On Jan 1, 4:41 pm, baris atbas <barisat...@gmail.com> wrote:

...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Udayakumar Rayala  
View profile  
 More options Jan 5 2011, 9:21 pm
From: Udayakumar Rayala <uday.ray...@gmail.com>
Date: Thu, 6 Jan 2011 07:51:38 +0530
Local: Wed, Jan 5 2011 9:21 pm
Subject: Re: FFmpeg using with NDK

Did you pre-build ffmpeg and using it as a library? If that is the case,
then you dont need to specify LOCAL_STATIC_LIBRARIES.

You can follow the below step as a starting point and then modify as you
want:

1. Place ffmpeg in jni folder. and follow the steps in How to compile
ffmpeg<http://androidcore.com/android-programming-tutorials/641-how-to-compi...>
<http://androidcore.com/android-programming-tutorials/641-how-to-compi...>2.
Place idTagReader.c in jni folder outside ffmpeg.
3. Add the following Android.mk file.

MY_LOCAL_PATH := $(call my-dir)
include $(all-subdir-makefiles)
LOCAL_PATH :=$(MY_LOCAL_PATH)
include $(CLEAR_VARS)
LOCAL_MODULE    := mediaServer
LOCAL_SRC_FILES := idTagReader.c
LOCAL_C_INCLUDES := $(MY_LOCAL_PATH) $(MY_LOCAL_PATH)/ffmpeg
LOCAL_SHARED_LIBRARIES := ffmpeg
LOCAL_LDLIBS += -lz -llog
include $(BUILD_SHARED_LIBRARY)

4. Add the following Application.mk file.

APP_MODULES      := ffmpeg mediaServer

5. Compile with ndk-build. It will generate 2 shared libraries libffmpeg.so
and libmediaServer.so.

If you are still getting the errors, post the output of ndk-build with V=1
command line option.

- Uday.

...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
soulseek  
View profile  
 More options Jan 10 2011, 4:14 am
From: soulseek <markus.brou...@gmail.com>
Date: Mon, 10 Jan 2011 01:14:43 -0800 (PST)
Local: Mon, Jan 10 2011 4:14 am
Subject: Re: FFmpeg using with NDK
Thank very much for your help! But I still get the same error
messages. But I found out that when I download
http://rockplayer.freecoder.org/download/rockplayer_ffmpeg.zip,
extract it into the ffmpeg folder in the jni folder and take your make
files, than everything compiles fin :-) So thanks again!

P.S.: This is my output with errors:

[soulseek@sabayon] ffmpeg $ ndk-build V=1
rm -f /media/Linux/SW_Projekt/AndroidCarStreamer/libs/armeabi/lib*.so /
media/Linux/SW_Projekt/AndroidCarStreamer/libs/armeabi-v7a/lib*.so /
media/Linux/SW_Projekt/AndroidCarStreamer/libs/x86/lib*.so
rm -f /media/Linux/SW_Projekt/AndroidCarStreamer/libs/armeabi/
gdbserver /media/Linux/SW_Projekt/AndroidCarStreamer/libs/armeabi-v7a/
gdbserver /media/Linux/SW_Projekt/AndroidCarStreamer/libs/x86/
gdbserver
rm -f /media/Linux/SW_Projekt/AndroidCarStreamer/libs/armeabi/
gdb.setup /media/Linux/SW_Projekt/AndroidCarStreamer/libs/armeabi-v7a/
gdb.setup /media/Linux/SW_Projekt/AndroidCarStreamer/libs/x86/
gdb.setup
Gdbserver      : [arm-linux-androideabi-4.4.3] libs/armeabi/gdbserver
mkdir -p /media/Linux/SW_Projekt/AndroidCarStreamer/libs/armeabi
install -p /media/Linux/SW_Projekt/android_ndk_linux/toolchains/arm-
linux-androideabi-4.4.3/prebuilt/gdbserver /media/Linux/SW_Projekt/
AndroidCarStreamer/libs/armeabi/gdbserver
Gdbsetup       : libs/armeabi/gdb.setup
echo "set solib-search-path /media/Linux/SW_Projekt/AndroidCarStreamer/
obj/local/armeabi" > /media/Linux/SW_Projekt/AndroidCarStreamer/libs/
armeabi/gdb.setup
echo "directory /media/Linux/SW_Projekt/android_ndk_linux/platforms/
android-8/arch-arm/usr/include /media/Linux/SW_Projekt/
AndroidCarStreamer/jni/ffmpeg/libavcodec /media/Linux/SW_Projekt/
AndroidCarStreamer/jni/ffmpeg/libavcodec/.. /media/Linux/SW_Projekt/
AndroidCarStreamer/jni/ffmpeg/libavcore /media/Linux/SW_Projekt/
AndroidCarStreamer/jni/ffmpeg/libavcore/.. /media/Linux/SW_Projekt/
AndroidCarStreamer/jni/ffmpeg/libavfilter /media/Linux/SW_Projekt/
AndroidCarStreamer/jni/ffmpeg/libavfilter/.. /media/Linux/SW_Projekt/
AndroidCarStreamer/jni/ffmpeg/libavformat /media/Linux/SW_Projekt/
AndroidCarStreamer/jni/ffmpeg/libavformat/.. /media/Linux/SW_Projekt/
AndroidCarStreamer/jni/ffmpeg/libavutil /media/Linux/SW_Projekt/
AndroidCarStreamer/jni/ffmpeg/libavutil/.. /media/Linux/SW_Projekt/
AndroidCarStreamer/jni/ffmpeg /media/Linux/SW_Projekt/
AndroidCarStreamer/jni /media/Linux/SW_Projekt/AndroidCarStreamer/jni/
ffmpeg/libpostproc /media/Linux/SW_Projekt/AndroidCarStreamer/jni/
ffmpeg/libpostproc/.. /media/Linux/SW_Projekt/android_ndk_linux/
sources/cxx-stl/system" >> /media/Linux/SW_Projekt/AndroidCarStreamer/
libs/armeabi/gdb.setup
Install        : libffmpeg.so => libs/armeabi/libffmpeg.so
mkdir -p /media/Linux/SW_Projekt/AndroidCarStreamer/libs/armeabi
install -p /media/Linux/SW_Projekt/AndroidCarStreamer/obj/local/
armeabi/libffmpeg.so /media/Linux/SW_Projekt/AndroidCarStreamer/libs/
armeabi/libffmpeg.so
/media/Linux/SW_Projekt/android_ndk_linux/toolchains/arm-linux-
androideabi-4.4.3/prebuilt/linux-x86/bin/arm-linux-androideabi-strip --
strip-unneeded  /media/Linux/SW_Projekt/AndroidCarStreamer/libs/
armeabi/libffmpeg.so
SharedLibrary  : libmediaServer.so
/media/Linux/SW_Projekt/android_ndk_linux/toolchains/arm-linux-
androideabi-4.4.3/prebuilt/linux-x86/bin/arm-linux-androideabi-g++ -
Wl,-soname,libmediaServer.so -shared --sysroot=/media/Linux/SW_Projekt/
android_ndk_linux/platforms/android-8/arch-arm   /media/Linux/
SW_Projekt/AndroidCarStreamer/obj/local/armeabi/objs-debug/mediaServer/
idTagReader.o    /media/Linux/SW_Projekt/AndroidCarStreamer/obj/local/
armeabi/libffmpeg.so /media/Linux/SW_Projekt/android_ndk_linux/
platforms/android-8/arch-arm/usr/lib/libc.so /media/Linux/SW_Projekt/
android_ndk_linux/platforms/android-8/arch-arm/usr/lib/libstdc++.so /
media/Linux/SW_Projekt/android_ndk_linux/platforms/android-8/arch-arm/
usr/lib/libm.so   -Wl,--no-undefined -Wl,-z,noexecstack -L/media/Linux/
SW_Projekt/android_ndk_linux/platforms/android-8/arch-arm/usr/lib -lz -
llog -Wl,-rpath-link=/media/Linux/SW_Projekt/android_ndk_linux/
platforms/android-8/arch-arm/usr/lib -lsupc++ -o /media/Linux/
SW_Projekt/AndroidCarStreamer/obj/local/armeabi/libmediaServer.so
/media/Linux/SW_Projekt/AndroidCarStreamer/obj/local/armeabi/objs-
debug/mediaServer/idTagReader.o: In function
`Java_mercedes_ui_Main_helloLog':
/media/Linux/SW_Projekt/AndroidCarStreamer/jni/idTagReader.c:16:
undefined reference to `av_register_all'
/media/Linux/SW_Projekt/AndroidCarStreamer/jni/idTagReader.c:18:
undefined reference to `av_open_input_file'
/media/Linux/SW_Projekt/AndroidCarStreamer/jni/idTagReader.c:24:
undefined reference to `dump_format'
/media/Linux/SW_Projekt/AndroidCarStreamer/jni/idTagReader.c:27:
undefined reference to `av_metadata_get'
collect2: ld returned 1 exit status
make: *** [/media/Linux/SW_Projekt/AndroidCarStreamer/obj/local/
armeabi/libmediaServer.so] Error 1

On 5 Jan., 21:21, Udayakumar Rayala <uday.ray...@gmail.com> wrote:

...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Nikhil Dhavale  
View profile  
 More options Feb 4 2011, 6:11 am
From: Nikhil Dhavale <nikhildhavale...@gmail.com>
Date: Fri, 4 Feb 2011 03:11:38 -0800 (PST)
Local: Fri, Feb 4 2011 6:11 am
Subject: Re: FFmpeg using with NDK
I am trying similar type of library usage. But I get following issue.
/cygdrive/e/Android/FFMppegg/jni/Android.mk:3: /cygdrive/e/Android/
FFMppegg/jni/
ffmpeg/Android.mk: No such file or directory
make: *** No rule to make target `/cygdrive/e/Android/FFMppegg/jni/
ffmpeg/Androi
d.mk'.  Stop.
Implying something is wrong with Android.mk file. Can you please help.
Nikhil Dhavale

On Jan 2, 2:41 am, baris atbas <barisat...@gmail.com> wrote:

...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
soulseek  
View profile  
 More options Feb 4 2011, 6:21 am
From: soulseek <markus.brou...@gmail.com>
Date: Fri, 4 Feb 2011 03:21:43 -0800 (PST)
Local: Fri, Feb 4 2011 6:21 am
Subject: Re: FFmpeg using with NDK
Can you pleas post your /cygdrive/e/Android/FFMppegg/jni/Android.mk
and `/cygdrive/e/Android/FFMppegg/jni/ffmpeg/Android.mk' files?
and is this file `/cygdrive/e/Android/FFMppegg/jni/ffmpeg/Android.mk'
in the ffmpeg folder? Because I had sometimes this message "No rule to
make target" when the file I wanted to include was missing ;-)

On 4 Feb., 12:11, Nikhil Dhavale <nikhildhavale...@gmail.com> wrote:

...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Udayakumar Rayala  
View profile  
 More options Feb 4 2011, 9:05 am
From: Udayakumar Rayala <uday.ray...@gmail.com>
Date: Fri, 4 Feb 2011 19:35:14 +0530
Local: Fri, Feb 4 2011 9:05 am
Subject: Re: FFmpeg using with NDK

I have attached the Android.mk files.

...

read more »

  jni.zip
1K Download

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
soulseek  
View profile  
 More options Feb 5 2011, 6:47 am
From: soulseek <markus.brou...@gmail.com>
Date: Sat, 5 Feb 2011 03:47:56 -0800 (PST)
Local: Sat, Feb 5 2011 6:47 am
Subject: Re: FFmpeg using with NDK
Could you also upload your ffmpeg folder with all files somewhere
please? Because, I cant replicate your error. I have to delete the
cmdutils.c from the local source files in the jni/ffmpeg/Android.mk
because I have no version.h and when I use my config.sh I get some
other errors (like: error: expected ';', ',' or ')' before 'v1' but I
think it has to do with my config.sh script)

But it starts to compile as you can see:

jni $ ndk-build
Gdbserver      : [arm-linux-androideabi-4.4.3] libs/armeabi/gdbserver
Gdbsetup       : libs/armeabi/gdb.setup
Compile thumb  : ffmpeg <= ffmpeg.c
./jni/ffmpeg/ffmpeg.c: In function 'do_video_out':
./jni/ffmpeg/ffmpeg.c:1085: warning: passing argument 2 of 'sws_scale'
from incompatible pointer type
./jni/ffmpeg/libswscale/swscale.h:195: note: expected 'const uint8_t *
const*' but argument is of type 'uint8_t **'
Compile thumb  : avformat <= 4xm.c
Compile thumb  : avformat <= adtsenc.c
.
.
.

On 4 Feb., 09:05, Udayakumar Rayala <uday.ray...@gmail.com> wrote:

...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Messages 1 - 25 of 35   Newer >
« Back to Discussions « Newer topic     Older topic »