Scale the Contents of pixelBuffer

I m newbie to OpenGl.I have 1024768 image in pixel buffer.
But i need a 352
288 image in same pixel buffer.
How can I do it?
I have gone through the topics but couldn’t find an answer.
If the question is repeated kindly excuse me. :slight_smile:

You can upload the data stored in the pixel buffer into a texture using glTexImage2D and render a quad which resizes the image to the needed size in pixel (this needs the correct adjustment of the modelview matrix).
After this you should read back the content of the framebuffer to the pixel buffer using glReadPixels.

Thanks for reply.
But my problem is not solved.I tried like this.


After this i used glReadPixels to read data into pixelBuf and found image is still in 1152*864.

Any help is appreciated.
Thanks in advance