logo       

Re: Strange problem working with sound: msg#00207

video.ffmpeg.user

Subject: Re: Strange problem working with sound

Hi

Having eliminated the compiling problems, I revisit the problem again.
The problem is still the same, no sound if I specify my own audio
parameter; whereas sound ok when using "-target dvd":

On Sat, 22 Apr 2006 23:01:22 -0400, T wrote:

> I want to change the sound of VTS_06_1.VOB from mp2 to ac3, so I did:
>
> /opt/new/bin/ffmpeg -i "VTS_06_1.VOB" -acodec ac3 -ab 224 -ar 48000 -ac 2
> -vcodec copy -ss 0:6:50 -vframes 3000 "VTS_06_1.copy.mpg"
>
> the /opt/new/bin/ffmpeg is the ffmpeg that I grab & build from cvs today.
>
> What's weired is that there is no sound in the result file (when played with
> VLC). The work log and result check is as followed:

$ ffmpeg -i "VTS_06_1.VOB" -acodec ac3 -ab 224 -ar 48000 -ac 2 -vcodec copy -ss
0:6:50 -vframes 3000 "VTS_06_1.copy.mpg"
FFmpeg version CVS, Copyright (c) 2000-2004 Fabrice Bellard
configuration: --prefix=/opt/new --libdir=${prefix}/lib
--incdir=${prefix}/include/ffmpeg --mandir=${prefix}/share/man --enable-shared
--enable-pthreads --enable-gpl --disable-bktr --disable-dv1394
--disable-network --disable-simple_idct --disable-ffserver
libavutil version: 49.0.0
libavcodec version: 51.9.0
libavformat version: 50.4.0
built on Apr 24 2006 11:20:15, gcc: 3.3.5 (Debian 1:3.3.5-13)
Input #0, mpeg, from 'VTS_06_1.VOB':
Duration: 00:41:09.3, start: 0.280633, bitrate: 2887 kb/s
Stream #0.0[0x1e0], 29.97 fps(r): Video: mpeg2video, yuv420p, 352x480, 2600
kb/s
Stream #0.1[0x1c0]: Audio: mp2, 48000 Hz, stereo, 192 kb/s
File 'VTS_06_1.copy.mpg' already exists. Overwrite ? [y/N] y
Output #0, mpeg, to 'VTS_06_1.copy.mpg':
Stream #0.0, 29.97 fps(c): Video: mpeg2video, yuv420p, 352x480, q=2-31, 2600
kb/s
Stream #0.1: Audio: ac3, 48000 Hz, stereo, 224 kb/s
Stream mapping:
Stream #0.0 -> #0.0
Stream #0.1 -> #0.1
frame= 3000 q=-9099599.8 Lsize= 34702kB time=100.1 bitrate=2839.2kbits/s
video:31772kB audio:2738kB global headers:0kB muxing overhead 0.557089%

If checking with tcprobe, it reports no audio/video.

$ tcprobe -i VTS_06_1.copy.mpg
[tcprobe] MPEG program stream (PS)

[tcprobe] summary for VTS_06_1.copy.mpg, (*) = not default, 0 = not detected
no audio track: use "null" import module for audio

If checking with ffmpeg, it reports that the audio stream is of type
0x0000, and it comes before the video stream:

$ ffmpeg -i VTS_06_1.copy.mpg
FFmpeg version CVS, Copyright (c) 2000-2004 Fabrice Bellard
configuration: --prefix=/opt/new --libdir=${prefix}/lib
--incdir=${prefix}/include/ffmpeg --mandir=${prefix}/share/man --enable-shared
--enable-pthreads --enable-gpl --disable-bktr --disable-dv1394
--disable-network --disable-simple_idct --disable-ffserver
libavutil version: 49.0.0
libavcodec version: 51.9.0
libavformat version: 50.4.0
built on Apr 24 2006 11:20:15, gcc: 3.3.5 (Debian 1:3.3.5-13)
Seems that stream 1 comes from film source: inf (1/0) -> nan (0/0)
Input #0, mpeg, from 'VTS_06_1.copy.mpg':
Duration: N/A, start: 0.500000, bitrate: N/A
Stream #0.0[0x80]: Audio: 0x0000, 48000 Hz, stereo, 224 kb/s
Stream #0.1[0x1e0], inf fps(c): Video: mpeg2video

What's wrong?

If I convert the video as well, like the following, there is still no
sound:

ffmpeg -i "VTS_06_1.VOB" -acodec ac3 -ab 224 -ar 48000 -ac 2 -vcodec mpeg2video
-sameq -maxrate 4500 -bufsize 1792 -ss 0:6:50 -vframes 3000 "VTS_06_1.mpg"

The order of the video/audio stream is correct, just that the audio ID is
still wrong:

$ ffmpeg -i VTS_06_1.mpg
FFmpeg version CVS, Copyright (c) 2000-2004 Fabrice Bellard
configuration: --prefix=/opt/new --libdir=${prefix}/lib
--incdir=${prefix}/include/ffmpeg --mandir=${prefix}/share/man --enable-shared
--enable-pthreads --enable-gpl --disable-bktr --disable-dv1394
--disable-network --disable-simple_idct --disable-ffserver
libavutil version: 49.0.0
libavcodec version: 51.9.0
libavformat version: 50.4.0
built on Apr 24 2006 11:20:15, gcc: 3.3.5 (Debian 1:3.3.5-13)
Input #0, mpeg, from 'VTS_06_1.mpg':
Duration: 00:01:39.6, start: 0.500000, bitrate: 4662 kb/s
Stream #0.0[0x1e0], 29.97 fps(r): Video: mpeg2video, yuv420p, 352x480, 4500
kb/s
Stream #0.1[0x80]: Audio: 0x0000, 48000 Hz, stereo, 224 kb/s
Must supply at least one output file

The following still holds:

> PS. If I use "-target dvd", then everything is ok:
>
> /opt/new/bin/ffmpeg -i "VTS_06_1.VOB" -target dvd -ss 0:6:50 -vframes
> 3000 "VTS_06_1.dvd.mpg"
>
> The reason that I want to specify audio parameter myself is that - the
> source video is already dvd compatible - I want to keep the original
> frame size, which is 352x480
>
> $ ffmpeg -i VTS_06_1.VOB
> ffmpeg version cvs, build 4753, Copyright (c) 2000-2004 Fabrice Bellard
> configuration: --prefix=/usr --libdir=${prefix}/lib --enable-shared
> --enable-mp3lame --host=i386-linux --enable-gpl --build=i386-linux
> --enable-faad --mandir=${prefix}/share/man --enable-vorbis
> --enable-pthreads --enable-faac --enable-xvid --enable-dts cc
> --enable-amr_nb --enable-amr_wb --enable-pp --enable-shared-pp
> --enable-libogg --enable-a52bin --enable-x264 built on Jun 9 2005
> 15:41:29, gcc: 3.3.5 (Debian 1:3.3.5-13)
> Input #0, mpeg, from 'VTS_06_1.VOB':
> Duration: 00:41:09.3, start: 0.280633, bitrate: 2887 kb/s Stream #0.0:
> Video: mpeg2video, yuv420p, 352x480, 29.97 fps, 2600 kb/s Stream #0.1:
> Audio: mp2, 48000 Hz, stereo, 192 kb/s
>
> How can I specify my own audio parameter to covert the sound, and left
> the video intact?
>
> thanks a lot
>
> tong


<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise