Skip to main content
gamedev.net
🔒 Locked

BackBuffer to texture

Started by treeway 1 reply 550+ views
Original Post
treeway
treeway
Hi i want to do a differed shader, so i plan on doing the following: - Draw the scene as normal to the back buffer. - getting the back buffer, put it into in a texture. - Aplly the texture to a sprite. - run a shader to draw the sprite. - clear the backbuffer. does anyone know how i can get the backbuffer into a texture? thanks
S1CA
S1CA
IDirect3DDevice9::GetRenderTarget() then IDirect3DDevice9::StretchRect()

An alternative in your case might be to draw your scene to an offscreen render target texture then use that to draw the sprite(s) so you never need to copy the backbuffer.
Simon O'Connor | Technical Director (Newcastle) Lockwood Publishing | LinkedIn | Personal site
ET3D
ET3D
Yeah, render targets are your friends.

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.