On Mon, Aug 2, 2010 at 3:14 PM, Hoang Ong <[email protected]> wrote:
> Thank you for your help but It still doesn't work, It cannot pass the
> sws_scale function.
>
> buffer = (uint8_t *)av_malloc(sizeBuffer);
> avpicture_fill((AVPicture*)&pFrameRGB,buffer,
> PIX_FMT_RGB24,pCodecCtx->width,
> pCodecCtx->height);
I double checked your code:
AVFrame *pFrameRGB;
pFrameRGB=avcodec_alloc_frame();
avpicture_fill((AVPicture*)&pFrameRGB,buffer, PIX_FMT_RGB24,pCodecCtx->width,
pCodecCtx->height);
(AVPicture*)&pFrameRGB is wrong, the '&' should be removed
Never touch C++ if you are not familiar with C
--
-----------------------------------------------------------------------------------------
My key fingerprint: d1:03:f5:32:26:ff:d7:3c:e4:42:e3:51:ec:92:78:b2
_______________________________________________
libav-user mailing list
[email protected]
https://lists.mplayerhq.hu/mailman/listinfo/libav-user