LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   my mobile samsung e2120 does not play mp4 file created using ffmpeg (https://www.linuxquestions.org/questions/linux-newbie-8/my-mobile-samsung-e2120-does-not-play-mp4-file-created-using-ffmpeg-817538/)

sumeet inani 07-01-2010 10:03 PM

my mobile samsung e2120 does not play mp4 file created using ffmpeg
 
I am using ubuntu 8.04
here is what i did

I ran
ffmpeg -i /sumeet/clip/friends\ introduction\ song.mp4 -s 160x120 -acodec amr_nb -vcodec mpeg4 -r 30 -ar 8000 -ac 1 ~/Desktop/friends.mp4
now I compared sample video created by mobile file I created above.
Code:

09:08:59 ~ $ffmpeg -i ~/Desktop/sample.mp4
FFmpeg version SVN-rUNKNOWN, Copyright (c) 2000-2007 Fabrice Bellard, et al.
  configuration: --enable-gpl --enable-pp --enable-swscaler --enable-pthreads --enable-libvorbis --enable-libtheora --enable-libogg --enable-libgsm --enable-dc1394 --disable-debug --enable-libmp3lame --enable-libfaadbin --enable-libfaad --enable-libfaac --enable-xvid --enable-x264 --enable-liba52 --enable-amr_nb --enable-amr_wb --enable-shared --prefix=/usr
  libavutil version: 1d.49.3.0
  libavcodec version: 1d.51.38.0
  libavformat version: 1d.51.10.0
  built on May  1 2010 18:17:41, gcc: 4.2.4 (Ubuntu 4.2.4-1ubuntu4)
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '/home/lxuser/Desktop/sample.mp4':
  Duration: 00:00:11.0, start: 0.000000, bitrate: 18 kb/s
  Stream #0.0(und): Audio: amr_nb, 8000 Hz, mono
  Stream #0.1(und): Video: mpeg4, yuv420p, 160x120, 30.00 fps(r)
Must supply at least one output file
09:09:07 ~ $ffmpeg -i ~/Desktop/friends.mp4
FFmpeg version SVN-rUNKNOWN, Copyright (c) 2000-2007 Fabrice Bellard, et al.
  configuration: --enable-gpl --enable-pp --enable-swscaler --enable-pthreads --enable-libvorbis --enable-libtheora --enable-libogg --enable-libgsm --enable-dc1394 --disable-debug --enable-libmp3lame --enable-libfaadbin --enable-libfaad --enable-libfaac --enable-xvid --enable-x264 --enable-liba52 --enable-amr_nb --enable-amr_wb --enable-shared --prefix=/usr
  libavutil version: 1d.49.3.0
  libavcodec version: 1d.51.38.0
  libavformat version: 1d.51.10.0
  built on May  1 2010 18:17:41, gcc: 4.2.4 (Ubuntu 4.2.4-1ubuntu4)
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '/home/lxuser/Desktop/friends.mp4':
  Duration: 00:00:44.3, start: 0.000000, bitrate: 238 kb/s
  Stream #0.0(und): Video: mpeg4, yuv420p, 160x120, 30.00 fps(r)
  Stream #0.1(und): Audio: amr_nb, 8000 Hz, mono
Must supply at least one output file

All i can see difference is order of audio & video stream.
What should i do ?

fruttenboel 07-02-2010 03:20 PM

syntax for ffmpeg:

Code:

ffmpeg -i /path/to/infile.extension outfile
I did not see an outfile in your command lines...

sumeet inani 07-05-2010 04:32 AM

here I am comparing two mp4 files .
One created by mobile & other on computer .
i am showing that codec & other parameters of both file are same (except order of audio & video stream) . Yet , computer file does not play in mobile which says 'unsupported content'

sumeet inani 07-28-2010 01:39 AM

Here is my question with more info
I got 2 samples of mobile encoded file & analysed it to conclude that it should have following
Code:

Metadata:
major_brand    : 3gp4
    minor_version  : 512
    compatible_brands: 3gp4
Stream #0.0(und): Audio: amrnb, 8000 Hz, 1 channels, flt, 12 kb/s
tream #0.1(und): Video: mpeg4, yuv420p, 160x120 [PAR 12:11 DAR 16:11], sth kb/s, PAR 1:1 DAR 4:3, sth fps, 30 tbr, 1k tbn, 30 tbc

But the video I encoded using ffmpeg says
Code:

Metadata:
    major_brand    : isom
    minor_version  : 512
    compatible_brands: mp41
    Stream #0.0(und): Video: mpeg4, yuv420p, 160x120 [PAR 1:1 DAR 4:3], 224 kb/s, 25 fps, 25 tbr, 25 tbn, 25 tbc
    Stream #0.1(und): Audio: amrnb, 8000 Hz, 1 channels, flt, 12 kb/s

Coloured ones are differences . How Can i iron them out ?

sumeet inani 07-30-2010 12:11 AM

now I have further perused/scrutinised media info .
Code:

Format profile : Base Media to 3GPP Media Release 4
Codec ID : isom to 3gp4
video
id : 1 to 2
Format settings, BVOP : no to color=red]Yes[/color]
Bit rate mode : Variable to constant
Nominal bit rate : 128 Kbps
Original display aspect ratio : 3:2 (though dar=4:3 is satisfied by ffmpeg)
Frame rate mode : constant to Variable
Minimum frame rate : 7.463 fps

Maximum frame rate : 15.152 fps
Audio

ID : 2 to 1

I tried '-b 128k -minrate 128k -maxrate 128k -bufsize 256k -r 8' . That helped.
Now question reamins about interchanging order of video 7 audio in output ?


All times are GMT -5. The time now is 12:42 AM.