avcodec YUV to RGB

时光怂恿深爱的人放手 提交于 2019-12-01 07:02:20

av_frame_alloc only allocates memory for the frame object itself, it does not allocate memory to store the image data. Have you done:

FillVect.resize( avpicture_get_size( PIX_FMT_RGB24, FrameWidth, FrameHeight ) );

somewhere in your code before calling avpicture_fill? Or some other way to make sure FillVect allocates enough memory to keep the whole decoded picture?

Did you try to run it under valgrind to see what exactly trigges SEGFAULT?

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!