/** Creates a new FrameBuffer with a float backing texture, having the given dimensions and potentially a depth buffer attached. * * @param width the width of the framebuffer in pixels * @param height the height of the framebuffer in pixels * @param hasDepth whether to attach a depth buffer * @throws GdxRuntimeException in case the FrameBuffer could not be created */ public FloatFrameBuffer (int width, int height, boolean hasDepth) { FloatFrameBufferBuilder bufferBuilder = new FloatFrameBufferBuilder(width, height); bufferBuilder.addFloatAttachment(GL30.GL_RGBA32F, GL30.GL_RGBA, GL30.GL_FLOAT, false); if (hasDepth) bufferBuilder.addBasicDepthRenderBuffer(); this.bufferBuilder = bufferBuilder; build(); }
/** Creates a new FrameBuffer with a float backing texture, having the given dimensions and potentially a depth buffer attached. * * @param width the width of the framebuffer in pixels * @param height the height of the framebuffer in pixels * @param hasDepth whether to attach a depth buffer * @throws GdxRuntimeException in case the FrameBuffer could not be created */ public FloatFrameBuffer (int width, int height, boolean hasDepth) { FloatFrameBufferBuilder bufferBuilder = new FloatFrameBufferBuilder(width, height); bufferBuilder.addFloatAttachment(GL30.GL_RGBA32F, GL30.GL_RGBA, GL30.GL_FLOAT, false); if (hasDepth) bufferBuilder.addBasicDepthRenderBuffer(); this.bufferBuilder = bufferBuilder; build(); }
/** Creates a new FrameBuffer with a float backing texture, having the given dimensions and potentially a depth buffer attached. * * @param width the width of the framebuffer in pixels * @param height the height of the framebuffer in pixels * @param hasDepth whether to attach a depth buffer * @throws GdxRuntimeException in case the FrameBuffer could not be created */ public FloatFrameBuffer (int width, int height, boolean hasDepth) { FloatFrameBufferBuilder bufferBuilder = new FloatFrameBufferBuilder(width, height); bufferBuilder.addFloatAttachment(GL30.GL_RGBA32F, GL30.GL_RGBA, GL30.GL_FLOAT, false); if (hasDepth) bufferBuilder.addBasicDepthRenderBuffer(); this.bufferBuilder = bufferBuilder; build(); }