Re: How to stop drawing outside of area (masking)?
On 2/12/20 1:24 PM, Schred [via jogamp] wrote:
> I am currently coding my own UI system using JOGL and would like to know how
> to only draw inside a certain area.
> The system is structured like this:
> -components (including other containers)
> and I want the components of a container to only be able to draw in that
> container's area.
> How would I go about doing this?
Try the GL viewport.
On the other hand, it might be nice to have a seamless integration
of the scene and UI as we demo in GraphUI?
If you like (and are free) to collab on UI work,
please email me.
Thanks, I got it now working with gl.glViewport()! One minor inconvenience is that TextRenderer now adjusts the size of the text according to the new viewport, meaning that the smaller the viewport is, the smaller the text is. Maybe I'll figure something out.