Use FFmpeg to join MP4 files while preserving subtitles stream [closed] - ffmpeg

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 8 years ago.
Improve this question
I tried:
ffmpeg -f concat -i files.lst -c copy output.mp4
But the output file doesn't have the subtitles stream. How do I fix this?
Log:
ffmpeg version 2.3.4 Copyright (c) 2000-2014 the FFmpeg developers
built on Dec 4 2014 09:23:21 with gcc 4.8.2 (GCC) 20140120 (Red Hat 4.8.2-16)
configuration: --prefix=/usr --bindir=/usr/bin --datadir=/usr/share/ffmpeg --incdir=/usr/include/ffmpeg --libdir=/usr/lib64 --mandir=/usr/share/man --arch=x86_64 --optflags='-O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic' --enable-bzlib --disable-crystalhd --enable-gnutls --enable-libass --enable-libcdio --enable-libdc1394 --disable-indev=jack --enable-libfreetype --enable-libgsm --enable-libmp3lame --enable-openal --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-libschroedinger --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libvorbis --enable-libv4l2 --enable-libx264 --enable-libxvid --enable-x11grab --enable-avfilter --enable-avresample --enable-postproc --enable-pthreads --disable-static --enable-shared --enable-gpl --disable-debug --disable-stripping --shlibdir=/usr/lib64 --enable-runtime-cpudetect
libavutil 52. 92.100 / 52. 92.100
libavcodec 55. 69.100 / 55. 69.100
libavformat 55. 48.100 / 55. 48.100
libavdevice 55. 13.102 / 55. 13.102
libavfilter 4. 11.100 / 4. 11.100
libavresample 1. 3. 0 / 1. 3. 0
libswscale 2. 6.100 / 2. 6.100
libswresample 0. 19.100 / 0. 19.100
libpostproc 52. 3.100 / 52. 3.100
[mov,mp4,m4a,3gp,3g2,mj2 # 0x121e7e0] Invalid SampleDelta -1136 in STTS, at 252 st:1
[concat # 0x121d8e0] Estimating duration from bitrate, this may be inaccurate
Input #0, concat, from 'files.lst':
Duration: 00:00:00.02, start: 0.000000, bitrate: 144 kb/s
Stream #0:0: Video: h264 (Main) (avc1 / 0x31637661), yuv420p(tv, smpte170m), 720x480 [SAR 8:9 DAR 4:3], 2528 kb/s, 29.97 fps, 29.97 tbr, 90k tbn, 180k tbc
Stream #0:1: Audio: aac (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 160 kb/s
Stream #0:2: Subtitle: mov_text (tx3g / 0x67337874), 0 kb/s
Output #0, mp4, to 'output.mp4':
Metadata:
encoder : Lavf55.48.100
Stream #0:0: Video: h264 ([33][0][0][0] / 0x0021), yuv420p, 720x480 [SAR 8:9 DAR 4:3], q=2-31, 2528 kb/s, 29.97 fps, 90k tbn, 90k tbc
Stream #0:1: Audio: aac ([64][0][0][0] / 0x0040), 48000 Hz, stereo, 160 kb/s
Stream mapping:
Stream #0:0 -> #0:0 (copy)
Stream #0:1 -> #0:1 (copy)
Press [q] to stop, [?] for help
[mov,mp4,m4a,3gp,3g2,mj2 # 0x1205da0] Invalid SampleDelta -1136 in STTS, at 164 st:1
[mov,mp4,m4a,3gp,3g2,mj2 # 0x1227f80] Invalid SampleDelta -1136 in STTS, at 47 st:1
[mov,mp4,m4a,3gp,3g2,mj2 # 0x130d5e0] Invalid SampleDelta -1136 in STTS, at 715 st:1
[mov,mp4,m4a,3gp,3g2,mj2 # 0x1202b80] Invalid SampleDelta -1136 in STTS, at 121 st:1
[mov,mp4,m4a,3gp,3g2,mj2 # 0x1202b80] Invalid SampleDelta -1136 in STTS, at 67 st:1
[mov,mp4,m4a,3gp,3g2,mj2 # 0x121e7e0] Invalid SampleDelta -1136 in STTS, at 586 st:1
[mov,mp4,m4a,3gp,3g2,mj2 # 0x121e7e0] Invalid SampleDelta -1136 in STTS, at 697 st:1
[mov,mp4,m4a,3gp,3g2,mj2 # 0x1205da0] Invalid SampleDelta -1136 in STTS, at 327 st:1
[mov,mp4,m4a,3gp,3g2,mj2 # 0x1202ba0] Invalid SampleDelta -1136 in STTS, at 559 st:1
frame= 7713 fps=0.0 q=-1.0 Lsize= 83874kB time=00:04:17.62 bitrate=2667.0kbits/s
video:78535kB audio:5036kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.362465%

You also have to use -scodec copy, because -c does NOT include subtitles:
ffmpeg -f concat -i files.lst -c copy -scodec copy output.mp4

Related

FFMPEG [mp3float # 0x7fd42f813200] Header missing

I have a problem with some mp3 files. When transcoding the file with FFMPEG I get the following error:
[mp3float # 0x7fd42f813200] Header missing
Error while decoding stream #0:0: Invalid data found when processing input
Is this a problem of the file itself, and how it is produced?
Or is it a problem of FFMPEG?
Here full decoding message:
ffmpeg version git-2020-07-28-dfd12ee Copyright (c) 2000-2020 the FFmpeg developers
built with Apple clang version 11.0.0 (clang-1100.0.33.16)
configuration: --prefix=/usr/local/Cellar/ffmpeg/HEAD-dfd12ee_2 --enable-shared --cc=clang --host-cflags= --host-ldflags= --enable-gpl --enable-libaom --enable-libdav1d --enable-libmp3lame --enable-libopus --enable-libsnappy --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libx265 --enable-libfontconfig --enable-libfreetype --enable-frei0r --enable-libass --enable-demuxer=dash --disable-libjack --disable-indev=jack --enable-opencl --enable-videotoolbox --disable-htmlpages --enable-libfdk-aac --enable-nonfree
libavutil 56. 57.100 / 56. 57.100
libavcodec 58. 97.102 / 58. 97.102
libavformat 58. 49.100 / 58. 49.100
libavdevice 58. 11.101 / 58. 11.101
libavfilter 7. 87.100 / 7. 87.100
libswscale 5. 8.100 / 5. 8.100
libswresample 3. 8.100 / 3. 8.100
libpostproc 55. 8.100 / 55. 8.100
[mp3 # 0x7fd42f808200] Estimating duration from bitrate, this may be inaccurate
Input #0, mp3, from 'Ice Mc - Think About The Way.mp3':
Metadata:
title : Think About The Way
TBPM : 133
artist : Ice MC
date : 1994
track : 4/15
disc : 0
album_artist : ICE MC
Duration: 00:04:16.39, start: 0.000000, bitrate: 323 kb/s
Stream #0:0: Audio: mp3, 44100 Hz, stereo, fltp, 320 kb/s
Stream #0:1: Video: mjpeg (Baseline), yuvj420p(pc, bt470bg/unknown/unknown), 600x592 [SAR 72:72 DAR 75:74], 90k tbr, 90k tbn, 90k tbc (attached pic)
Metadata:
comment : Other
Stream mapping:
Stream #0:1 -> #0:0 (mjpeg (native) -> wrapped_avframe (native))
Stream #0:0 -> #0:1 (mp3 (mp3float) -> pcm_s16le (native))
Press [q] to stop, [?] for help
Output #0, null, to 'pipe:':
Metadata:
title : Think About The Way
TBPM : 133
artist : Ice MC
date : 1994
track : 4/15
disc : 0
album_artist : ICE MC
encoder : Lavf58.49.100
Stream #0:0: Video: wrapped_avframe, yuvj420p(progressive), 600x592 [SAR 72:72 DAR 75:74], q=2-31, 200 kb/s, 90k fps, 90k tbn, 90k tbc (attached pic)
Metadata:
comment : Other
encoder : Lavc58.97.102 wrapped_avframe
Stream #0:1: Audio: pcm_s16le, 44100 Hz, stereo, s16, 1411 kb/s
Metadata:
encoder : Lavc58.97.102 pcm_s16le
[mp3float # 0x7fd42f813200] Header missing
Error while decoding stream #0:0: Invalid data found when processing input
frame= 1 fps=0.0 q=-0.0 Lsize=N/A time=00:04:16.60 bitrate=N/A speed= 725x
video:1kB audio:44204kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: unknown
What is also noticed is that this mp3 has the cover embedded as a video stream. And there is also this weird cross mapping. Not sure if that is normal?
Are you sure, that you use only the stream you need? If no, you can check it by printing all the stream number of packets, returned by av_read_frame.
To select a specific stream, you should discard others. Check this thread to find out how: How to change stream index in libavformat

What is the best way to capture a screenshot from a udp stream?

I'm trying to capture a screenshot from a udp stream using ffmpeg in a Ubuntu 14.04 System.
Following is the command
ffmpeg -y -i udp_ip -vframes 1 -q:v 1 test.png
But the image captured is of very poor resolution and I observed a lag while taking the screenshot.
Please suggest a best tool or a way to take a screenshot in the fastest way and also of the best image resolution possible.
edit:
log files
ffmpeg version 3.3.2 Copyright (c) 2000-2017 the FFmpeg developers
built with gcc 4.8 (Ubuntu 4.8.4-2ubuntu1~14.04.3)
configuration: --extra-libs=-ldl --prefix=/opt/ffmpeg --mandir=/usr/share/man --enable-avresample --disable-debug --enable-nonfree --enable-gpl --enable-version3 --enable-libopencore-amrnb --enable-libopencore-amrwb --disable-decoder=amrnb --disable-decoder=amrwb --enable-libpulse --enable-libfreetype --enable-gnutls --enable-libx264 --enable-libx265 --enable-libfdk-aac --enable-libvorbis --enable-libtheora --enable-libmp3lame --enable-libopus --enable-libvpx --enable-libspeex --enable-libass --enable-avisynth --enable-libsoxr --enable-libxvid --enable-libvidstab --enable-libwavpack --enable-nvenc
libavutil 55. 58.100 / 55. 58.100
libavcodec 57. 89.100 / 57. 89.100
libavformat 57. 71.100 / 57. 71.100
libavdevice 57. 6.100 / 57. 6.100
libavfilter 6. 82.100 / 6. 82.100
libavresample 3. 5. 0 / 3. 5. 0
libswscale 4. 6.100 / 4. 6.100
libswresample 2. 7.100 / 2. 7.100
libpostproc 54. 5.100 / 54. 5.100
[mpeg2video # 0x390cc60] Invalid frame dimensions 0x0.
Last message repeated 7 times
Input #0, mpegts, from 'udp://#xxx.xx.xx.xx:xxxx':
Duration: N/A, start: 144.130744, bitrate: 4128 kb/s
Program 1
Metadata:
service_name : Program-1
service_provider: Encoder
Stream #0:0[0x42]: Video: mpeg2video (Main) ([2][0][0][0] / 0x0002), yuv420p(tv, top first), 720x576 [SAR 16:15 DAR 4:3], 4000 kb/s, 25 fps, 25 tbr, 90k tbn, 50 tbc
Stream #0:1[0x43]: Audio: mp2 ([3][0][0][0] / 0x0003), 48000 Hz, stereo, s16p, 128 kb/s
Stream mapping:
Stream #0:0 -> #0:0 (mpeg2video (native) -> png (native))
Press [q] to stop, [?] for help
Output #0, image2, to 'player.png':
Metadata:
encoder : Lavf57.71.100
Stream #0:0: Video: png, rgb24, 720x576 [SAR 16:15 DAR 4:3], q=2-31, 200 kb/s, 25 fps, 25 tbn, 25 tbc
Metadata:
encoder : Lavc57.89.100 png
frame= 1 fps=0.0 q=-0.0 Lsize=N/A time=00:00:00.04 bitrate=N/A dup=1 drop=1 speed=0.729x
video:777kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: unknown
Since, this seems to be an issue of aspect ratio, and not quality, per se, use
ffmpeg -y -i udp_ip -vf scale=iw*sar:ih,setsar=1 -vframes 1 -q:v 1 test.png
The scale filter rescales the video to square pixels. The SAR filter isn't strictly necessary but in case the PNG muxer writes that data, better to reset it.

ffmpeg: -copyts makes -t stop at timestamps, not duration

From
-t duration (input/output)
When used as an input option (before -i), limit the duration of data read from the input file.
When used as an output option (before an output url), stop writing the output after its duration reaches duration.
So this should yield a 1-minute file with timestamps starting at 1:49, right?
ffmpeg -y -copyts -ss 1:49 -i ~/Videos/input.mkv -c copy -t 1:00 timing-1m49s.mkv
ffmpeg version 3.3.2 Copyright (c) 2000-2017 the FFmpeg developers
built with gcc 7 (SUSE Linux)
configuration: --prefix=/usr --libdir=/usr/lib64 --shlibdir=/usr/lib64 --incdir=/usr/include/ffmpeg --extra-cflags='-fmessage-length=0 -grecord-gcc-switches -O2 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector-strong -funwind-tables -fasynchronous-unwind-tables -g' --optflags='-fmessage-length=0 -grecord-gcc-switches -O2 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector-strong -funwind-tables -fasynchronous-unwind-tables -g' --disable-htmlpages --enable-pic --disable-stripping --enable-shared --disable-static --enable-gpl --disable-openssl --enable-avresample --enable-libcdio --enable-gnutls --enable-ladspa --enable-libass --enable-libbluray --enable-libcelt --enable-libcdio --enable-libdc1394 --enable-libfreetype --enable-libgsm --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libwebp --enable-netcdf --enable-vaapi --enable-vdpau --enable-libfdk_aac --enable-nonfree --enable-libmp3lame --enable-libtwolame --enable-libx264 --enable-libx265 --enable-libxvid
libavutil 55. 58.100 / 55. 58.100
libavcodec 57. 89.100 / 57. 89.100
libavformat 57. 71.100 / 57. 71.100
libavdevice 57. 6.100 / 57. 6.100
libavfilter 6. 82.100 / 6. 82.100
libavresample 3. 5. 0 / 3. 5. 0
libswscale 4. 6.100 / 4. 6.100
libswresample 2. 7.100 / 2. 7.100
libpostproc 54. 5.100 / 54. 5.100
Input #0, matroska,webm, from '/home/ariel/Videos/input.mkv':
Metadata:
encoder : libebml v0.7.7 + libmatroska v0.8.0
creation_time : 2006-07-20T03:07:03.000000Z
Duration: 00:23:57.06, start: 0.000000, bitrate: 1983 kb/s
Stream #0:0: Video: h264 (High), yuv420p(progressive), 720x480, SAR 37:30 DAR 37:20, 29.97 fps, 29.97 tbr, 1k tbn, 59.94 tbc (default)
Stream #0:1(eng): Audio: ac3, 48000 Hz, stereo, fltp, 192 kb/s (default)
Stream #0:2(jpn): Audio: ac3, 48000 Hz, stereo, fltp, 192 kb/s
Stream #0:3(eng): Subtitle: dvd_subtitle, 720x480 (default)
Metadata:
title : English Audio
Stream #0:4(eng): Subtitle: dvd_subtitle, 720x480
Metadata:
title : Japanese Audio
Output #0, matroska, to 'timing-1m49s.mkv':
Metadata:
encoder : Lavf57.71.100
Stream #0:0: Video: h264 (High) (H264 / 0x34363248), yuv420p(progressive), 720x480 [SAR 37:30 DAR 37:20], q=2-31, 29.97 fps, 29.97 tbr, 1k tbn, 1k tbc (default)
Stream #0:1(eng): Audio: ac3 ([0] [0][0] / 0x2000), 48000 Hz, stereo, fltp, 192 kb/s (default)
Stream mapping:
Stream #0:0 -> #0:0 (copy)
Stream #0:1 -> #0:1 (copy)
Press [q] to stop, [?] for help
frame= 0 fps=0.0 q=-1.0 Lsize= 1kB time=00:00:00.00 bitrate=N/A speed= 0x
video:0kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: unknown
Wrong. It outputs a file with no frames:
-rwxrwx--- 1 root users 805 Jul 30 01:36 timing-1m49s.mkv
I have to specify -t 1:49 or more, and e.g. -t 1:55 produces a 6-second file that starts at 0:00 and according to the metadata should last 1:55.
I arrived at this point trying to extract a clip and add subtitles in the same command, but this minimal case looks to me contrary to the documentation.
Yes, the -t used as output option looks at the timestamps, which usually start at zero. Except for cases like these when -copyts is used. Use -t as input option:
ffmpeg -y -copyts -ss 1:49 -t 1:00 -i ~/Videos/input.mkv -c copy timing-1m49s.mkv

What is the best way to split a transport stream file?

I have a .ts file (Download files here: http://dropcanvas.com/2gmsg/1).
I want to split this video while I expect ALL other properties remain same including pts time.
Here is what I try to achieve this:
ffmpeg -ss 0.000 -i sample.ts -y -c copy -t 3 splitted.ts
Expected start time: 94678.950389
New start time: 1.402367
I expect the above command should only take first 3 seconds of the .ts file and all other stuff to stay same. I've seen copyts and copytb options from the documentation but I wasn't able to use them.
So how do I do this?
Thank you
Here are the logs for copyts. It creates a 0 byte splitted.ts file:
ffmpeg -ss 0:00:00 -i sample.ts -to 00:00:03 -y -c copy -copyts splitted.ts
ffmpeg version 3.0 Copyright (c) 2000-2016 the FFmpeg developers
built with Apple LLVM version 7.0.0 (clang-700.0.72)
configuration: --prefix=/usr/local/Cellar/ffmpeg/3.0 --enable-shared --enable-pthreads --enable-gpl --enable-version3 --enable-hardcoded-tables --enable-avresample --cc=clang --host-cflags= --host-ldflags= --enable-opencl --enable-libx264 --enable-libmp3lame --enable-libxvid --enable-libfreetype --enable-libvorbis --enable-libvpx --enable-libass --enable-ffplay --enable-libfdk-aac --enable-libopus --enable-libx265 --enable-nonfree --enable-vda
libavutil 55. 17.103 / 55. 17.103
libavcodec 57. 24.102 / 57. 24.102
libavformat 57. 25.100 / 57. 25.100
libavdevice 57. 0.101 / 57. 0.101
libavfilter 6. 31.100 / 6. 31.100
libavresample 3. 0. 0 / 3. 0. 0
libswscale 4. 0.100 / 4. 0.100
libswresample 2. 0.101 / 2. 0.101
libpostproc 54. 0.100 / 54. 0.100
[NULL # 0x7fafac02fc00] start time for stream 2 is not set in estimate_timings_from_pts
Input #0, mpegts, from 'sample.ts':
Duration: 00:00:10.07, start: 94678.950389, bitrate: 934 kb/s
Program 1
Stream #0:0[0x100]: Video: h264 (Main) ([27][0][0][0] / 0x001B), yuv420p, 854x480 [SAR 1280:1281 DAR 16:9], 29.97 fps, 29.97 tbr, 90k tbn, 59.94 tbc
Stream #0:1[0x101]: Audio: aac (LC) ([15][0][0][0] / 0x000F), 44100 Hz, stereo, fltp, 140 kb/s
Stream #0:2[0x102]: Data: timed_id3 (ID3 / 0x20334449)
Output #0, mpegts, to 'splitted.ts':
Metadata:
encoder : Lavf57.25.100
Stream #0:0: Video: h264 ([27][0][0][0] / 0x001B), yuv420p, 854x480 [SAR 1280:1281 DAR 16:9], q=2-31, 29.97 fps, 29.97 tbr, 90k tbn, 90k tbc
Stream #0:1: Audio: aac (LC) ([15][0][0][0] / 0x000F), 44100 Hz, stereo, 140 kb/s
Stream mapping:
Stream #0:0 -> #0:0 (copy)
Stream #0:1 -> #0:1 (copy)
Press [q] to stop, [?] for help
frame= 0 fps=0.0 q=-1.0 Lsize= 0kB time=00:00:00.00 bitrate=N/A speed= 0x
video:0kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: unknown
Output file is empty, nothing was encoded (check -ss / -t / -frames parameters if used)
This works for me
ffmpeg -seek_timestamp 1 -ss 94678.950389 -i sample.ts -y -c copy -copyts -to 94681.950389 -muxdelay 0 splitted.ts
Your original command can work if you use the frames flag.
ffmpeg -ss 0.000 -i sample.ts -y -c copy -copyts -muxdelay 0 -vframes 90 splitted.ts
Where 90 represents amount of frames in t seconds.

ffmpeg: stream copy from .mxf into NLE-compatible format [closed]

Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 9 years ago.
Improve this question
Because my NLE software does not support the .mxf-files from Canon XF100 I need to convert them into a supported format.
As far as I know, mxf-files are just another container format for mpeg2 streams, so it would be really nice to extract the streams and place them into another container (without reencoding).
I think ffmpeg can do this – correct me if I'm wrong – by running the following command:
ffmpeg -i in.mxf -vcodec copy out.m2ts (or .ts, .mts, ...)
ffmpeg finishes without errors after about 2 seconds (in.mxf is abut 170mb):
c:\video>c:\ffmpeg\bin\ffmpeg -i in.MXF -vcodec copy out.m2ts
ffmpeg version N-53680-g0ab9362 Copyright (c) 2000-2013 the FFmpeg developers
built on May 30 2013 12:14:03 with gcc 4.7.3 (GCC)
configuration: --enable-gpl --enable-version3 --disable-w32threads --enable-av
isynth --enable-bzlib --enable-fontconfig --enable-frei0r --enable-gnutls --enab
le-iconv --enable-libass --enable-libbluray --enable-libcaca --enable-libfreetyp
e --enable-libgsm --enable-libilbc --enable-libmodplug --enable-libmp3lame --ena
ble-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-l
ibopus --enable-librtmp --enable-libschroedinger --enable-libsoxr --enable-libsp
eex --enable-libtheora --enable-libtwolame --enable-libvo-aacenc --enable-libvo-
amrwbenc --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libxavs --
enable-libxvid --enable-zlib
libavutil 52. 34.100 / 52. 34.100
libavcodec 55. 12.102 / 55. 12.102
libavformat 55. 8.100 / 55. 8.100
libavdevice 55. 2.100 / 55. 2.100
libavfilter 3. 73.100 / 3. 73.100
libswscale 2. 3.100 / 2. 3.100
libswresample 0. 17.102 / 0. 17.102
libpostproc 52. 3.100 / 52. 3.100
Guessed Channel Layout for Input Stream #0.1 : mono
Guessed Channel Layout for Input Stream #0.2 : mono
Input #0, mxf, from 'in.MXF':
Metadata:
uid : 1bb23c97-6205-4800-80a2-e00002244ba7
generation_uid : 1bb23c97-6205-4800-8122-e00002244ba7
company_name : CANON
product_name : XF100
product_version : 1.00
product_uid : 060e2b34-0401-010d-0e15-005658460100
modification_date: 2013-01-06 11:05:02
timecode : 01:42:14:22
Duration: 00:00:28.32, start: 0.000000, bitrate: 51811 kb/s
Stream #0:0: Video: mpeg2video (4:2:2), yuv422p, 1920x1080 [SAR 1:1 DAR 16:9
], 25 fps, 25 tbr, 25 tbn, 50 tbc
Stream #0:1: Audio: pcm_s16le, 48000 Hz, mono, s16, 768 kb/s
Stream #0:2: Audio: pcm_s16le, 48000 Hz, mono, s16, 768 kb/s
Output #0, mpegts, to 'out.m2ts':
Metadata:
uid : 1bb23c97-6205-4800-80a2-e00002244ba7
generation_uid : 1bb23c97-6205-4800-8122-e00002244ba7
company_name : CANON
product_name : XF100
product_version : 1.00
product_uid : 060e2b34-0401-010d-0e15-005658460100
modification_date: 2013-01-06 11:05:02
timecode : 01:42:14:22
encoder : Lavf55.8.100
Stream #0:0: Video: mpeg2video, yuv422p, 1920x1080 [SAR 1:1 DAR 16:9], q=2-3
1, 25 fps, 90k tbn, 25 tbc
Stream #0:1: Audio: mp2, 48000 Hz, mono, s16, 128 kb/s
Stream mapping:
Stream #0:0 -> #0:0 (copy)
Stream #0:1 -> #0:1 (pcm_s16le -> mp2)
Press [q] to stop, [?] for help
frame= 532 fps=0.0 q=-1.0 size= 143511kB time=00:00:21.25 bitrate=55314.1kbits
frame= 561 fps=435 q=-1.0 size= 151254kB time=00:00:22.42 bitrate=55242.0kbits
frame= 586 fps=314 q=-1.0 size= 158021kB time=00:00:23.41 bitrate=55288.0kbits
frame= 609 fps=255 q=-1.0 size= 164182kB time=00:00:24.34 bitrate=55235.4kbits
frame= 636 fps=217 q=-1.0 size= 171463kB time=00:00:25.42 bitrate=55235.1kbits
frame= 669 fps=194 q=-1.0 size= 180133kB time=00:00:26.72 bitrate=55226.3kbits
frame= 699 fps=173 q=-1.0 size= 188326kB time=00:00:27.92 bitrate=55256.6kbits
frame= 708 fps=169 q=-1.0 Lsize= 190877kB time=00:00:28.30 bitrate=55233.6kbit
s/s
video:172852kB audio:442kB subtitle:0 global headers:0kB muxing overhead 10.1461
18%
Unfortunately the output file turns out to be displayed correctly only by vlc player.
My NLE-software (Cyberlink Power Director) is able to open the file but most of the picture is green. Only a few pixels on the left edge show the original video:
output file
Any ideas how to solve that problem? Is there a better way to use .mxf-files in NLE-software without native support?
thanks in advance
Thanks to Carl
ffmpeg -fflags +genpts -i in.MXF -c copy out.mkv

Resources