I have a utility that uses avifile to perform encoding.
Until recently, this is how I was able to change the encoding bitrate (for
DIV3/4/5/6 codecs)
const CodecInfo *codecInfo = CodecInfo::match ( codec );
[...]
Creators::SetCodecAttr ( *codecInfo, "BitRate", bitrate );
[...]
IAviVideoWriteStream *stream = avifile->AddVideoStream ( opt_codec, &bh, ( int
) time_between_frames );
stream->Start ( );
The resulting output with CVS avifile is (assuming I pass 800 in as
bitrate) [relevant excerpt, I think]:
<Win32 video encoder> : BitRate 800 (910.000000)
<Win32 video encoder> : W32 Quality 0 KeyFrames: 15 BitRate: 800000000
<Win32 video encoder> : BitRate 800 (800.000000)
<Win32 video encoder> : W32 Quality 0 KeyFrames: 15 BitRate: 800000000
...
<Win32 loader> : Total Unfree 0 bytes cnt 0 [(nil),0]r second.
It seems like the bitrate is being set in the codec. But no matter what
bitrate I pass in for a given codec, I get the same size file. The file
size differs from codec to codec, but it doesn't matter what the bitrate is
-- only which codec is chosen.
This method has worked for several months of CVS avifile. It was broken for
a while in October/November as a result of some registry foolishness. I've
looked a bit at the code in question (plugins/libwin32/videocodec) and it
does not seem to be the case this time around.
Any ideas?
[BTW, should I post a patch to fix the compile problems when you don't have
X or SDL to the list or should I send it directly to someone?]
_______________________________________________
Avifile mailing list
[EMAIL PROTECTED]
http://prak.org/mailman/listinfo/avifile