Blender V5.3
blender::workbench::SceneState Struct Reference

#include <workbench_private.hh>

Public Member Functions

void init (const DRWContext *context, bool scene_updated, Object *camera_ob=nullptr)

Public Attributes

Scene * scene = nullptr
Object * camera_object = nullptr
Camera * camera = nullptr
float4x4 view_projection_matrix = float4x4::identity()
float3 view_forward {0}
int2 resolution = int2(0)
eContextObjectMode object_mode = CTX_MODE_OBJECT
View3DShading shading = {}
eLightingType lighting_type = eLightingType::STUDIO
bool xray_mode = false
DRWState cull_state = DRW_STATE_NO_DRAW
Vector< float4 > clip_planes
float4 background_color = float4(0)
bool draw_cavity = false
bool draw_curvature = false
bool draw_shadows = false
bool draw_outline = false
bool draw_dof = false
bool draw_aa = false
bool draw_object_id = false
bool shadows_use_rt = false
int sample = 0
int samples_len = 0
bool reset_taa_next_sample = false
bool render_finished = false
bool updated = false
Material material_override = Material(float3(1.0f))
Material material_attribute_color = Material(float3(-1.0f))
bool show_paint_bvh_debug = false

Detailed Description

Definition at line 155 of file workbench_private.hh.

Member Function Documentation

◆ init()

void blender::workbench::SceneState::init ( const DRWContext * context,
bool scene_updated,
Object * camera_ob = nullptr )

Definition at line 100 of file workbench_state.cc.

References blender::RenderData::alphamode, blender::assign_if_different(), blender::View3DShading::background_color, background_color, blender::View3DShading::background_type, blender::CAM_DOF_ENABLED, blender::View3D::camera, camera, camera_object, blender::View3DShading::cavity_type, blender::RegionView3D::clip, clip_planes, blender::View3DShading::color_type, blender::CTX_data_mode_enum_ex(), cull_state, blender::Paint::debug_flags, blender::draw::View::default_get(), blender::DEG_get_evaluated_scene(), blender::Scene::display, draw_aa, draw_cavity, draw_curvature, draw_dof, draw_object_id, draw_outline, draw_shadows, blender::DRW_object_get_data_for_drawing(), blender::DRW_STATE_CLIP_PLANES, blender::DRW_STATE_CULL_BACK, blender::DRW_STATE_NO_DRAW, ELEM, blender::View3DShading::flag, blender::draw::View::forward(), blender::GPU_ray_query_support(), blender::IndexRange::IndexRange(), blender::View3DShading::light, lighting_type, blender::workbench::Material::Material(), material_override, blender::max_ii(), blender::min_ii(), blender::OB_CAMERA, blender::OB_MATERIAL, blender::OB_RENDER, blender::OB_SOLID, object_mode, blender::Sculpt::paint, blender::PAINT_DEBUG_SHOW_BVH_NODES, blender::draw::View::persmat(), blender::RegionView3D::persp, blender::Scene::r, blender::R_ALPHAPREMUL, blender::SceneDisplay::render_aa, render_finished, reset_taa_next_sample, resolution, blender::RegionView3D::rflag, blender::RV3D_BOXCLIP, blender::RV3D_CAMOB, RV3D_CLIPPING_ENABLED, blender::RV3D_GPULIGHT_UPDATE, RV3D_LOCK_FLAGS, sample, samples_len, scene, blender::ToolSettings::sculpt, blender::SceneDisplay::shading, blender::View3D::shading, shading, SHADING_XRAY_ALPHA, SHADING_XRAY_ENABLED, shadows_use_rt, show_paint_bvh_debug, blender::View3DShading::single_color, blender::Scene::toolsettings, blender::Object::type, blender::View3DShading::type, blender::U, UNPACK3, updated, blender::USER_GPU_FLAG_WORKBENCH_RT_SHADOWS, blender::V3D_LIGHTING_FLAT, blender::V3D_SHADING_BACKFACE_CULLING, blender::V3D_SHADING_BACKGROUND_VIEWPORT, blender::V3D_SHADING_CAVITY, blender::V3D_SHADING_CAVITY_BOTH, blender::V3D_SHADING_CAVITY_CURVATURE, blender::V3D_SHADING_CAVITY_SSAO, blender::V3D_SHADING_DEPTH_OF_FIELD, blender::V3D_SHADING_OBJECT_COLOR, blender::V3D_SHADING_OBJECT_OUTLINE, blender::V3D_SHADING_SHADOW, view_forward, view_projection_matrix, blender::SceneDisplay::viewport_aa, w(), blender::Scene::world, blender::View3DShading::xray_alpha, and xray_mode.

