Sign in to follow this  

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

This topic is 4384 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
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

This topic is 4384 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.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this