Sanyo FH1 - MP4 / AVC1 / H264 - pts < dts
So I had a thought. Swap out the camcorder audio for a different audio track. Then put it back on the camcorder and play it. But.... $ ffmpeg -an -i ./sany0001.mp4 -vcodec copy -y video_only.mp4 FFmpeg version git-ed22f90, Copyright (c) 2000-2009 Fabrice Bellard, et al. built on Jan 11 2010 13:42:28 with gcc 4.3.2 configuration: --prefix=/usr --enable-shared --enable-gpl --enable-nonfree --enable-postproc --enable-avfilter --enable-avfilter-lavf --enable-pthreads --enable-x11grab --enable-gray --enable-small --disable-libdirac --disable-libschroedinger --enable-libfaac --enable-libfaad --enable-libmp3lame --enable-libxvid --enable-libx264 --enable-libtheora --enable-libvorbis libavutil 50. 3. 0 / 50. 3. 0 libavcodec 52.36. 0 / 52.36. 0 libavformat 52.39. 0 / 52.39. 0 libavdevice 52. 2. 0 / 52. 2. 0 libavfilter 0. 5. 0 / 0. 5. 0 libswscale 0. 7. 1 / 0. 7. 1 libpostproc 51. 2. 0 / 51. 2. 0 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=0, dts=1001, size=144 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=2002, dts=3003, size=31624 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=4004, dts=5005, size=38968 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=6006, dts=7007, size=32880 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=8008, dts=9009, size=10928 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=10010, dts=11011, size=16488 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=12012, dts=13013, size=17912 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=14014, dts=15015, size=23280 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=16016, dts=17017, size=33376 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=18018, dts=19019, size=38000 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=20020, dts=21021, size=23528 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=22022, dts=23023, size=23328 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=24024, dts=25025, size=32944 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=26026, dts=27027, size=37504 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=28028, dts=29029, size=22360 Seems stream 0 codec frame rate differs from container frame rate: 119.88 (120000/1001) -> 59.94 (60000/1001) Input #0, mov,mp4,m4a,3gp,3g2,mj2, from './FH1_video/sany1108.mp4': Duration: 00:17:58.79, start: 0.000000, bitrate: 24157 kb/s Stream #0.0(eng): Video: h264, yuv420p, 1920x1080 [PAR 1:1 DAR 16:9], 59.94 tbr, 60k tbn, 119.88 tbc Stream #0.1(eng): Audio: aac, 48000 Hz, 2 channels, s16 Metadata major_brand : mp42 minor_version : 1 compatible_brands: mp42avc1 comment : SANYO DIGITAL CAMERA FH1 comment-eng : SANYO DIGITAL CAMERA FH1 Output #0, mp4, to 'wgm.mp4': Stream #0.0(eng): Video: libx264, yuv420p, 1920x1080 [PAR 1:1 DAR 16:9], q=2-31, 120k tbn, 59.94 tbc Stream mapping: Stream #0.0 -> #0.0 Press [q] to stop encoding [NULL @ 0x8071730]error, pts < dts av_interleaved_write_frame(): Error while opening file ??????? [NULL @ 0x8071730]error, pts < dts av_interleaved_write_frame(): Error while opening file ??????? Presentation timestamp before Decode timestamp is what I'm assuming this means. It's generated from a camcorder, so how / why would that be? This is video from a camcorder so I can't really change that. I am able to decode and re-encode to other formats with a lot of invalid timestamp errors. Although the output seems fine. I am able to extract audio only with -acodec copy. But I can't seem to extract video only with -vcodec copy. Any hints? The plan was to: ffmpeg -vn -i sany0001.mp4 -acodec copy -y audio.aac ffmpeg -an -i sany0001.mp4 -vcodec copy -y video.mp4 then swap out the audio.aac for an equivalent but different audio track. Same length, same specs. And then. ffmpeg -i video.mp4 -i new_audio.aac -vcodec copy -acodec copy -y new_sany0001.mp4 But I can't seem to get the video only part. Ffmpeg -i for the source says this: $ ffmpeg -i sany1108.mp4 FFmpeg version git-ed22f90, Copyright (c) 2000-2009 Fabrice Bellard, et al. built on Jan 11 2010 13:42:28 with gcc 4.3.2 configuration: --prefix=/usr --enable-shared --enable-gpl --enable-nonfree --enable-postproc --enable-avfilter --enable-avfilter-lavf --enable-pthreads --enable-x11grab --enable-gray --enable-small --disable-libdirac --disable-libschroedinger --enable-libfaac --enable-libfaad --enable-libmp3lame --enable-libxvid --enable-libx264 --enable-libtheora --enable-libvorbis libavutil 50. 3. 0 / 50. 3. 0 libavcodec 52.36. 0 / 52.36. 0 libavformat 52.39. 0 / 52.39. 0 libavdevice 52. 2. 0 / 52. 2. 0 libavfilter 0. 5. 0 / 0. 5. 0 libswscale 0. 7. 1 / 0. 7. 1 libpostproc 51. 2. 0 / 51. 2. 0 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=0, dts=1001, size=144 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=2002, dts=3003, size=31624 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=4004, dts=5005, size=38968 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=6006, dts=7007, size=32880 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=8008, dts=9009, size=10928 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=10010, dts=11011, size=16488 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=12012, dts=13013, size=17912 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=14014, dts=15015, size=23280 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=16016, dts=17017, size=33376 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=18018, dts=19019, size=38000 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=20020, dts=21021, size=23528 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=22022, dts=23023, size=23328 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=24024, dts=25025, size=32944 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=26026, dts=27027, size=37504 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=28028, dts=29029, size=22360 Seems stream 0 codec frame rate differs from container frame rate: 119.88 (120000/1001) -> 59.94 (60000/1001) Input #0, mov,mp4,m4a,3gp,3g2,mj2, from './FH1_video/sany1108.mp4': Duration: 00:17:58.79, start: 0.000000, bitrate: 24157 kb/s Stream #0.0(eng): Video: h264, yuv420p, 1920x1080 [PAR 1:1 DAR 16:9], 59.94 tbr, 60k tbn, 119.88 tbc Stream #0.1(eng): Audio: aac, 48000 Hz, 2 channels, s16 Metadata major_brand : mp42 minor_version : 1 compatible_brands: mp42avc1 comment : SANYO DIGITAL CAMERA FH1 comment-eng : SANYO DIGITAL CAMERA FH1 At least one output file must be specified Why all this hassle you ask. 1080p60. At the moment said camcorder (Sanyo FH1) is the only device I have capable of playing it in realtime and outputting a signal compatible with the HDTV in Full HD. If I could get that to work, it might prove interesting. Just a thought, any hints to make it work? Should I file a bug report? Is there one already? Is it fixed in the latest svn? I'm current as of 10/5/2009. Thanks, - James
Hi, On 01/25/2010 08:51 AM, James Shatto wrote:
So I had a thought. Swap out the camcorder audio for a different audio track. Then put it back on the camcorder and play it. But....
$ ffmpeg -an -i ./sany0001.mp4 -vcodec copy -y video_only.mp4
FFmpeg version git-ed22f90, Copyright (c) 2000-2009 Fabrice Bellard, et al. built on Jan 11 2010 13:42:28 with gcc 4.3.2 configuration: --prefix=/usr --enable-shared --enable-gpl --enable-nonfree --enable-postproc --enable-avfilter --enable-avfilter-lavf --enable-pthreads --enable-x11grab --enable-gray --enable-small --disable-libdirac --disable-libschroedinger --enable-libfaac --enable-libfaad --enable-libmp3lame --enable-libxvid --enable-libx264 --enable-libtheora --enable-libvorbis libavutil 50. 3. 0 / 50. 3. 0 libavcodec 52.36. 0 / 52.36. 0 libavformat 52.39. 0 / 52.39. 0 libavdevice 52. 2. 0 / 52. 2. 0 libavfilter 0. 5. 0 / 0. 5. 0 libswscale 0. 7. 1 / 0. 7. 1 libpostproc 51. 2. 0 / 51. 2. 0 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=0, dts=1001, size=144 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=2002, dts=3003, size=31624 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=4004, dts=5005, size=38968 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=6006, dts=7007, size=32880 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=8008, dts=9009, size=10928 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=10010, dts=11011, size=16488 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=12012, dts=13013, size=17912 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=14014, dts=15015, size=23280 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=16016, dts=17017, size=33376 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=18018, dts=19019, size=38000 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=20020, dts=21021, size=23528 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=22022, dts=23023, size=23328 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=24024, dts=25025, size=32944 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=26026, dts=27027, size=37504 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=28028, dts=29029, size=22360
Seems stream 0 codec frame rate differs from container frame rate: 119.88 (120000/1001) -> 59.94 (60000/1001) Input #0, mov,mp4,m4a,3gp,3g2,mj2, from './FH1_video/sany1108.mp4': Duration: 00:17:58.79, start: 0.000000, bitrate: 24157 kb/s Stream #0.0(eng): Video: h264, yuv420p, 1920x1080 [PAR 1:1 DAR 16:9], 59.94 tbr, 60k tbn, 119.88 tbc Stream #0.1(eng): Audio: aac, 48000 Hz, 2 channels, s16 Metadata major_brand : mp42 minor_version : 1 compatible_brands: mp42avc1 comment : SANYO DIGITAL CAMERA FH1 comment-eng : SANYO DIGITAL CAMERA FH1 Output #0, mp4, to 'wgm.mp4': Stream #0.0(eng): Video: libx264, yuv420p, 1920x1080 [PAR 1:1 DAR 16:9], q=2-31, 120k tbn, 59.94 tbc Stream mapping: Stream #0.0 -> #0.0 Press [q] to stop encoding [NULL @ 0x8071730]error, pts< dts av_interleaved_write_frame(): Error while opening file
[...]
Why all this hassle you ask. 1080p60. At the moment said camcorder (Sanyo FH1) is the only device I have capable of playing it in realtime and outputting a signal compatible with the HDTV in Full HD. If I could get that to work, it might prove interesting. Just a thought, any hints to make it work? Should I file a bug report? Is there one already? Is it fixed in the latest svn? I'm current as of 10/5/2009.
Your camcorder produces non standard compliant files. However this bug was workarounded already, update to latest svn. -- Baptiste COUDURIER Key fingerprint 8D77134D20CC9220201FC5DB0AC9325C5C1ABAAA FFmpeg maintainer http://www.ffmpeg.org
--- On Mon, 1/25/10, Baptiste Coudurier <baptiste.coudurier at gmail.com> wrote:
From: Baptiste Coudurier <baptiste.coudurier at gmail.com> Subject: Re: [FFmpeg-user] Sanyo FH1 - MP4 / AVC1 / H264 - pts < dts To: "FFmpeg user questions and RTFMs" <ffmpeg-user at mplayerhq.hu> Date: Monday, January 25, 2010, 2:21 PM Hi,
So I had a thought.? Swap out the camcorder audio for a different audio track.? Then put it back on the camcorder and play it.? But....
$ ffmpeg -an -i ./sany0001.mp4 -vcodec copy -y video_only.mp4
FFmpeg version git-ed22f90, Copyright (c) 2000-2009 Fabrice Bellard, et al. ? ? built on Jan 11 2010 13:42:28 with gcc 4.3.2 ? ? configuration: --prefix=/usr --enable-shared --enable-gpl --enable-nonfree --enable-postproc --enable-avfilter --enable-avfilter-lavf --enable-pthreads --enable-x11grab --enable-gray --enable-small --disable-libdirac --disable-libschroedinger --enable-libfaac --enable-libfaad --enable-libmp3lame --enable-libxvid --enable-libx264 --enable-libtheora --enable-libvorbis ? ? libavutil? ???50. 3. 0 / 50. 3. 0 ? ? libavcodec? ? 52.36. 0 / 52.36. 0 ? ? libavformat???52.39. 0 / 52.39. 0 ? ? libavdevice???52. 2. 0 /
? ? libavfilter? ? 0. 5. 0 /?
? ? libswscale? ???0. 7. 1 /? 0. 7. 1 ? ? libpostproc???51. 2. 0 /
[mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=0, dts=1001, size=144 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=2002, dts=3003, size=31624 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=4004, dts=5005, size=38968 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=6006, dts=7007, size=32880 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=8008, dts=9009, size=10928 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=10010, dts=11011, size=16488 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=12012, dts=13013, size=17912 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=14014, dts=15015, size=23280 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=16016, dts=17017, size=33376 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=18018, dts=19019, size=38000 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=20020, dts=21021, size=23528 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=22022, dts=23023, size=23328 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=24024, dts=25025, size=32944 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=26026, dts=27027, size=37504 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=28028, dts=29029, size=22360
Seems stream 0 codec frame rate differs from container
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from './FH1_video/sany1108.mp4': ? ? Duration: 00:17:58.79, start: 0.000000, bitrate: 24157 kb/s ? ? ? Stream #0.0(eng): Video: h264, yuv420p, 1920x1080 [PAR 1:1 DAR 16:9], 59.94 tbr, 60k tbn, 119.88 tbc ? ? ? Stream #0.1(eng): Audio: aac, 48000 Hz, 2 channels, s16 ? ? Metadata ? ? ? major_brand? ???: mp42 ? ? ? minor_version???: 1 ? ? ? compatible_brands: mp42avc1 ? ? ? comment? ? ? ???: SANYO DIGITAL CAMERA FH1 ? ? ? comment-eng? ???: SANYO DIGITAL CAMERA FH1 Output #0, mp4, to 'wgm.mp4': ? ? ? Stream #0.0(eng): Video: libx264, yuv420p, 1920x1080 [PAR 1:1 DAR 16:9], q=2-31, 120k tbn, 59.94 tbc Stream mapping: ? ? Stream #0.0 ->? #0.0 Press [q] to stop encoding [NULL @ 0x8071730]error, pts<? dts av_interleaved_write_frame(): Error while opening file
[...]
Why all this hassle you ask.? 1080p60.? At
On 01/25/2010 08:51 AM, James Shatto wrote: 52. 2. 0 0. 5. 0 51. 2. 0 frame rate: 119.88 (120000/1001) ->? 59.94 (60000/1001) the moment said camcorder (Sanyo FH1) is the only device I have capable of playing it in realtime and outputting a signal compatible with the HDTV in Full HD.? If I could get that to work, it might prove interesting.? Just a thought, any hints to make it work?? Should I file a bug report?? Is there one already?? Is it fixed in the latest svn?? I'm current as of 10/5/2009.
Your camcorder produces non standard compliant files. However this bug was workarounded already, update to latest svn.
-- Baptiste COUDURIER
I upgraded to the latest SVN (1/27) I can extract video only now. And audio only, and remerge. Although I haven't tested the result on the camcorder. Those annoying invalid timestamp errors are now gone as well. But the first 1/2 second of hose-age is still present. I'm not sure if that's ffmpeg or some other libav? issue though. That issue goes something like... ffmpeg -ss 00:00:00.000 -i sany0001.mp4 -ss 00:00:00.000 -vframes 30 -y test%02d.png results in frame 1 good, frame 30 good, frames 2-29 mostly grey. Where: ffmpeg -ss 00:00:00.000 -i sany0001.mp4 -ss 00:00:00.500 -vframes 30 -y test%02d.png results in all frames good. Skipping 1/2 second AFTER -i. Where: ffmpeg -ss 00:00:00.500 -i sany0001.mp4 -ss 00:00:00.000 -vframes 30 -y test%02d.png results in frame 1 good, frame 30 good, frames 2-29 mostly grey. Skipping 1/2 second BEFORE -i. All frames 30 plus are good afaik. The effect is similar to what youtube does to the first 7 seconds of my libx264 (0.77) conversions and uploads. I'm current on 0.83 after this upgrade. mplayer shows the same grey on playback, so I'm not sure if that's an ffmpeg thing or other related issue. It does affect ffmpeg decoding though. http://www.youtube.com/watch?v=rX9YAOhsyYM - James
Hi, On 01/29/2010 06:13 AM, James Shatto wrote:
--- On Mon, 1/25/10, Baptiste Coudurier<baptiste.coudurier at gmail.com> wrote:
From: Baptiste Coudurier<baptiste.coudurier at gmail.com> Subject: Re: [FFmpeg-user] Sanyo FH1 - MP4 / AVC1 / H264 - pts< dts To: "FFmpeg user questions and RTFMs"<ffmpeg-user at mplayerhq.hu> Date: Monday, January 25, 2010, 2:21 PM Hi,
So I had a thought. Swap out the camcorder audio for a different audio track. Then put it back on the camcorder and play it. But....
$ ffmpeg -an -i ./sany0001.mp4 -vcodec copy -y video_only.mp4
FFmpeg version git-ed22f90, Copyright (c) 2000-2009 Fabrice Bellard, et al. built on Jan 11 2010 13:42:28 with gcc 4.3.2 configuration: --prefix=/usr --enable-shared --enable-gpl --enable-nonfree --enable-postproc --enable-avfilter --enable-avfilter-lavf --enable-pthreads --enable-x11grab --enable-gray --enable-small --disable-libdirac --disable-libschroedinger --enable-libfaac --enable-libfaad --enable-libmp3lame --enable-libxvid --enable-libx264 --enable-libtheora --enable-libvorbis libavutil 50. 3. 0 / 50. 3. 0 libavcodec 52.36. 0 / 52.36. 0 libavformat 52.39. 0 / 52.39. 0 libavdevice 52. 2. 0 /
On 01/25/2010 08:51 AM, James Shatto wrote: 52. 2. 0
libavfilter 0. 5. 0 /
0. 5. 0
libswscale 0. 7.
1 / 0. 7. 1
libpostproc 51. 2. 0 /
[mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=0, dts=1001, size=144 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=2002, dts=3003, size=31624 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=4004, dts=5005, size=38968 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=6006, dts=7007, size=32880 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=8008, dts=9009, size=10928 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=10010, dts=11011, size=16488 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=12012, dts=13013, size=17912 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=14014, dts=15015, size=23280 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=16016, dts=17017, size=33376 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=18018, dts=19019, size=38000 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=20020, dts=21021, size=23528 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=22022, dts=23023, size=23328 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=24024, dts=25025, size=32944 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=26026, dts=27027, size=37504 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=28028, dts=29029, size=22360
Seems stream 0 codec frame rate differs from container
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from './FH1_video/sany1108.mp4': Duration: 00:17:58.79, start: 0.000000, bitrate: 24157 kb/s Stream #0.0(eng): Video: h264, yuv420p, 1920x1080 [PAR 1:1 DAR 16:9], 59.94 tbr, 60k tbn, 119.88 tbc Stream #0.1(eng): Audio: aac, 48000 Hz, 2 channels, s16 Metadata major_brand : mp42 minor_version : 1 compatible_brands: mp42avc1 comment : SANYO DIGITAL CAMERA FH1 comment-eng : SANYO DIGITAL CAMERA FH1 Output #0, mp4, to 'wgm.mp4': Stream #0.0(eng): Video: libx264, yuv420p, 1920x1080 [PAR 1:1 DAR 16:9], q=2-31, 120k tbn, 59.94 tbc Stream mapping: Stream #0.0 -> #0.0 Press [q] to stop encoding [NULL @ 0x8071730]error, pts< dts av_interleaved_write_frame(): Error while opening file
[...]
Why all this hassle you ask. 1080p60. At
51. 2. 0 frame rate: 119.88 (120000/1001) -> 59.94 (60000/1001) the moment said camcorder (Sanyo FH1) is the only device I have capable of playing it in realtime and outputting a signal compatible with the HDTV in Full HD. If I could get that to work, it might prove interesting. Just a thought, any hints to make it work? Should I file a bug report? Is there one already? Is it fixed in the latest svn? I'm current as of 10/5/2009.
Your camcorder produces non standard compliant files. However this bug was workarounded already, update to latest svn.
-- Baptiste COUDURIER
I upgraded to the latest SVN (1/27) I can extract video only now. And audio only, and remerge. Although I haven't tested the result on the camcorder. Those annoying invalid timestamp errors are now gone as well. But the first 1/2 second of hose-age is still present. I'm not sure if that's ffmpeg or some other libav? issue though. That issue goes something like...
ffmpeg -ss 00:00:00.000 -i sany0001.mp4 -ss 00:00:00.000 -vframes 30 -y test%02d.png
results in frame 1 good, frame 30 good, frames 2-29 mostly grey.
Where:
ffmpeg -ss 00:00:00.000 -i sany0001.mp4 -ss 00:00:00.500 -vframes 30 -y test%02d.png
results in all frames good. Skipping 1/2 second AFTER -i.
Where:
ffmpeg -ss 00:00:00.500 -i sany0001.mp4 -ss 00:00:00.000 -vframes 30 -y test%02d.png
results in frame 1 good, frame 30 good, frames 2-29 mostly grey. Skipping 1/2 second BEFORE -i. All frames 30 plus are good afaik. The effect is similar to what youtube does to the first 7 seconds of my libx264 (0.77) conversions and uploads. I'm current on 0.83 after this upgrade. mplayer shows the same grey on playback, so I'm not sure if that's an ffmpeg thing or other related issue. It does affect ffmpeg decoding though.
Can you upload your file somewhere so I can have a look ? Please follow http://www.ffmpeg.org/bugreports.html Thanks a lot. -- Baptiste COUDURIER Key fingerprint 8D77134D20CC9220201FC5DB0AC9325C5C1ABAAA FFmpeg maintainer http://www.ffmpeg.org
--- On Fri, 1/29/10, Baptiste Coudurier <baptiste.coudurier at gmail.com> wrote:
From: Baptiste Coudurier <baptiste.coudurier at gmail.com> Subject: Re: [FFmpeg-user] Sanyo FH1 - MP4 / AVC1 / H264 - pts < dts To: "FFmpeg user questions and RTFMs" <ffmpeg-user at mplayerhq.hu> Date: Friday, January 29, 2010, 1:21 PM Hi,
--- On Mon, 1/25/10, Baptiste Coudurier<baptiste.coudurier at gmail.com>? wrote:
From: Baptiste Coudurier<baptiste.coudurier at gmail.com> Subject: Re: [FFmpeg-user] Sanyo FH1 - MP4 / AVC1 / H264 - pts<? dts To: "FFmpeg user questions and RTFMs"<ffmpeg-user at mplayerhq.hu> Date: Monday, January 25, 2010, 2:21 PM Hi,
On 01/25/2010 08:51 AM, James Shatto wrote:
So I had a thought.? Swap out the camcorder audio for a different audio track.? Then put it back on the camcorder and play it.? But....
$ ffmpeg -an -i ./sany0001.mp4 -vcodec copy -y video_only.mp4
FFmpeg version git-ed22f90, Copyright (c) 2000-2009 Fabrice Bellard, et al. ? ? ? built on Jan 11 2010 13:42:28 with gcc 4.3.2 ? ? ? configuration: --prefix=/usr --enable-shared --enable-gpl --enable-nonfree --enable-postproc --enable-avfilter --enable-avfilter-lavf --enable-pthreads --enable-x11grab --enable-gray --enable-small --disable-libdirac --disable-libschroedinger --enable-libfaac --enable-libfaad --enable-libmp3lame --enable-libxvid --enable-libx264 --enable-libtheora --enable-libvorbis ? ? ? libavutil? ???50. 3. 0 / 50. 3. 0 ? ? ? libavcodec? ? 52.36. 0 / 52.36. 0 ? ? ?
52.39. 0
? ? ?
52. 2. 0
? ? ? libavfilter? ?
0. 5. 0
? ? ? libswscale? ???0. 7. 1 /? 0. 7. 1 ? ? ?
[mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=0, dts=1001, size=144 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=2002, dts=3003, size=31624 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=4004, dts=5005, size=38968 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=6006, dts=7007, size=32880 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=8008, dts=9009, size=10928 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=10010, dts=11011, size=16488 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=12012, dts=13013, size=17912 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=14014, dts=15015, size=23280 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=16016, dts=17017, size=33376 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=18018, dts=19019, size=38000 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=20020, dts=21021, size=23528 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=22022, dts=23023, size=23328 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=24024, dts=25025, size=32944 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=26026, dts=27027, size=37504 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=28028, dts=29029, size=22360
Seems stream 0 codec frame rate differs from container
51. 2. 0 frame rate: 119.88 (120000/1001) ->???59.94 (60000/1001)
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from './FH1_video/sany1108.mp4': ? ? ? Duration: 00:17:58.79, start: 0.000000, bitrate: 24157 kb/s ? ? ? ? Stream #0.0(eng): Video: h264, yuv420p, 1920x1080 [PAR 1:1 DAR 16:9], 59.94 tbr, 60k tbn, 119.88 tbc ? ? ? ? Stream #0.1(eng): Audio: aac, 48000 Hz, 2 channels, s16 ? ? ? Metadata ? ? ? ? major_brand ? ???: mp42 ? ? ? ? minor_version???: 1 ? ? ? ? compatible_brands: mp42avc1 ? ? ? ? comment ? ???: SANYO DIGITAL CAMERA FH1 ? ? ? ? comment-eng ? ???: SANYO DIGITAL CAMERA FH1 Output #0, mp4, to 'wgm.mp4': ? ? ? ? Stream #0.0(eng): Video: libx264, yuv420p, 1920x1080 [PAR 1:1 DAR 16:9], q=2-31, 120k tbn, 59.94 tbc Stream mapping: ? ? ? Stream #0.0 ->???#0.0 Press [q] to stop encoding [NULL @ 0x8071730]error,
av_interleaved_write_frame(): Error while opening file
[...]
Why all this hassle you ask.? 1080p60.? At the moment said camcorder (Sanyo FH1) is the only device I have capable of playing it in realtime and outputting a signal compatible with the HDTV in Full HD.? If I could get that to work, it might prove interesting.? Just a thought, any hints to make it work?? Should I file a bug report?? Is there one already?? Is it fixed in the latest svn?? I'm current as of 10/5/2009.
Your camcorder produces non standard compliant files. However this bug was workarounded already, update to latest svn.
-- Baptiste COUDURIER
I upgraded to the latest SVN (1/27) I can extract video only now.? And audio only, and remerge.? Although I haven't tested the result on the camcorder.? Those annoying invalid timestamp errors are now gone as well.? But the first 1/2 second of hose-age is still
On 01/29/2010 06:13 AM, James Shatto wrote: libavformat???52.39. 0 / libavdevice???52. 2. 0 / 0. 5. 0 / libpostproc???51. 2. 0 / pts<???dts present.? I'm not sure if that's ffmpeg or some other libav? issue though.? That issue goes something like...
ffmpeg -ss 00:00:00.000 -i sany0001.mp4 -ss
00:00:00.000 -vframes 30 -y test%02d.png
results in frame 1 good, frame 30 good, frames 2-29
mostly grey.
Where:
ffmpeg -ss 00:00:00.000 -i sany0001.mp4 -ss
00:00:00.500 -vframes 30 -y test%02d.png
results in all frames good.? Skipping 1/2 second
AFTER -i.
Where:
ffmpeg -ss 00:00:00.500 -i sany0001.mp4 -ss
00:00:00.000 -vframes 30 -y test%02d.png
results in frame 1 good, frame 30 good, frames 2-29
mostly grey.? Skipping 1/2 second BEFORE -i.? All frames 30 plus are good afaik.? The effect is similar to what youtube does to the first 7 seconds of my libx264 (0.77) conversions and uploads.? I'm current on 0.83 after this upgrade.? mplayer shows the same grey on playback, so I'm not sure if that's an ffmpeg thing or other related issue.? It does affect ffmpeg decoding though.
Can you upload your file somewhere so I can have a look ? Please follow http://www.ffmpeg.org/bugreports.html
Thanks a lot.
-- Baptiste COUDURIER
Done. Uploaded to: upload.ffmpeg.org/Mplayer/incoming/sany1131/ one .mp4 file from the camcorder ~2.5 seconds and 6MB+ one .txt file with notes extracted from above. (Hmmm... 553 on the .txt file, oh well) That plus notate it here? Or is there some official form thingy? Nothing significant footage wise, just an oops I didn't mean to push that button short clip. FWIW, the remux'd clips were not recognized by the camcorder. Just an image with a fat ? symbol on them. I made one from the original video and audio. Plus one from new audio, no love. Oh well, I had to try. I'm not a fan of AAC audio anyway. Perhaps some MP4box / header editing could make it gel. Or not. Thanks, - James
On 01/29/2010 12:56 PM, James Shatto wrote:
--- On Fri, 1/29/10, Baptiste Coudurier<baptiste.coudurier at gmail.com> wrote:
From: Baptiste Coudurier<baptiste.coudurier at gmail.com> Subject: Re: [FFmpeg-user] Sanyo FH1 - MP4 / AVC1 / H264 - pts< dts To: "FFmpeg user questions and RTFMs"<ffmpeg-user at mplayerhq.hu> Date: Friday, January 29, 2010, 1:21 PM Hi,
--- On Mon, 1/25/10, Baptiste Coudurier<baptiste.coudurier at gmail.com> wrote:
From: Baptiste Coudurier<baptiste.coudurier at gmail.com> Subject: Re: [FFmpeg-user] Sanyo FH1 - MP4 / AVC1 / H264 - pts< dts To: "FFmpeg user questions and RTFMs"<ffmpeg-user at mplayerhq.hu> Date: Monday, January 25, 2010, 2:21 PM Hi,
On 01/25/2010 08:51 AM, James Shatto wrote:
So I had a thought. Swap out the camcorder audio for a different audio track. Then put it back on the camcorder and play it. But....
$ ffmpeg -an -i ./sany0001.mp4 -vcodec copy -y video_only.mp4
FFmpeg version git-ed22f90, Copyright (c) 2000-2009 Fabrice Bellard, et al. built on Jan 11 2010 13:42:28 with gcc 4.3.2 configuration: --prefix=/usr --enable-shared --enable-gpl --enable-nonfree --enable-postproc --enable-avfilter --enable-avfilter-lavf --enable-pthreads --enable-x11grab --enable-gray --enable-small --disable-libdirac --disable-libschroedinger --enable-libfaac --enable-libfaad --enable-libmp3lame --enable-libxvid --enable-libx264 --enable-libtheora --enable-libvorbis libavutil 50. 3. 0 / 50. 3. 0 libavcodec 52.36. 0 / 52.36. 0
52.39. 0
52. 2. 0
libavfilter
0. 5. 0
libswscale
0. 7. 1 / 0. 7. 1
[mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=0, dts=1001, size=144 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=2002, dts=3003, size=31624 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=4004, dts=5005, size=38968 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=6006, dts=7007, size=32880 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=8008, dts=9009, size=10928 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=10010, dts=11011, size=16488 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=12012, dts=13013, size=17912 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=14014, dts=15015, size=23280 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=16016, dts=17017, size=33376 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=18018, dts=19019, size=38000 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=20020, dts=21021, size=23528 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=22022, dts=23023, size=23328 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=24024, dts=25025, size=32944 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=26026, dts=27027, size=37504 [mov,mp4,m4a,3gp,3g2,mj2 @ 0x8066420]Invalid timestamps stream=0, pts=28028, dts=29029, size=22360
Seems stream 0 codec frame rate differs from container
51. 2. 0 frame rate: 119.88 (120000/1001) -> 59.94 (60000/1001)
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from './FH1_video/sany1108.mp4': Duration: 00:17:58.79, start: 0.000000, bitrate: 24157 kb/s Stream #0.0(eng): Video: h264, yuv420p, 1920x1080 [PAR 1:1 DAR 16:9], 59.94 tbr, 60k tbn, 119.88 tbc Stream #0.1(eng): Audio: aac, 48000 Hz, 2 channels, s16 Metadata major_brand : mp42
minor_version : 1
compatible_brands:
mp42avc1
comment
: SANYO DIGITAL CAMERA FH1
comment-eng
: SANYO DIGITAL CAMERA FH1
Output #0, mp4, to 'wgm.mp4': Stream #0.0(eng): Video: libx264, yuv420p, 1920x1080 [PAR 1:1 DAR 16:9], q=2-31, 120k tbn, 59.94 tbc Stream mapping: Stream #0.0 -> #0.0 Press [q] to stop encoding [NULL @ 0x8071730]error,
av_interleaved_write_frame(): Error while opening file
[...]
Why all this hassle you ask. 1080p60. At the moment said camcorder (Sanyo FH1) is the only device I have capable of playing it in realtime and outputting a signal compatible with the HDTV in Full HD. If I could get that to work, it might prove interesting. Just a thought, any hints to make it work? Should I file a bug report? Is there one already? Is it fixed in the latest svn? I'm current as of 10/5/2009.
Your camcorder produces non standard compliant files. However this bug was workarounded already, update to latest svn.
-- Baptiste COUDURIER
I upgraded to the latest SVN (1/27) I can extract video only now. And audio only, and remerge. Although I haven't tested the result on the camcorder. Those annoying invalid timestamp errors are now gone as well. But the first 1/2 second of hose-age is still
On 01/29/2010 06:13 AM, James Shatto wrote: libavformat 52.39. 0 / libavdevice 52. 2. 0 / 0. 5. 0 / libpostproc 51. 2. 0 / pts< dts present. I'm not sure if that's ffmpeg or some other libav? issue though. That issue goes something like...
ffmpeg -ss 00:00:00.000 -i sany0001.mp4 -ss
00:00:00.000 -vframes 30 -y test%02d.png
results in frame 1 good, frame 30 good, frames 2-29
mostly grey.
Where:
ffmpeg -ss 00:00:00.000 -i sany0001.mp4 -ss
00:00:00.500 -vframes 30 -y test%02d.png
results in all frames good. Skipping 1/2 second
AFTER -i.
Where:
ffmpeg -ss 00:00:00.500 -i sany0001.mp4 -ss
00:00:00.000 -vframes 30 -y test%02d.png
results in frame 1 good, frame 30 good, frames 2-29
mostly grey. Skipping 1/2 second BEFORE -i. All frames 30 plus are good afaik. The effect is similar to what youtube does to the first 7 seconds of my libx264 (0.77) conversions and uploads. I'm current on 0.83 after this upgrade. mplayer shows the same grey on playback, so I'm not sure if that's an ffmpeg thing or other related issue. It does affect ffmpeg decoding though.
Can you upload your file somewhere so I can have a look ? Please follow http://www.ffmpeg.org/bugreports.html
Thanks a lot.
-- Baptiste COUDURIER
Done. Uploaded to:
upload.ffmpeg.org/Mplayer/incoming/sany1131/
one .mp4 file from the camcorder ~2.5 seconds and 6MB+ one .txt file with notes extracted from above.
(Hmmm... 553 on the .txt file, oh well)
That plus notate it here? Or is there some official form thingy? Nothing significant footage wise, just an oops I didn't mean to push that button short clip.
FWIW, the remux'd clips were not recognized by the camcorder. Just an image with a fat ? symbol on them. I made one from the original video and audio. Plus one from new audio, no love. Oh well, I had to try. I'm not a fan of AAC audio anyway. Perhaps some MP4box / header editing could make it gel. Or not.
Thanks. It seems to be a bug, I added it to our bugtracker: https://roundup.ffmpeg.org/roundup/ffmpeg/issue1722 Feel free to subscribe to get notifications. Thanks for the report. -- Baptiste COUDURIER Key fingerprint 8D77134D20CC9220201FC5DB0AC9325C5C1ABAAA FFmpeg maintainer http://www.ffmpeg.org
participants (2)
-
baptiste.coudurier@gmail.com -
wwwshadow7@yahoo.com