Member Data Documentation

◆ background_color

float4 blender::workbench::SceneState::background_color = float4(0)

Definition at line 173 of file workbench_private.hh.

Referenced by blender::workbench::SceneResources::init(), and init().

◆ camera

Camera* blender::workbench::SceneState::camera = nullptr

Definition at line 159 of file workbench_private.hh.

Referenced by blender::workbench::DofPass::init(), and init().

◆ camera_object

Object* blender::workbench::SceneState::camera_object = nullptr

Definition at line 158 of file workbench_private.hh.

Referenced by blender::workbench::DofPass::init(), and init().

◆ clip_planes

◆ cull_state

◆ draw_aa

bool blender::workbench::SceneState::draw_aa = false

Definition at line 180 of file workbench_private.hh.

Referenced by blender::workbench::AntiAliasingPass::init(), and init().

◆ draw_cavity

bool blender::workbench::SceneState::draw_cavity = false

◆ draw_curvature

bool blender::workbench::SceneState::draw_curvature = false

◆ draw_dof

bool blender::workbench::SceneState::draw_dof = false

◆ draw_object_id

bool blender::workbench::SceneState::draw_object_id = false

Definition at line 182 of file workbench_private.hh.

Referenced by init().

◆ draw_outline

bool blender::workbench::SceneState::draw_outline = false

Definition at line 178 of file workbench_private.hh.

Referenced by blender::workbench::OutlinePass::init(), and init().

◆ draw_shadows

bool blender::workbench::SceneState::draw_shadows = false

◆ lighting_type

eLightingType blender::workbench::SceneState::lighting_type = eLightingType::STUDIO

◆ material_attribute_color

Material blender::workbench::SceneState::material_attribute_color = Material(float3(-1.0f))

Definition at line 196 of file workbench_private.hh.

◆ material_override

Material blender::workbench::SceneState::material_override = Material(float3(1.0f))

Definition at line 194 of file workbench_private.hh.

Referenced by init().

◆ object_mode

eContextObjectMode blender::workbench::SceneState::object_mode = CTX_MODE_OBJECT

Definition at line 164 of file workbench_private.hh.

Referenced by init(), and blender::workbench::ObjectState::ObjectState().

◆ render_finished

bool blender::workbench::SceneState::render_finished = false

Definition at line 189 of file workbench_private.hh.

Referenced by init().

◆ reset_taa_next_sample

bool blender::workbench::SceneState::reset_taa_next_sample = false

Definition at line 188 of file workbench_private.hh.

Referenced by init().

◆ resolution

◆ sample

◆ samples_len

◆ scene

◆ shading

◆ shadows_use_rt

bool blender::workbench::SceneState::shadows_use_rt = false

Definition at line 184 of file workbench_private.hh.

Referenced by init(), and blender::workbench::ShadowPass::init().

◆ show_paint_bvh_debug

bool blender::workbench::SceneState::show_paint_bvh_debug = false

Definition at line 198 of file workbench_private.hh.

Referenced by init().

◆ updated

bool blender::workbench::SceneState::updated = false

Definition at line 191 of file workbench_private.hh.

Referenced by init(), and blender::workbench::ShadowPass::init().

◆ view_forward

float3 blender::workbench::SceneState::view_forward {0}

◆ view_projection_matrix

float4x4 blender::workbench::SceneState::view_projection_matrix = float4x4::identity()

Definition at line 160 of file workbench_private.hh.

Referenced by init().

◆ xray_mode

bool blender::workbench::SceneState::xray_mode = false

Definition at line 168 of file workbench_private.hh.

Referenced by blender::workbench::SceneResources::init(), and init().


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