#include <RenderSystem3D.h>
Public 类型 | |
| using | GBufferExtraDrawer = std::function< void(Graphics &gfx, const Camera3D::Data &cam, const glm::mat4 &viewProj, float aspect)> |
| Register a callback that fills the G-buffer (depth/normal/albedo) for geometry outside the Renderable3D ECS (e.g. sprite-stack slices). Called inside the GBuffer pass after opaque meshes, before endGBufferPass. The camera data and view-projection match the pass camera. | |
| using | ShadowExtraDrawer = std::function< void(Graphics &gfx, const glm::mat4 &lightVP, const Camera3D::Data &cam)> |
| Register a callback that casts shadows for geometry outside the Renderable3D ECS (e.g. sprite-stack slices). Invoked inside each CSM cascade pass with that cascade's light-view-projection; call gfx.drawMeshShadowAlpha(...) / drawMeshShadow(...) there. When no Light3D casts shadows but drawers are registered, the legacy directional light is used as the shadow source. | |
静态 Public 成员函数 | |
| static void | render (Graphics &gfx) |
| static void | renderToCanvas (Graphics &gfx, Canvas *target, Camera3D *camera) |
| static void | addGBufferExtraDrawer (GBufferExtraDrawer drawer) |
| static void | addShadowExtraDrawer (ShadowExtraDrawer drawer) |
| static void | setDirectionalLight (float dx, float dy, float dz, float r, float g, float b) |
| Legacy single directional light used when no enabled Light3D exists. | |
详细描述
在文件 RenderSystem3D.h 第 245 行定义.
成员类型定义说明
◆ GBufferExtraDrawer
| using eve::graphics::RenderSystem3D::GBufferExtraDrawer = std::function<void(Graphics &gfx, const Camera3D::Data &cam, const glm::mat4 &viewProj, float aspect)> |
Register a callback that fills the G-buffer (depth/normal/albedo) for geometry outside the Renderable3D ECS (e.g. sprite-stack slices). Called inside the GBuffer pass after opaque meshes, before endGBufferPass. The camera data and view-projection match the pass camera.
在文件 RenderSystem3D.h 第 262 行定义.
◆ ShadowExtraDrawer
| using eve::graphics::RenderSystem3D::ShadowExtraDrawer = std::function<void(Graphics &gfx, const glm::mat4 &lightVP, const Camera3D::Data &cam)> |
Register a callback that casts shadows for geometry outside the Renderable3D ECS (e.g. sprite-stack slices). Invoked inside each CSM cascade pass with that cascade's light-view-projection; call gfx.drawMeshShadowAlpha(...) / drawMeshShadow(...) there. When no Light3D casts shadows but drawers are registered, the legacy directional light is used as the shadow source.
在文件 RenderSystem3D.h 第 275 行定义.
成员函数说明
◆ addGBufferExtraDrawer()
|
static |
在文件 RenderSystem3D.cpp 第 405 行定义.
◆ addShadowExtraDrawer()
|
static |
在文件 RenderSystem3D.cpp 第 410 行定义.
◆ render()
|
static |
在文件 RenderSystem3D.cpp 第 544 行定义.
引用了 a, eve::graphics::ShadowUpload::active, albedo, eve::graphics::Outline::apply(), eve::graphics::AmbientOcclusion::applyFromGBuffer(), b, eve::graphics::Graphics::begin3DFrame(), eve::graphics::Graphics::beginGBufferPass(), eve::graphics::Graphics::beginShadowPass(), eve::graphics::Material::bind(), eve::graphics::Mesh::boundsCx, eve::graphics::Mesh::boundsCy, eve::graphics::Mesh::boundsCz, eve::graphics::Mesh::boundsRadius, eve::graphics::buildDirectionalCSM(), c, camIdx, eve::graphics::GBuffer::clear(), clustered, eve::graphics::Lighting3DPack::count, d, data, depth, dir, distSq, eve::graphics::Graphics::drawMeshGBuffer(), eve::graphics::Graphics::drawMeshShader(), eve::graphics::Graphics::drawMeshShadow(), eve::graphics::Light3D::Data::dx, eve::graphics::Light3D::Data::dy, eve::graphics::Light3D::Data::dz, eve::graphics::Material::effectiveShader(), eve::graphics::Graphics::endGBufferPass(), eve::graphics::Graphics::endShadowPass(), eve::graphics::RenderControl::ensureCompiled(), fovRad, eve::graphics::Material::getAlbedoTexture(), eve::graphics::Material::getCastShadow(), eve::graphics::RenderControl::getGBuffer(), eve::graphics::Graphics::getHeight(), eve::graphics::GBuffer::getHwDepthTexture(), eve::graphics::GBuffer::getNormalTexture(), eve::graphics::Graphics::getPixelHeight(), eve::graphics::Graphics::getPixelWidth(), eve::graphics::Material::getReceiveLight(), eve::graphics::Graphics::getRenderControl(), eve::graphics::Material::getTintA(), eve::graphics::Material::getTintB(), eve::graphics::Material::getTintG(), eve::graphics::Material::getTintR(), eve::graphics::Graphics::getWidth(), eve::graphics::Graphics::had3DThisFrame(), eve::graphics::Mesh::hasBounds(), eve::graphics::RenderControl::hasPass(), eve::graphics::RenderControl::isEnabled(), eve::graphics::Material::isTransparentHair(), eve::graphics::GBuffer::isValid(), eve::graphics::ShadowConfig::kCascades, eve::graphics::ClusteredLightConfig::kMaxLights, eve::graphics::Lighting3DPack::kMaxLights, model, mr, p, eve::graphics::Graphics::pipelineAmbientOcclusion(), eve::graphics::Graphics::pipelineOutline(), eve::graphics::Light3DGpu::posRadius, eve::debug::rtBind(), eve::debug::rtDraw(), eve::debug::rtPassBegin(), eve::debug::rtPassEnd(), eve::graphics::Outline::setClip(), eve::graphics::AmbientOcclusion::setIntensity(), eve::graphics::Graphics::setMesh3DCameraPos(), eve::graphics::Graphics::setMesh3DClip(), eve::graphics::Graphics::setMesh3DClusteredActive(), eve::graphics::Graphics::setMesh3DClusteredLighting(), eve::graphics::Graphics::setMesh3DEnv(), eve::graphics::Graphics::setMesh3DHeightTexture(), eve::graphics::Graphics::setMesh3DLighting(), eve::graphics::Graphics::setMesh3DMaterial(), eve::graphics::Graphics::setMesh3DNormalTexture(), eve::graphics::Graphics::setMesh3DParallax(), eve::graphics::Graphics::setMesh3DSceneDepth(), eve::graphics::Graphics::setMesh3DShadowReceive(), eve::graphics::Graphics::setMesh3DShadows(), eve::graphics::Graphics::setMesh3DTexCellBomb(), eve::graphics::Graphics::setMesh3DView(), eve::graphics::Graphics::setMesh3DViewProj(), eve::graphics::AmbientOcclusion::setPower(), eve::graphics::AmbientOcclusion::setQuality(), eve::graphics::AmbientOcclusion::setRadius(), shader, eve::graphics::Light3D::Data::shadowBias, eve::graphics::Light3D::Data::shadowStrength, eve::graphics::Graphics::supportsGBufferPost(), tb, tg, tr , 以及 view.
被这些函数引用 eve::graphics::Graphics::render3D().
◆ renderToCanvas()
|
static |
Preview-quality 3D pass into an offscreen canvas (editor viewport): forward-only (no shadow / G-buffer / AO), legacy per-entity material path, using camera. The canvas texture then holds the rendered scene.
在文件 RenderSystem3D.cpp 第 920 行定义.
引用了 eve::graphics::ClusteredLightingUpload::active, eve::graphics::ShadowUpload::active, albedo, eve::graphics::Graphics::begin3DFrameToCanvas(), eve::graphics::Graphics::drawMeshShader(), eve::graphics::Graphics::end3DFrameToCanvas(), eye, fovRad, eve::graphics::Canvas::getHeight(), eve::graphics::Canvas::getWidth(), eve::graphics::ClusteredLightConfig::kMaxLights, model, mr, eve::graphics::perspectiveVulkanRH_ZO(), eve::debug::rtDraw(), eve::graphics::Graphics::setMesh3DCameraPos(), eve::graphics::Graphics::setMesh3DClip(), eve::graphics::Graphics::setMesh3DClusteredLighting(), eve::graphics::Graphics::setMesh3DEnv(), eve::graphics::Graphics::setMesh3DHeightTexture(), eve::graphics::Graphics::setMesh3DLighting(), eve::graphics::Graphics::setMesh3DMaterial(), eve::graphics::Graphics::setMesh3DNormalTexture(), eve::graphics::Graphics::setMesh3DParallax(), eve::graphics::Graphics::setMesh3DShadowReceive(), eve::graphics::Graphics::setMesh3DShadows(), eve::graphics::Graphics::setMesh3DTexCellBomb(), eve::graphics::Graphics::setMesh3DView(), eve::graphics::Graphics::setMesh3DViewProj(), shader , 以及 view.
◆ setDirectionalLight()
|
static |
Legacy single directional light used when no enabled Light3D exists.
在文件 RenderSystem3D.cpp 第 398 行定义.
该类的文档由以下文件生成:
- src/modules/graphics/RenderSystem3D.h
- src/modules/graphics/RenderSystem3D.cpp