raw2qt264 is a command line encoder using QuickTime H.264 codec for Mac OS X. raw2qt264 reads raw video from ffmpeg via pipe. You can specify pass count and bit rate.
 -[[Source code>http://members3.jcom.home.ne.jp/jacketplugin/raw2qt264.source.zip]]
 raw2qt264.source.zip is Xcode project, so you can modify and build easily.
 2006.1.21 Universal Binary. New Intel iMas is fater 2.5 times than iMac G5.
 *How to use
 % raw2qt264 Pass Kbps rawCommand outFile.mov
 rawCommand is a line command to output yuv4mpegpipe to stdout.
 -Convert inFile.mpg to outFile.mov, pass count is 2 and bit rate is 1000Kbps.
 % raw2qt264 2 1000 "ffmpeg -i inFile.mpg -vcodec rawvideo -f yuv4mpegpipe -" outFile.mov
 -Deinterlace, scale to 640x480 and crop to 90 % using ffmpeg
 % raw2qt264 2 1000 "ffmpeg -i inFile.mpg -deinterlace -s 640x480 -croptop 24 -cropbottom 24 -cropleft 32 -cropright 32 -vcodec rawvideo -f yuv4mpegpipe -" outFile.mov
 ・renice by itself.
 setpriority(PRIO_USER, 0, 10);
 ・Compress setting is in createCompressionSession(). You can find setting items in following header.
 の、Properties of compression sessions options objects.
 ・Key frame rate is currenty 300.
 // Set the maximum key frame interval, also known as the key frame rate.
 err = ICMCompressionSessionOptionsSetMaxKeyFrameInterval(sessionOptions, 300);
 MaxPartialSyncFrameInterval, AllowFrameTimeChanges, DataRateLimits(Hard limit) are set to default.
 Based on following Apple's sample code.
 QuickTime Session API documents