feat: 多光源——点光源类型(距离衰减,位置来自 Transform)
- LightComponent 加 Type(Directional/Point)+ radius;点光位置取 实体 Transform(固有组件首次实际受益) - LightData shader 契约扩为 4×vec4(color/direction/position/params, 每灯 64B,未用字段置零);UBO 688→816B - 光照循环按类型分支:方向光无衰减;点光 L 指向光源 + 平方距离衰减, 衰减半径外跳过;CSM 阴影只来自第 0 盏方向光 - main.cpp:SunTemple 场景加暖橙火坑光 + 冷蓝填充光(点光); KeyLight/FillLight 改 designated initializer
This commit is contained in:
@@ -39,7 +39,7 @@ namespace Engine {
|
||||
|
||||
class Application {
|
||||
public:
|
||||
Application(std::string title, u32 width, u32 height);
|
||||
Application(const std::string& title, u32 width, u32 height);
|
||||
virtual ~Application();
|
||||
|
||||
Application(const Application&) = delete;
|
||||
|
||||
Reference in New Issue
Block a user