Find the answer to your Linux question:
Results 1 to 7 of 7
Hi! Tried to search in our forums for .3gp conversion to mp4 but did not get anything particular to my question. I am trying to convert some videos taken from ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Linux Engineer nujinini's Avatar
    Join Date
    Apr 2009
    Posts
    1,272

    Convert .3gp to mp4 Using ffmpeg


    Hi!

    Tried to search in our forums for .3gp conversion to mp4 but did not get anything particular to my question.

    I am trying to convert some videos taken from my sons graduation yesterday. I tried to play the video and was surprised to find it in .3gp and there was no sound in the playback when played in my laptop.

    Here are my output.


    Code:
    jun@jun-laptop:~$ ffmpeg -i '/home/jun/Desktop/VID_20110319_140701.3gp' -s vga '/home/jun/Desktop/VID_20110319_140701.mp4' 
    FFmpeg version 0.5-svn17737+3:0.svn20090303-1ubuntu6.2, Copyright (c) 2000-2009 Fabrice Bellard, et al.
      configuration: --enable-gpl --enable-postproc --enable-swscale --enable-x11grab --extra-version=svn17737+3:0.svn20090303-1ubuntu6.2 --prefix=/usr --enable-avfilter --enable-avfilter-lavf --enable-libgsm --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-libvorbis --enable-pthreads --disable-stripping --disable-vhook --enable-libdc1394 --disable-armv5te --disable-armv6 --disable-armv6t2 --disable-armvfp --disable-neon --disable-altivec --disable-vis --enable-shared --disable-static
      libavutil     49.15. 0 / 49.15. 0
      libavcodec    52.20. 0 / 52.20. 0
      libavformat   52.31. 0 / 52.31. 0
      libavdevice   52. 1. 0 / 52. 1. 0
      libavfilter    0. 4. 0 /  0. 4. 0
      libswscale     0. 7. 1 /  0. 7. 1
      libpostproc   51. 2. 0 / 51. 2. 0
      built on Apr 23 2010 15:08:34, gcc: 4.3.3
    Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '/home/jun/Desktop/VID_20110319_140701.3gp':
      Duration: 00:00:48.28, start: 0.000000, bitrate: 1000 kb/s
        Stream #0.0(eng): Video: mpeg4, yuv420p, 640x480 [PAR 1:1 DAR 4:3], 60 tbr, 1k tbn, 60 tbc
        Stream #0.1(eng): Audio: samr / 0x726D6173, 8000 Hz, mono, s16
    Output #0, mp4, to '/home/jun/Desktop/VID_20110319_140701.mp4':
        Stream #0.0(eng): Video: 0x0000, yuv420p, 640x480 [PAR 1:1 DAR 4:3], q=2-31, 200 kb/s, 90k tbn, 60 tbc
        Stream #0.1(eng): Audio: 0x0000, 8000 Hz, mono, s16, 64 kb/s
    Stream mapping:
      Stream #0.0 -> #0.0
      Stream #0.1 -> #0.1
    Unsupported codec for output stream #0.0
    jun@jun-laptop:~$
    Can somebody kindly help me understand what I've been missing please?

    Thanks!
    nujinini
    Linux User #489667

  2. #2
    Trusted Penguin Dapper Dan's Avatar
    Join Date
    Oct 2004
    Location
    The Sovereign State of South Carolina
    Posts
    4,630
    There might be something here that will help you get it sorted.
    Linux Mint + IceWM Registered: #371367 New Members: click here

  3. #3
    Linux Guru Rubberman's Avatar
    Join Date
    Apr 2009
    Location
    I can be found either 40 miles west of Chicago, in Chicago, or in a galaxy far, far away.
    Posts
    11,633
    Why not convert it to mpeg2 (-target ntsc-dvd)? Anything can play that. In any case, I haven't had any problems converting to/from mpeg4, but the error indicates that your ffmpeg version has not been compiled with the mpeg4 encoder. Since the source is actually in mpeg4, it obviously has a decoder (different beast).

    So, how did you install your ffmpeg? From a package repository (binary), or from source? I usually build from source so I can configure it to suit my needs. I've had problems with the pre-compiled versions in the past, similar to yours.
    Sometimes, real fast is almost as good as real time.
    Just remember, Semper Gumbi - always be flexible!

  4. #4
    Linux Engineer nujinini's Avatar
    Join Date
    Apr 2009
    Posts
    1,272
    Quote Originally Posted by Rubberman View Post
    So, how did you install your ffmpeg? From a package repository (binary), or from source? I usually build from source so I can configure it to suit my needs. I've had problems with the pre-compiled versions in the past, similar to yours.
    I installed it by:

    Code:
    $ sudo aptitude install ffmpeg
    I'm sorry but I don't know how to answer if I got it from binary or from source. Can you please tell me where I should start if I try to build it from source too? Perhaps I can configure it to suit my needs, if ever.
    nujinini
    Linux User #489667

  5. #5
    Linux Guru Rubberman's Avatar
    Join Date
    Apr 2009
    Location
    I can be found either 40 miles west of Chicago, in Chicago, or in a galaxy far, far away.
    Posts
    11,633
    Installing with Aptitude, you got the pre-compiled binaries. You can also download the sources and build them on your system, but you will need the development versions of a number of packages (mostly for the header files). You can get the ffmpeg source from here: Get FFmpeg
    Sometimes, real fast is almost as good as real time.
    Just remember, Semper Gumbi - always be flexible!

  6. #6
    Just Joined!
    Join Date
    Apr 2014
    Posts
    1
    I find some solution from Videohelp forum. I'm sorry if it's not related with ffmpeg, since i have no idea about it. I tried two of them - Faasoft Video Converter and VLC and they all seems to work well. I prefer to use them to convert 3GP to MP4 rather than ffmpeg.

  7. #7
    Linux Guru Rubberman's Avatar
    Join Date
    Apr 2009
    Location
    I can be found either 40 miles west of Chicago, in Chicago, or in a galaxy far, far away.
    Posts
    11,633
    For simple stuff Faasoft and VLC may be adequate (use VLC for most of my media play), but if you have any complex stuff to do, such as convert mp3 audio in a video to ac3, then ffmpeg is the ticket. The options are daunting, and will take time to learn. Myself, 99% of the time I can generate a DVD compatible mpeg2 file with this: ffmpeg -i inputfile -target ntsc-dvd -q 0 -async 20 outputfile.mpg

    What does that mean? -target ntsc-dvd says that the output is to be an NTSC dvd compatible format. If you are in Europe and need PAL output, then change that to -target pal-dvd. The -q 0 means to keep the same quality as the source for the output, and the -async 20 means to sync the audio every 20 milliseconds - a good option if the audio gets out of sync with the video, which is not too uncommon.
    Sometimes, real fast is almost as good as real time.
    Just remember, Semper Gumbi - always be flexible!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •