Estella 0.113.0
A fast 2D and 3D game engine powered by WebAssembly and ECS
Loading...
Searching...
No Matches
esengine::FramebufferSpec Struct Reference

Framebuffer creation parameters. More...

#include <Framebuffer.hpp>

Public Attributes

u32 width = 1280
 Framebuffer width in pixels.
u32 height = 720
 Framebuffer height in pixels.
u32 samples = 1
 Number of samples for MSAA (1 = no multisampling).
bool depthStencil = true
 Whether to create depth/stencil attachment.
bool linearFilter = false
 Texture filter mode: false=GL_NEAREST, true=GL_LINEAR.
GfxPixelFormat colorFormat = GfxPixelFormat::RGBA8
 Color attachment format. RGBA16F needs GfxDevice::supportsFloatTargets.
bool gbuffer = false
 A second colour attachment (RGBA8) drawn in the same pass: the surface's material, for effects that need to know what they are looking at.
bool storage = false
 The colour attachment can also be written by a compute shader (GfxDevice::supportsCompute).
bool mipmaps = false

Detailed Description

Framebuffer creation parameters.

Specifies the dimensions and attachment configuration for an off-screen rendering target.

spec.width = 1280;
spec.height = 720;
spec.samples = 1; // No multisampling
auto fbo = Framebuffer::create(spec);
static Unique< Framebuffer > create(GfxDevice &device, const FramebufferSpec &spec)
Creates a framebuffer from specification.
Framebuffer creation parameters.
u32 samples
Number of samples for MSAA (1 = no multisampling).
u32 height
Framebuffer height in pixels.
u32 width
Framebuffer width in pixels.

Definition at line 46 of file Framebuffer.hpp.

Member Data Documentation

◆ colorFormat

◆ depthStencil

bool esengine::FramebufferSpec::depthStencil = true

◆ gbuffer

bool esengine::FramebufferSpec::gbuffer = false

A second colour attachment (RGBA8) drawn in the same pass: the surface's material, for effects that need to know what they are looking at.

Definition at line 60 of file Framebuffer.hpp.

Referenced by esengine::rg::TargetPool::acquire().

◆ height

◆ linearFilter

bool esengine::FramebufferSpec::linearFilter = false

◆ mipmaps

bool esengine::FramebufferSpec::mipmaps = false

Definition at line 63 of file Framebuffer.hpp.

◆ samples

u32 esengine::FramebufferSpec::samples = 1

Number of samples for MSAA (1 = no multisampling).

Definition at line 52 of file Framebuffer.hpp.

Referenced by esengine::rg::TargetPool::acquire().

◆ storage

bool esengine::FramebufferSpec::storage = false

The colour attachment can also be written by a compute shader (GfxDevice::supportsCompute).

Definition at line 62 of file Framebuffer.hpp.

Referenced by esengine::rg::TargetPool::acquire().

◆ width


The documentation for this struct was generated from the following file:
  • /home/runner/work/estella/estella/src/esengine/renderer/rhi/Framebuffer.hpp