• Advertisement
Sign in to follow this  

UI rendering - clipping

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

im writting some UI Code, but i keep running in to the problem of how to clip stuff so they arent rendered outside of some bounds (such as a box of sphere or some arbitary shape). I've been thinking of using render to texture, render the child windows to a texture, then use the render to render inside the parent window. This seems a bit over the top and was wondering if there was a simpler solution?

Share this post


Link to post
Share on other sites
Advertisement
u could render the shape u want to clip to, into the stencilbuffer.
then draw whatever UI u want, just where stencilbits are set.

it should be pretty easy to realize this.

Share this post


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

  • Advertisement