The OpenCV Wiki directly solves this problem. See http://opencv.willowgarage.com/wiki/VideoCodecs and, in particular, the heading "Compatibility List".
Unfortunately, the only codecs supported on all three platforms (Linux, Windows, and OSX) are the "DIB" I420 and IYUV, which are uncompressed video codecs and thus make really large file sizes.
The wiki also lists some codecs to try, which can work on any two platforms, but not all three.
If you decide to use uncompressed video files, you can convert them to something with a smaller file size as soon as they are on your Windows computer using a program such as VirtualDub .
Edit: FYI. On Windows, I have OpenCV output in Motion-JPEG, and then I use VirtualDub in direct stream mode to save a file that fixes a movie index error. These M-JPEG video files are then played by default on Mac and Windows.
If I try to read a video in OpenCV, I often convert my video to Cinepak first (using virtual dub, quicktime, etc.) and then upload it to OpenCV. I use Cinepak because, for some reason, Cinepak encoders seem more common than MJPEG encoders.
AndyL source share