Need a video format that will play on Windows XP/7 out of the box-Collection of common programming errors

ArtOfWarfareI am distributing an exe file that contains a video that needs to be able to be played on Windows XP & Windows 7 without ANY other software or codecs installed. This includes Windows Media Player, which many of my customers don’t have installed.
Formats – bear with me, I mostly develop apps for other platforms. I don’t normally deal with a/v stuff or Windows stuff so my terminology is probably off – I’ve tried and had no success with:
- .mp4
- .ogv
- .wmv (ironic, isn’t it?)
I have been able to play the video in a .mpg format, but it has two issues:
- Audio doesn’t play
- The file is really big. It’s 80 MB and I’d rather have it be no more than 30 MB. I’m okay with putting it in a zip to keep the size down, but that only gets it down to 50 MB.
When I open the file on my Mac, it plays, audio and all.
This is what the QuickTime X movie inspector says about the file format:
MPEG-1 Video, 1,280 x 720 MPEG Layer 3, 48000 Hz, Stereo (L R)I’d like an FFMPEG command that I can feed my video to and end up with an outputted file that will play on Windows 7, both audio and visual, without any dependencies on other codecs or applications. I’d like it if it also played on fresh installs of Windows XP although I can live with it if it doesn’t, and ideally I’d like it to also be within my size constraints.
Edit with details on the output of ffmpeg when I attempted to follow Darth Android’s answer:
ffmpeg version 2.0.1 Copyright (c) 2000-2013 the FFmpeg developers built on Aug 15 2013 10:56:46 with llvm-gcc 4.2.1 (LLVM build 2336.11.00) configuration: --prefix=/Volumes/Ramdisk/sw --enable-gpl --enable-pthreads --enable-version3 --enable-libspeex --enable-libvpx --disable-decoder=libvpx --enable-libmp3lame --enable-libtheora --enable-libvorbis --enable-libx264 --enable-avfilter --enable-libopencore_amrwb --enable-libopencore_amrnb --enable-filters --enable-libgsm --arch=x86_64 --enable-runtime-cpudetect libavutil 52. 38.100 / 52. 38.100 libavcodec 55. 18.102 / 55. 18.102 libavformat 55. 12.100 / 55. 12.100 libavdevice 55. 3.100 / 55. 3.100 libavfilter 3. 79.101 / 3. 79.101 libswscale 2. 3.100 / 2. 3.100 libswresample 0. 17.102 / 0. 17.102 libpostproc 52. 3.100 / 52. 3.100 Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'my-video.mp4': Metadata: major_brand : mp42 minor_version : 0 compatible_brands: mp42isomavc1 creation_time : 2013-06-10 18:21:11 encoder : HandBrake 0.9.9 2013051800 Duration: 00:01:33.95, start: 0.000000, bitrate: 954 kb/s Stream #0:0(und): Video: h264 (Main) (avc1 / 0x31637661), yuv420p, 1280x720 [SAR 1:1 DAR 16:9], 813 kb/s, 29.97 fps, 29.97 tbr, 90k tbn, 180k tbc Metadata: creation_time : 2013-06-10 18:21:11 Stream #0:1(eng): Audio: aac (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 136 kb/s Metadata: creation_time : 2013-06-10 18:21:11 [vob @ 0x7f8278821000] VBV buffer size not set, muxing may fail Output #0, vob, to 'my-video.mpg': Metadata: major_brand : mp42 minor_version : 0 compatible_brands: mp42isomavc1 encoder : Lavf55.12.100 Stream #0:0(und): Video: mpeg2video, yuv420p, 1280x720 [SAR 1:1 DAR 16:9], q=2-31, 200 kb/s, 90k tbn, 29.97 tbc Metadata: creation_time : 2013-06-10 18:21:11 Stream #0:1(eng): Audio: mp2, 48000 Hz, stereo, s16, 128 kb/s Metadata: creation_time : 2013-06-10 18:21:11 Stream mapping: Stream #0:0 -> #0:0 (h264 -> mpeg2video) Stream #0:1 -> #0:1 (aac -> mp2) Press [q] to stop, [?] for help frame= 182 fps=0.0 q=24.8 size= 528kB time=00:00:06.25 bitrate= 691.6kbits frame= 380 fps=379 q=31.0 size= 1076kB time=00:00:12.97 bitrate= 679.4kbits frame= 548 fps=364 q=31.0 size= 1704kB time=00:00:18.49 bitrate= 754.8kbits frame= 692 fps=345 q=31.0 size= 2390kB time=00:00:23.26 bitrate= 841.4kbits frame= 815 fps=325 q=31.0 size= 3170kB time=00:00:27.30 bitrate= 951.2kbits frame= 950 fps=316 q=24.8 size= 4146kB time=00:00:31.78 bitrate=1068.4kbits frame= 1079 fps=307 q=31.0 size= 5154kB time=00:00:36.13 bitrate=1168.5kbits frame= 1242 fps=309 q=31.0 size= 5868kB time=00:00:41.65 bitrate=1154.0kbits frame= 1413 fps=313 q=31.0 size= 6586kB time=00:00:47.31 bitrate=1140.2kbits frame= 1587 fps=316 q=31.0 size= 7346kB time=00:00:53.14 bitrate=1132.2kbits frame= 1753 fps=318 q=31.0 size= 8026kB time=00:00:58.66 bitrate=1120.7kbits frame= 1925 fps=320 q=31.0 size= 8798kB time=00:01:04.35 bitrate=1119.9kbits frame= 2091 fps=321 q=31.0 size= 9646kB time=00:01:10.02 bitrate=1128.5kbits frame= 2226 fps=317 q=31.0 size= 10484kB time=00:01:14.48 bitrate=1153.0kbits frame= 2386 fps=317 q=31.0 size= 11232kB time=00:01:19.86 bitrate=1152.1kbits frame= 2554 fps=318 q=31.0 size= 11852kB time=00:01:25.40 bitrate=1136.8kbits frame= 2759 fps=324 q=31.0 size= 12396kB time=00:01:32.14 bitrate=1102.0kbits frame= 2813 fps=325 q=31.0 Lsize= 12546kB time=00:01:33.94 bitrate=1094.0kbits/s video:10904kB audio:1468kB subtitle:0 global headers:0kB muxing overhead 1.402856%
Darth AndroidTry:
ffmpeg.exe -i "C:/Path/to/your/video.mkv" -vcodec mpeg2video -acodec mp2 -f vob -y "C:/Path/to/output/video.mpg"where
video.mkvis your source file and andvideo.mpgis your output.-vcodec mpeg2videosets the output video format to MPEG2
-acodec mp2sets the output audio format to MPEG2-f vobsets the output container/file format to Vob (*.mpg)
-yoverwrites target file.
ArtOfWarfareI finally found a format that worked for me on a fresh install of Windows 7 without Windows Media Player or any other codecs:
MPEG-1 Video, 1,280 x 720 MPEG Layer 3, 48000 Hz, Mono(Note the only change was from Stereo to Mono compared to what I had been using when I first posted the question.)
To get it I typed:
ffmpeg -i my-video.mp4 -vcodec mpeg1video -acodec mp2 -ac 1 -f vob my-video-mono.mpgI’d like to thank Darth Android whose answer greatly helped me with learning more about the arguments I needed to provide to ffmpeg.