Stas ha escrit:
[Quoted Text] > Hi. > > Does anyone have a working user allocated sample, allowing to create a > buffer of samples prior to sending them to the Writer object? > > Thanks in advance, > Stas.
Hi Stas,
You just need to create your samples calling: hr=pPortraitWriter->AllocateSample(dwLength, &pMyINSBuff);
where dwLength, is, tipically imgWidth*imgWeigth*(colorDepth/8) (if your bitmaps are RGB)
after creating the INSBuffer, retrieve a pointer to the buffer itself: hr=pMyINSBuff->GetBuffer(&pbBuffDest); //BYTE *pbBuffDest;
copy/create/whatever your bitmaps to pbBuffDest and call the writer:
hr=pWriter->WriteSample(dwInput, qwTime, dwFlags, pMyINSBuff);
And... thats all if i understood your question! :)
Vegethalia -------------------------------- http://www.pleyhades.com
|