Jump to content
  • Advertisement
Sign in to follow this  
Scythen

Render to texture problem... help please...

This topic is 4687 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Ok, my problem is with texture rendering and multisampling. I would like to render to a texture with multisampling but no matter what I try, I can’t seem to get a render target with multisampling. My hardware supports multisampling (GeForce6) but CreateRenderTarget always fails if I have any form of multisampling. Also, how does one use a surface created with CreateRenderTarget as a texture? Since the surface is not part of a texture, GetContainer always failes. Can this only be done by copying the render target surface to a texture surface? Without multisampling, I just render to a texture surface created with the render target flag and that works fine. Apparently, texture can’t be created with multisampling enabled (guess that makes sense).

Share this post


Link to post
Share on other sites
Advertisement
Quote:
Original post by Scythen
Ok, my problem is with texture rendering and multisampling.

I would like to render to a texture with multisampling but no matter what I try, I can’t seem to get a render target with multisampling. My hardware supports multisampling (GeForce6) but CreateRenderTarget always fails if I have any form of multisampling.


What does the debug output say?

Quote:

Also, how does one use a surface created with CreateRenderTarget as a texture?
Since the surface is not part of a texture, GetContainer always failes.
Can this only be done by copying the render target surface to a texture surface?

Without multisampling, I just render to a texture surface created with the render target flag and that works fine. Apparently, texture can’t be created with multisampling enabled (guess that makes sense).


A surface is not the same as a texture, so a surface cannot be used as a texture. Your options are to copy the surface to a texture, or create a texture with the render target flag.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!