Encyclopedia of image processing algorithms (based libyuv or IPP) ---- YV12 turn RGBA

Disclaimer: This article is a blogger original article, shall not be reproduced without the bloggers allowed. https://blog.csdn.net/xjb2006/article/details/80826516

"Zhou stars to teach you to learn ffmpeg" skills

libyuv Source:

static int YV12ToARGB(const uint8* src_frame,uint8* dst_frame,int width,int height)
{
const uint8* yplane= src_frame;
const uint8* uplane= src_frame + width * height;
const uint8* vplane= uplane+ (width * height/4);
int n = libyuv::I420ToARGB(yplane,width,uplane, width/2,vplane, width/2,dst_frame, width*4,width, height);

return n;

        }


Call YV12ToARGB (pIn, pOut, 1920, 1080,); // convert the image 1080P @ YUV420P ARGB32 bit color space is RGB format (for display or other needs OPENGL RGB 32-bit environment)


Contact the author in question QQ: 35744025


Guess you like

Origin blog.csdn.net/xjb2006/article/details/80826516