[FFmpeg-user] How to integrate shared object file of libx264 while using ffmpeg for android?

2014-08-05 Thread David Varghese
Hi,

I am working with integrating ffmpeg for android .

Since I needed H.264 encoding I need to integrate libx264 with ffmpeg .
Given below are the steps I followed .

1) Build the latest libx264 using android compiler tool-chain to obtain
libx264.so.142 .

2) Build ffmpeg v 2.3 referring to this
http://www.roman10.net/how-to-build-ffmpeg-with-ndk-r9/ with --enable
-libx264 option while configuring ffmpeg . The method explained in the blog
included some editing in configure file of ffmpeg to generate shared object
files with format [lib name].so rather than the generating shared object
file with format [lib name].so.[version] (Since android build system
supports files with extension .so only).

The building process was successful but since the generated .so files
(after building ffmpeg) has dynamic dependency with libx264.so.142,I need
to package libx264.so.142 also with the android .apk file . But since the
above format (.so.142) is not supported with android apk building system I
cannot package it with the .apk .

So I think the only option I have is to make some changes in configure file
of ffmpeg to change the dynamic dependency of libx264.so.142 to libx264.so
. Am I right??

What changes do I need to make to ffmpeg configure file to achieve this?


-- 
Thanks and Regards ,
David Varghese
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] How to integrate shared object file of libx264 while using ffmpeg for android?

2014-08-05 Thread Carl Eugen Hoyos
David Varghese davidvrgh at gmail.com writes:

 2) Build ffmpeg v 2.3

If you need support on this mailing list, please 
provide the actual configure line you are using 
(not an external script) and the problem you have 
with that configure line.
If you believe that our configure script misses 
some feature necessary for a particular OS (like 
Android) please report this here!

If you have problems building x264, I am not sure 
this is the right place to ask.

Carl Eugen


___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] How to integrate shared object file of libx264 while using ffmpeg for android?

2014-08-05 Thread David Varghese
Thanks .

I have edited the actual configure file by replacing the following lines ,

SLIBNAME_WITH_MAJOR='$(SLIBNAME).$(LIBMAJOR)'

 LIB_INSTALL_EXTRA_CMD='$$(RANLIB) $(LIBDIR)/$(LIBNAME)'

 SLIB_INSTALL_NAME='$(SLIBNAME_WITH_VERSION)'

 SLIB_INSTALL_LINKS='$(SLIBNAME_WITH_MAJOR) $(SLIBNAME)'




with the below lines,

SLIBNAME_WITH_MAJOR='$(SLIBPREF)$(FULLNAME)-$(LIBMAJOR)$(SLIBSUF)'

LIB_INSTALL_EXTRA_CMD='$$(RANLIB) $(LIBDIR)/$(LIBNAME)'

SLIB_INSTALL_NAME='$(SLIBNAME_WITH_MAJOR)'

SLIB_INSTALL_LINKS='$(SLIBNAME)'



My intention was to generate shared object files with extension library
name - version.so rather than with the extension format
libavcodec.so.version . This is because android's binary generating
system only supports .so format .

When running ffmpeg configure with --enable-libx264 option the generated
shared object files (eg : libavutil) has dynamic dependency with
libx264.so.version . But I want to make this dependency to library
name.so extension format so that android binary packaging system will be
able to package shared object for libx264 .






On Tue, Aug 5, 2014 at 4:22 PM, Carl Eugen Hoyos ceho...@ag.or.at wrote:

 David Varghese davidvrgh at gmail.com writes:

  2) Build ffmpeg v 2.3

 If you need support on this mailing list, please
 provide the actual configure line you are using
 (not an external script) and the problem you have
 with that configure line.
 If you believe that our configure script misses
 some feature necessary for a particular OS (like
 Android) please report this here!

 If you have problems building x264, I am not sure
 this is the right place to ask.

 Carl Eugen


 ___
 ffmpeg-user mailing list
 ffmpeg-user@ffmpeg.org
 http://ffmpeg.org/mailman/listinfo/ffmpeg-user




-- 
Thanks and Regards ,
David Varghese
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] How to integrate shared object file of libx264 while using ffmpeg for android?

2014-08-05 Thread Carl Eugen Hoyos
David Varghese davidvrgh at gmail.com writes:

 I have edited the actual configure file

You (of course!) cannot get support here if you 
edit your configure file. Instead, please report 
what does not work with the unchanged source so 
we can fix it.
If you want to compile for Android, please use 
the configure option --target-os=android (this 
should stop FFmpeg from building shared libraries 
with major version in the file name).

Please do not top-post here.

Carl Eugen


___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] How to integrate shared object file of libx264 while using ffmpeg for android?

2014-08-05 Thread Carl Eugen Hoyos
David Varghese davidvrgh at gmail.com writes:

 Using configure option --target-os=android is 
 generating shared object files which has extension 
 supported by android (.so) .

Thank you for testing this!

 But when I use --enable -libx264 option the libavutil.so 
 (which is generated after building ffmpeg) is having a 
 dynamic dependency to the shared object file libx264.so.142

Do I understand correctly that you built a binary of x264 
that has an incorrect so name? Is it perhaps sufficient to 
rename the library?

Carl Eugen


___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] Any better documentation?

2014-08-05 Thread Stephen Ho
Thanks everyone, I will be reading more about your suggestions. I also
found this http://manpages.ubuntu.com/manpages/oneiric/man1/ffmpeg.1.html
to be better than what I paid for the pdf book, as you can see I am the
very beginner, and thought the book is not a man page but some tutorial. It
turns out it is somewhat in between.

