add comments and adjust formatting
This commit is contained in:
parent
1993452669
commit
600e34d1fe
|
@ -76,6 +76,11 @@ public class CurveRenderState {
|
|||
FrameBufferCache.init(width, height);
|
||||
}
|
||||
|
||||
/**
|
||||
* Undo the static state. Static state setup caused by calls to
|
||||
* {@link #draw(org.newdawn.slick.Color, org.newdawn.slick.Color, itdelatrisu.opsu.objects.curves.Vec2f[])}
|
||||
* are undone.
|
||||
*/
|
||||
public static void shutdown()
|
||||
{
|
||||
staticState.shutdown();
|
||||
|
@ -144,7 +149,7 @@ public class CurveRenderState {
|
|||
}
|
||||
|
||||
/**
|
||||
* Discard the cache.
|
||||
* Discard the cache mapping for this curve object
|
||||
*/
|
||||
public void discardCache() {
|
||||
fbo = null;
|
||||
|
@ -454,6 +459,9 @@ public class CurveRenderState {
|
|||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Cleanup any OpenGL objects that may have been initialized.
|
||||
*/
|
||||
private void shutdown()
|
||||
{
|
||||
if(gradientTexture != 0)
|
||||
|
|
|
@ -122,11 +122,14 @@ public class FrameBufferCache {
|
|||
return buffer;
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear the cache pool of Framebuffers.
|
||||
* If there were any previous Framebuffers in the cache delete them
|
||||
* this is necessary for cases when the game gets re-started with a
|
||||
* different resolution without closing the process
|
||||
*/
|
||||
public static void shutdown()
|
||||
{
|
||||
//if there were any previous Framebuffers in the cache delete them
|
||||
//this is necessary for cases when the game gets re-started with a
|
||||
//different resolution without closing the process
|
||||
FrameBufferCache fbcInstance = FrameBufferCache.getInstance();
|
||||
for(Rendertarget target: fbcInstance.cache)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue
Block a user