[FFmpeg-user] Need help with converting a h.264 3gp file to h.263 3gp

Mani Goswami mani.goswami at gmail.com
Fri Jul 20 21:09:41 CEST 2012


Thanks Michael for your response. But even that don't seem to work. Here is
the response:

[manig at littlefamous-dr movies]$ sudo ffmpeg -i
video_9BtjFG12DsMs1dtY.rSjshKA7AUtRJKTp6dbFubOxk92gcYmcNEeSf1ZV2EPZehAg.tuopOx_wI-_0.3gp
-b:v 64k -vcodec h263 -acodec aac -s 240x300 -strict experimental
newgph263.3gp
ffmpeg version N-42690-gb34ce5a Copyright (c) 2000-2012 the FFmpeg
developers
  built on Jul 20 2012 16:34:40 with gcc 4.1.2 (GCC) 20070626 (Red Hat
4.1.2-14)
  configuration:
  libavutil      51. 65.100 / 51. 65.100
  libavcodec     54. 42.100 / 54. 42.100
  libavformat    54. 17.101 / 54. 17.101
  libavdevice    54.  1.100 / 54.  1.100
  libavfilter     3.  2.100 /  3.  2.100
  libswscale      2.  1.100 /  2.  1.100
  libswresample   0. 15.100 /  0. 15.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from
'video_9BtjFG12DsMs1dtY.rSjshKA7AUtRJKTp6dbFubOxk92gcYmcNEeSf1ZV2EPZehAg.tuopOx_wI-_0.3gp':
  Metadata:
    major_brand     : 3gp5
    minor_version   : 0
    compatible_brands: 3gp53gp4mp41mp42isom
    creation_time   : 1942-05-31 01:31:41
  Duration: 00:01:10.33, start: 0.000000, bitrate: 88 kb/s
    Stream #0:0(eng): Audio: aac (mp4a / 0x6134706D), 16000 Hz, mono, s16,
15 kb/s
    Metadata:
      creation_time   : 1942-05-31 01:31:41
      handler_name    : Apple Sound Media Handler
    Stream #0:1(eng): Video: mpeg4 (Simple Profile) (mp4v / 0x7634706D),
yuv420p, 240x302 [SAR 1:1 DAR 120:151], 65 kb/s, SAR 12:11 DAR 1440:1661,
10 fps, 10 tbr, 10 tbn, 1k tbc
    Metadata:
      creation_time   : 1942-05-31 01:31:41
      handler_name    : Apple Video Media Handler
    Stream #0:2(und): Data: none (rtp  / 0x20707472)
    Metadata:
      creation_time   : 1942-05-30 00:34:36
      handler_name    : GPAC ISO Hint Handler
    Stream #0:3(und): Data: none (rtp  / 0x20707472)
    Metadata:
      creation_time   : 1942-05-30 00:34:36
      handler_name    : GPAC ISO Hint Handler
File 'newgph263.3gp' already exists. Overwrite ? [y/N] y
Invalid pixel aspect ratio 1800/1661, limit is 255/255 reducing
[h263 @ 0x9904080] The specified picture size of 240x300 is not valid for
the H.263 codec.
Valid sizes are 128x96, 176x144, 352x288, 704x576, and 1408x1152. Try
H.263+.
Output #0, 3gp, to 'newgph263.3gp':
  Metadata:
    major_brand     : 3gp5
    minor_version   : 0
    compatible_brands: 3gp53gp4mp41mp42isom
    Stream #0:0(eng): Video: h263, yuv420p, 240x300 [SAR 246:227 DAR
984:1135], q=2-31, 64 kb/s, SAR 1800:1661 DAR 1440:1661, 90k tbn, 10 tbc
    Metadata:
      creation_time   : 1942-05-31 01:31:41
      handler_name    : Apple Video Media Handler
    Stream #0:1(eng): Audio: none, 16000 Hz, mono, flt, 128 kb/s
    Metadata:
      creation_time   : 1942-05-31 01:31:41
      handler_name    : Apple Sound Media Handler
Stream mapping:
  Stream #0:1 -> #0:0 (mpeg4 -> h263)
  Stream #0:0 -> #0:1 (aac -> aac)
Error while opening encoder for output stream #0:0 - maybe incorrect
parameters such as bit_rate, rate, width or height


Also, if I try picking any of the one size recommended, I get to see
following error:

[manig at littlefamous-dr movies]$ sudo ffmpeg -i
video_9BtjFG12DsMs1dtY.rSjshKA7AUtRJKTp6dbFubOxk92gcYmcNEeSf1ZV2EPZehAg.tuopOx_wI-_0.3gp
-b:v 64k -vcodec h263 -acodec aac -s 128x96 -strict experimental
newgph263.3gp
ffmpeg version N-42690-gb34ce5a Copyright (c) 2000-2012 the FFmpeg
developers
  built on Jul 20 2012 16:34:40 with gcc 4.1.2 (GCC) 20070626 (Red Hat
4.1.2-14)
  configuration:
  libavutil      51. 65.100 / 51. 65.100
  libavcodec     54. 42.100 / 54. 42.100
  libavformat    54. 17.101 / 54. 17.101
  libavdevice    54.  1.100 / 54.  1.100
  libavfilter     3.  2.100 /  3.  2.100
  libswscale      2.  1.100 /  2.  1.100
  libswresample   0. 15.100 /  0. 15.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from
'video_9BtjFG12DsMs1dtY.rSjshKA7AUtRJKTp6dbFubOxk92gcYmcNEeSf1ZV2EPZehAg.tuopOx_wI-_0.3gp':
  Metadata:
    major_brand     : 3gp5
    minor_version   : 0
    compatible_brands: 3gp53gp4mp41mp42isom
    creation_time   : 1942-05-31 01:31:41
  Duration: 00:01:10.33, start: 0.000000, bitrate: 88 kb/s
    Stream #0:0(eng): Audio: aac (mp4a / 0x6134706D), 16000 Hz, mono, s16,
15 kb/s
    Metadata:
      creation_time   : 1942-05-31 01:31:41
      handler_name    : Apple Sound Media Handler
    Stream #0:1(eng): Video: mpeg4 (Simple Profile) (mp4v / 0x7634706D),
yuv420p, 240x302 [SAR 1:1 DAR 120:151], 65 kb/s, SAR 12:11 DAR 1440:1661,
10 fps, 10 tbr, 10 tbn, 1k tbc
    Metadata:
      creation_time   : 1942-05-31 01:31:41
      handler_name    : Apple Video Media Handler
    Stream #0:2(und): Data: none (rtp  / 0x20707472)
    Metadata:
      creation_time   : 1942-05-30 00:34:36
      handler_name    : GPAC ISO Hint Handler
    Stream #0:3(und): Data: none (rtp  / 0x20707472)
    Metadata:
      creation_time   : 1942-05-30 00:34:36
      handler_name    : GPAC ISO Hint Handler
File 'newgph263.3gp' already exists. Overwrite ? [y/N] y
Invalid pixel aspect ratio 1080/1661, limit is 255/255 reducing
[aac @ 0xa7e3f20] Too many bits per frame requested
Output #0, 3gp, to 'newgph263.3gp':
  Metadata:
    major_brand     : 3gp5
    minor_version   : 0
    compatible_brands: 3gp53gp4mp41mp42isom
    Stream #0:0(eng): Video: h263, yuv420p, 128x96 [SAR 158:243 DAR
632:729], q=2-31, 64 kb/s, SAR 1080:1661 DAR 1440:1661, 90k tbn, 10 tbc
    Metadata:
      creation_time   : 1942-05-31 01:31:41
      handler_name    : Apple Video Media Handler
    Stream #0:1(eng): Audio: aac, 16000 Hz, mono, flt, 128 kb/s
    Metadata:
      creation_time   : 1942-05-31 01:31:41
      handler_name    : Apple Sound Media Handler
Stream mapping:
  Stream #0:1 -> #0:0 (mpeg4 -> h263)
  Stream #0:0 -> #0:1 (aac -> aac)
Error while opening encoder for output stream #0:1 - maybe incorrect
parameters such as bit_rate, rate, width or height

Regards,
Mani

On Sat, Jul 21, 2012 at 12:32 AM, Michael Bradshaw <
mbradshaw at sorensonmedia.com> wrote:

> On Fri, Jul 20, 2012 at 12:51 PM, Mani Goswami <mani.goswami at gmail.com>
> wrote:
> > Here is the complete console output:
> >
> > [manig at littlefamous-dr movies]$ sudo ffmpeg -i
> >
> video_9BtjFG12DsMs1dtY.rSjshKA7AUtRJKTp6dbFubOxk92gcYmcNEeSf1ZV2EPZehAg.tuopOx_wI-_0.3gp
> > -b:v 64k -vcodec h263 -acodec aac  -strict experimental newgph263.3gp
> > Password:
> > ffmpeg version N-42690-gb34ce5a Copyright (c) 2000-2012 the FFmpeg
> > developers
> >   built on Jul 20 2012 16:34:40 with gcc 4.1.2 (GCC) 20070626 (Red Hat
> > 4.1.2-14)
> >   configuration:
> >   libavutil      51. 65.100 / 51. 65.100
> >   libavcodec     54. 42.100 / 54. 42.100
> >   libavformat    54. 17.101 / 54. 17.101
> >   libavdevice    54.  1.100 / 54.  1.100
> >   libavfilter     3.  2.100 /  3.  2.100
> >   libswscale      2.  1.100 /  2.  1.100
> >   libswresample   0. 15.100 /  0. 15.100
> > Input #0, mov,mp4,m4a,3gp,3g2,mj2, from
> >
> 'video_9BtjFG12DsMs1dtY.rSjshKA7AUtRJKTp6dbFubOxk92gcYmcNEeSf1ZV2EPZehAg.tuopOx_wI-_0.3gp':
> >   Metadata:
> >     major_brand     : 3gp5
> >     minor_version   : 0
> >     compatible_brands: 3gp53gp4mp41mp42isom
> >     creation_time   : 1942-05-31 01:31:41
> >   Duration: 00:01:10.33, start: 0.000000, bitrate: 88 kb/s
> >     Stream #0:0(eng): Audio: aac (mp4a / 0x6134706D), 16000 Hz, mono,
> s16,
> > 15 kb/s
> >     Metadata:
> >       creation_time   : 1942-05-31 01:31:41
> >       handler_name    : Apple Sound Media Handler
> >     Stream #0:1(eng): Video: mpeg4 (Simple Profile) (mp4v / 0x7634706D),
> > yuv420p, 240x302 [SAR 1:1 DAR 120:151], 65 kb/s, SAR 12:11 DAR 1440:1661,
> > 10 fps, 10 tbr, 10 tbn, 1k tbc
> >     Metadata:
> >       creation_time   : 1942-05-31 01:31:41
> >       handler_name    : Apple Video Media Handler
> >     Stream #0:2(und): Data: none (rtp  / 0x20707472)
> >     Metadata:
> >       creation_time   : 1942-05-30 00:34:36
> >       handler_name    : GPAC ISO Hint Handler
> >     Stream #0:3(und): Data: none (rtp  / 0x20707472)
> >     Metadata:
> >       creation_time   : 1942-05-30 00:34:36
> >       handler_name    : GPAC ISO Hint Handler
> > File 'newgph263.3gp' already exists. Overwrite ? [y/N] y
> > w/h must be a multiple of 4
>
> Console output says w/h needs to be a multiple of 4. Your height is
> 302. You either need to a) crop it down to 300, b) pad it to 304, or
> c) squish/stretch it to 300 or 304 by setting -s 240x300 (or -s
> 240x304).
>
> --Michael
> _______________________________________________
> ffmpeg-user mailing list
> ffmpeg-user at ffmpeg.org
> http://ffmpeg.org/mailman/listinfo/ffmpeg-user
>



-- 
Mani Shankar Goswami


More information about the ffmpeg-user mailing list