Package arc.graphics.gl
Class FloatFrameBuffer
- All Implemented Interfaces:
Disposable
This is a
FrameBuffer
variant backed by a float texture.-
Nested Class Summary
Nested classes/interfaces inherited from class arc.graphics.gl.GLFrameBuffer
GLFrameBuffer.FloatFrameBufferBuilder, GLFrameBuffer.FrameBufferBuilder, GLFrameBuffer.FrameBufferCubemapBuilder, GLFrameBuffer.FrameBufferRenderBufferAttachmentSpec, GLFrameBuffer.FrameBufferTextureAttachmentSpec, GLFrameBuffer.GLFrameBufferBuilder<U extends GLFrameBuffer<? extends GLTexture>>
-
Field Summary
Fields inherited from class arc.graphics.gl.GLFrameBuffer
bufferBuilder, bufferNesting, currentBoundFramebuffer, defaultFramebufferHandle, defaultFramebufferHandleInitialized, depthbufferHandle, depthStencilPackedBufferHandle, framebufferHandle, GL_DEPTH24_STENCIL8_OES, hasDepthStencilPackedBuffer, isMRT, lastBoundFramebuffer, stencilbufferHandle, textureAttachments
-
Constructor Summary
ModifierConstructorDescriptionFloatFrameBuffer
(int width, int height, boolean hasDepth) Creates a new FrameBuffer with a float backing texture, having the given dimensions and potentially a depth buffer attached.protected
FloatFrameBuffer
(GLFrameBuffer.GLFrameBufferBuilder<? extends GLFrameBuffer<Texture>> bufferBuilder) Creates a GLFrameBuffer from the specifications provided by bufferBuilder -
Method Summary
Modifier and TypeMethodDescriptionprotected void
create
(Pixmap.Format format, int width, int height, boolean hasDepth, boolean hasStencil) protected Texture
createTexture
(GLFrameBuffer.FrameBufferTextureAttachmentSpec attachmentSpec) Override this method in a derived class to set up the backing texture as you like.void
resize
(int width, int height) Note that this does nothing if the width and height are the same.Methods inherited from class arc.graphics.gl.FrameBuffer
attachFrameBufferColorTexture, blit, disposeColorTexture, resizeCheck, unbind
Methods inherited from class arc.graphics.gl.GLFrameBuffer
begin, begin, beginBind, bind, build, dispose, end, endBind, getBufferNesting, getDepthBufferHandle, getDepthStencilPackedBuffer, getFramebufferHandle, getHeight, getStencilBufferHandle, getTexture, getTextureAttachments, getWidth, isBound, setFrameBufferViewport
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface arc.util.Disposable
isDisposed
-
Constructor Details
-
FloatFrameBuffer
protected FloatFrameBuffer(GLFrameBuffer.GLFrameBufferBuilder<? extends GLFrameBuffer<Texture>> bufferBuilder) Creates a GLFrameBuffer from the specifications provided by bufferBuilder -
FloatFrameBuffer
public FloatFrameBuffer(int width, int height, boolean hasDepth) Creates a new FrameBuffer with a float backing texture, having the given dimensions and potentially a depth buffer attached.- Parameters:
width
- the width of the framebuffer in pixelsheight
- the height of the framebuffer in pixelshasDepth
- whether to attach a depth buffer- Throws:
ArcRuntimeException
- in case the FrameBuffer could not be created
-
-
Method Details
-
create
protected void create(Pixmap.Format format, int width, int height, boolean hasDepth, boolean hasStencil) - Overrides:
create
in classFrameBuffer
-
resize
public void resize(int width, int height) Description copied from class:FrameBuffer
Note that this does nothing if the width and height are the same.- Overrides:
resize
in classFrameBuffer
-
createTexture
Description copied from class:GLFrameBuffer
Override this method in a derived class to set up the backing texture as you like.- Overrides:
createTexture
in classFrameBuffer
-