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

#include <RenderTypePlugin.hpp>

Public Attributes

RenderContext & render_context
resource::ResourceManager & resources
u32 white_texture_id = 0
u32 batch_shader_id = 0
RenderStage current_stage = RenderStage::Transparent
glm::mat4 view_projection {1.0f}
const MaterialStore * materials = nullptr
RenderFrame * frame = nullptr
 The owning frame, for lazily-compiled batch variants (RenderFrame::batchProgram).
RenderPurpose purpose = RenderPurpose::Scene
u32 shadow_texture_id = 0
 The map that pass produced, handed to the meshes that receive it (0 = none).
u32 environment_texture_id = 0
 The frame environment's prefiltered reflection atlas (0 = none this frame).
bool gbuffer = false
bool track_motion = false
u64 motion_key = 0
u64 motion_frame = 0
glm::mat4 motion_prev_view_projection {1.0f}
glm::vec2 motion_prev_jitter {0.0f}
glm::vec3 view_eye {0.0f}
bool has_view_eye = false
bool lighting_direct = false
bool rainCover = false
bool causticReceivers = false
 Opaque geometry seen by refracted sunlight, including objects with shadow casting disabled.

Detailed Description

Definition at line 63 of file RenderTypePlugin.hpp.

Member Data Documentation

◆ batch_shader_id

u32 esengine::RenderFrameContext::batch_shader_id = 0

Definition at line 67 of file RenderTypePlugin.hpp.

◆ causticReceivers

bool esengine::RenderFrameContext::causticReceivers = false

Opaque geometry seen by refracted sunlight, including objects with shadow casting disabled.

Definition at line 103 of file RenderTypePlugin.hpp.

◆ current_stage

RenderStage esengine::RenderFrameContext::current_stage = RenderStage::Transparent

Definition at line 68 of file RenderTypePlugin.hpp.

◆ environment_texture_id

u32 esengine::RenderFrameContext::environment_texture_id = 0

The frame environment's prefiltered reflection atlas (0 = none this frame).

Definition at line 79 of file RenderTypePlugin.hpp.

◆ frame

RenderFrame* esengine::RenderFrameContext::frame = nullptr

The owning frame, for lazily-compiled batch variants (RenderFrame::batchProgram).

Definition at line 72 of file RenderTypePlugin.hpp.

◆ gbuffer

bool esengine::RenderFrameContext::gbuffer = false

The pass these draws execute in has a second colour attachment for the surface's material, so a shader that can write it is asked for the variant that does. False for every other collect.

Definition at line 82 of file RenderTypePlugin.hpp.

◆ has_view_eye

bool esengine::RenderFrameContext::has_view_eye = false

Definition at line 96 of file RenderTypePlugin.hpp.

◆ lighting_direct

bool esengine::RenderFrameContext::lighting_direct = false

Definition at line 97 of file RenderTypePlugin.hpp.

◆ materials

const MaterialStore* esengine::RenderFrameContext::materials = nullptr

Definition at line 70 of file RenderTypePlugin.hpp.

◆ motion_frame

u64 esengine::RenderFrameContext::motion_frame = 0

Definition at line 87 of file RenderTypePlugin.hpp.

◆ motion_key

u64 esengine::RenderFrameContext::motion_key = 0

Definition at line 86 of file RenderTypePlugin.hpp.

◆ motion_prev_jitter

glm::vec2 esengine::RenderFrameContext::motion_prev_jitter {0.0f}

Definition at line 92 of file RenderTypePlugin.hpp.

◆ motion_prev_view_projection

glm::mat4 esengine::RenderFrameContext::motion_prev_view_projection {1.0f}

Last frame's view-projection (the engine's convention, unjittered) and the shift in NDC that frame was drawn with: what the Motion collect writes into each record, so a displacement lands on the raster the previous picture was actually drawn on.

Definition at line 91 of file RenderTypePlugin.hpp.

◆ purpose

RenderPurpose esengine::RenderFrameContext::purpose = RenderPurpose::Scene

What this collect is for. The frame sets it, and also skips every plugin that casts nothing when the purpose is a shadow map.

Definition at line 75 of file RenderTypePlugin.hpp.

◆ rainCover

bool esengine::RenderFrameContext::rainCover = false

This shadow-depth collect is the RAIN's map of what stands overhead, not a light's: what keeps rain off is solid whether or not light passes it, so a see-through surface that casts no shadow (a glass roof) is in it all the same. Last, so the positional initialisers before it keep their places.

Definition at line 101 of file RenderTypePlugin.hpp.

◆ render_context

RenderContext& esengine::RenderFrameContext::render_context

Definition at line 64 of file RenderTypePlugin.hpp.

◆ resources

resource::ResourceManager& esengine::RenderFrameContext::resources

Definition at line 65 of file RenderTypePlugin.hpp.

◆ shadow_texture_id

u32 esengine::RenderFrameContext::shadow_texture_id = 0

The map that pass produced, handed to the meshes that receive it (0 = none).

Definition at line 77 of file RenderTypePlugin.hpp.

◆ track_motion

bool esengine::RenderFrameContext::track_motion = false

A temporal effect in the chain reads per-object motion, so the scene collect remembers where each mesh was, and the Motion collect has something to compare against. Per view: motion_key names which.

Definition at line 85 of file RenderTypePlugin.hpp.

◆ view_eye

glm::vec3 esengine::RenderFrameContext::view_eye {0.0f}

Where the SCENE camera is, in every collect of the frame (a shadow map's included): what a distance-limited draw measures from. Absent for an orthographic camera, which has no position to be far from.

Definition at line 95 of file RenderTypePlugin.hpp.

◆ view_projection

glm::mat4 esengine::RenderFrameContext::view_projection {1.0f}

Definition at line 69 of file RenderTypePlugin.hpp.

◆ white_texture_id

u32 esengine::RenderFrameContext::white_texture_id = 0

Definition at line 66 of file RenderTypePlugin.hpp.


The documentation for this struct was generated from the following file: