read values from a texture

Started by
0 comments, last by Gorax 18 years, 9 months ago
if there is a function for it, i cant find it. Is there a way to read the values from an openggl texture into an array? Specifically, a floating point texture into an array of floats. I can do it if i render the texture to the color buffer then use glReadPixels(), but the results are clamped from 0..1 :( Cheers for any help Muncher btw, using C++ ;)
Advertisement
Try glGetTexImage(). One thing to note: if you don't plan on storing the width and height of the texture somewhere in your program, you may want to read that page for information on how to get the texture width and height.

This topic is closed to new replies.

Advertisement