Render to a texture without using a FBO ?

Started by
3 comments, last by FlyingSolo 10 years, 11 months ago

Hi Folks,

My ogl is a bit rusty and none of the books I've got seem to cover this topic. What I'd like to do is render to a texture which I can later render to screen in the normal way - but without using FBO's. This is a 2D (Ortho) app where speed isn't a major concern.

Is this even feasible? If so, how !?

Many thanks :)

Advertisement

Render to the screen, glCopyTexImage to copy screen to texture.

NBA2K, Madden, Maneater, Killing Floor, Sims http://www.pawlowskipinball.com/pinballeternal

Ah, thanks for that - and indeed that will work, but I deliberately want (and need) to render to a texture.

Back story:- I've already got all the textures I need for this project (there's a LOT of them) but they're geared up for a full-screen program. What I want to do is draw to a full-sized (hidden) texture, and then copy that texture to the screen - reducing its size as I do so.

I hope that makes sense... it's 01:30 here and I'm past tired!!

Thanks :)

As another alternative you could look at the old pbuffer extensions - but beware; they have a reputation for being horrible to use and the dubious notoriety for putting John Carmack the closest he's ever been to switching to D3D.

Is there any specific reason why glCopyTex(Sub)Image won't do what you need? From the way you describe your requirement, it looks like a good fit:

  • Draw your main scene.
  • Make a glCopyTex(Sub)Image call.
  • Draw the copied scene as a scaled-down fullscreen quad.

Direct3D has need of instancing, but we do not. We have plenty of glVertexAttrib calls.

There more I think about it, the more this does look like a glCopyTexImage job. Problem with being rusty is that the most obvious solutions don't leap to mind !

I've heard enough horror stories about pbuffers that I deliberately avoided them - and hence my post here!

Thanks for listening guys, I'll go have a play :)

This topic is closed to new replies.

Advertisement