Jump to content

  • Log In with Google      Sign In   
  • Create Account

FREE SOFTWARE GIVEAWAY

We have 4 x Pro Licences (valued at $59 each) for 2d modular animation software Spriter to give away in this Thursday's GDNet Direct email newsletter.


Read more in this forum topic or make sure you're signed up (from the right-hand sidebar on the homepage) and read Thursday's newsletter to get in the running!


randomguy2000

Member Since 25 Dec 2012
Offline Last Active Dec 29 2012 11:02 AM

Posts I've Made

In Topic: Using stencil buffer to draw reflections

25 December 2012 - 03:30 PM

When should I be clearing it? If you mean before I start drawing each frame, then yes:

    GL11.glClear(GL11.GL_COLOR_BUFFER_BIT | GL11.GL_DEPTH_BUFFER_BIT | GL11.GL_STENCIL_BUFFER_BIT);
    GL11.glClearColor(0, 0, 0, 1);

 

If you mean something else, then probably not. What is posted above is all the code that does anything with the stencil buffer.


PARTNERS