Reading texture data from GLES

Discussion of issues specific to mobile platforms such as iOS, Android, Symbian and Meego.
Post Reply
mannam
Halfling
Posts: 45
Joined: Tue Feb 15, 2011 7:23 am

Reading texture data from GLES

Post by mannam » Tue Feb 25, 2014 4:07 am

I know GLES don't have glGetTexImage.

Someone suggests binding the texture to FBO and use glReadPixels to get the data.

How to do this in Ogre? Thanks.
0 x

User avatar
masterfalcon
OGRE Team Member
OGRE Team Member
Posts: 4270
Joined: Sun Feb 25, 2007 4:56 am
Location: Bloomington, MN
Contact:

Re: Reading texture data from GLES

Post by masterfalcon » Tue Feb 25, 2014 5:44 am

If you are using GL ES 2 and Ogre 1.9 you can use GLES2TextureBuffer::download.
0 x

mannam
Halfling
Posts: 45
Joined: Tue Feb 15, 2011 7:23 am

Re: Reading texture data from GLES

Post by mannam » Tue Feb 25, 2014 6:54 am

Thanks. But how about Ogre 1.8?
0 x

User avatar
masterfalcon
OGRE Team Member
OGRE Team Member
Posts: 4270
Joined: Sun Feb 25, 2007 4:56 am
Location: Bloomington, MN
Contact:

Re: Reading texture data from GLES

Post by masterfalcon » Tue Feb 25, 2014 6:59 am

Sorry, it's a feature that was added for 1.9. There are no plans to back port it to 1.8. However the code is pretty well contained within that function so you could just copy/paste it from 1.9 if you wish.
0 x

mannam
Halfling
Posts: 45
Joined: Tue Feb 15, 2011 7:23 am

Re: Reading texture data from GLES

Post by mannam » Tue Feb 25, 2014 9:49 am

Okay, thank you!
0 x

Post Reply