I am using Window with the command window. I do not use linux etc. but I
have some unix commands in dos command window. man ffmpeg does not come up
with man page, maybe my manpath has not set up. That is OK, I just want it
to do simple thing.

Is there a GNU version of ffmpeg?

  *Stephen Ho *
510-364-8941 (c)  stephenh...@gmail.com
925-398-6808 x183 (vm) StephenHoRealty.com http://www.StephenHoRealty.com



On Tue, Aug 5, 2014 at 2:01 AM, James Darnley james.darn...@gmail.com
wrote:

 On 2014-08-05 08:48, Stephen Ho wrote:
  I did this command   ffmpeg -i abc.mp4 -f hevc abc.avi   got my file size
  to 5% of the original, and the resolution is really bad and no sound.
 
  Then I did  ffmpeg -i abc.mp4 -f h264 abc.avi and the file size is 45%,
 the
  video resolution is great (like the input file), but still no sound.

 What do you expect to happen when you ask ffmpeg to create a raw video
 stream?  -f controls the file format not the video codec.

 If you can't handle ffmpeg's own help, accessible through -h, try
 reading them online here: http://ffmpeg.org/documentation.html

 My suggestion for a good quality encode:
 ffmpeg -i INPUT -vcodec libx264 -preset medium -crf 21 -threads 0 OUTPUT

 I also wonder why you are wanting to re-encode an MP4 file.  I doubt you
 will make it that much smaller and keep decent quality seeing the rest
 of your requirements.


 ___
 ffmpeg-user mailing list
 ffmpeg-user@ffmpeg.org
 http://ffmpeg.org/mailman/listinfo/ffmpeg-user


___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] Any better documentation?

2014-08-05 Thread Gabri Shally
On Aug 5, 2014 10:30 PM, Stephen Ho stephenh...@gmail.com wrote:

 I am using Window with the command window. I do not use linux etc. but I
 have some unix commands in dos command window. man ffmpeg does not come up
 with man page, maybe my manpath has not set up. That is OK, I just want it
 to do simple thing.


if you just want to do something simple, you'd be better using gui that
interfacing ffmpeg, like FFactory. it easy to use.
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] Any better documentation?

2014-08-05 Thread Gerion Entrup
Am Dienstag 05 August 2014, 08:29:51 schrieb Stephen Ho:
 Thanks everyone, I will be reading more about your suggestions. I also
 found this http://manpages.ubuntu.com/manpages/oneiric/man1/ffmpeg.1.html
 to be better than what I paid for the pdf book, as you can see I am the
 very beginner, and thought the book is not a man page but some tutorial. It
Ubuntu ships a very old manpage. Many things have changed since version 0.7.2.

Maybe you take a look at:
http://ffmpeg.org/documentation.html

Gerion

 On Tue, Aug 5, 2014 at 2:01 AM, James Darnley james.darn...@gmail.com
 
 wrote:
  On 2014-08-05 08:48, Stephen Ho wrote:
   I did this command   ffmpeg -i abc.mp4 -f hevc abc.avi   got my file
   size
   to 5% of the original, and the resolution is really bad and no sound.
   
   Then I did  ffmpeg -i abc.mp4 -f h264 abc.avi and the file size is 45%,
  
  the
  
   video resolution is great (like the input file), but still no sound.
  
  What do you expect to happen when you ask ffmpeg to create a raw video
  stream?  -f controls the file format not the video codec.
  
  If you can't handle ffmpeg's own help, accessible through -h, try
  reading them online here: http://ffmpeg.org/documentation.html
  
  My suggestion for a good quality encode:
  ffmpeg -i INPUT -vcodec libx264 -preset medium -crf 21 -threads 0 OUTPUT
  
  I also wonder why you are wanting to re-encode an MP4 file.  I doubt you
  will make it that much smaller and keep decent quality seeing the rest
  of your requirements.
  
  
  ___
  ffmpeg-user mailing list
  ffmpeg-user@ffmpeg.org
  http://ffmpeg.org/mailman/listinfo/ffmpeg-user
 
 ___
 ffmpeg-user mailing list
 ffmpeg-user@ffmpeg.org
 http://ffmpeg.org/mailman/listinfo/ffmpeg-user

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] Any better documentation?

2014-08-05 Thread Stephen Ho
Wow, thank you @Gabri, FFactory is easy to use and good enough for me. I
put in 10 files expected to convert them and appended together into one,
and it actually convert each individually.

I will play with ffmpeg a bit more, I aim to do this.

ffmpeg -i file1.mp4 file2.mp4 file3.mp4  (something like this ==
resolution hd720, medium quality, h264 or hevc/265, into container .avi
  and sound should not matter much for file size)   finaloutput.avi



  *Stephen Ho *
510-364-8941 (c)  stephenh...@gmail.com
925-398-6808 x183 (vm) StephenHoRealty.com http://www.StephenHoRealty.com



On Tue, Aug 5, 2014 at 8:34 AM, Gabri Shally gabri...@gmail.com wrote:

 On Aug 5, 2014 10:30 PM, Stephen Ho stephenh...@gmail.com wrote:
 
  I am using Window with the command window. I do not use linux etc. but I
  have some unix commands in dos command window. man ffmpeg does not come
 up
  with man page, maybe my manpath has not set up. That is OK, I just want
 it
  to do simple thing.
 

 if you just want to do something simple, you'd be better using gui that
 interfacing ffmpeg, like FFactory. it easy to use.
 ___
 ffmpeg-user mailing list
 ffmpeg-user@ffmpeg.org
 http://ffmpeg.org/mailman/listinfo/ffmpeg-user

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user