The assumptions made above were that you wanted your output video to be:
439 pixels wide
455 pixels high
trimming 73 pixels from the left
trimming 15 pixels from the top
of your input video, and that you wanted Motion JPEG output e.g. “-vcodec mjpeg“.
The “-qscale 1” makes low compression (best possible MJPEG quality). qscale can go from 1 to 31 in the current version of ffmpeg.
Obviously, change these pixel parameters to suit your particular video.
The vision.VideoFileReader method will issue a “Could not open the specified file” error if you use the ~ in the filename for your home directory. The ~ notation works for every other Matlab command but vision.VideoFileReader
LabVIEW 2011 has only a few toolkits that work as a 64-bit installation on 64-bit Windows 7. You can see the list of the supported LabVIEW 64-bit toolkits at:
With regard to Device Drivers, the same Device Drivers DVD or download (4.8GB) is used for 32-bit and 64-bit LabVIEW. When you start the Device Driver installation, you will be prompted for each available items whether you want 32-bit or 64-bit.
National Instruments notes that you can install both 32-bit and 64-bit LabVIEW on a Windows 7 x64 system, and virtually all toolkits are said to work for a 32-bit LabVIEW install on a Windows 7 x64 (64-bit) system. There is said to a bit a of a performance penalty for using 32-bit LabVIEW on 64-bit Windows 7, due the Windows on Windows (WoW) emulation layer, but I haven’t yet found any benchmarks supporting what the difference is. Perhaps something I’ll post on in the future.
MATLAB on Linux claims to only playback uncompressed AVI files on “UNIX” systems.
However, MATLAB on Linux can’t even play all uncompressed AVI filed depending on your particular system configuration with gstreamer. The solution thus far, with MATLAB 2012a, seems to be using Motion JPEG in AVI videos.
Here’s a tentative solution for playing back video on Linux systems with MATLAB 2012a, that is, MATLAB “should” be able to playback “out.avi”
If you get an error about not having ffmpeg installed, on Ubuntu type in Terminal:
sudo apt-get install ffmpeg
Here is a video I transcoded the first second of using the above settings
(here is the actual command I used to truncate the video to one second and to heavily compress to reduce download size) ffmpeg -i input.avi -vcodec mjpeg -t 1 -qscale 11 out.avi
(The sample AVI file is used under GNU LGPL from http://people.sc.fsu.edu/~jburkardt/data/avi/avi.html )