27 lines
1.0 KiB
C++
27 lines
1.0 KiB
C++
#pragma once
|
||
|
||
#include <godot_cpp/classes/directional_light3d.hpp>
|
||
#include <godot_cpp/classes/world_environment.hpp>
|
||
|
||
#include <asset_resolver.h>
|
||
#include <environment.h>
|
||
|
||
// W5 —— .msenv(已由 formats/environment 解析)-> Godot 光照 / 天空 / 雾 / 色调。
|
||
// SHINSOO §9-W5。背景 / 角色方向光按参考端分成两个可见性层;云贴图接入
|
||
// ProceduralSkyMaterial 的 sky cover;texture-mode 下再用 Godot sky shader 叠加
|
||
// 参考端的有限云层平面与 UV 滚动。六面天空、滤色和 lens flare 仍保持显式待办,
|
||
// 不把不等价的近似标成完成。
|
||
namespace mtgodot {
|
||
|
||
struct EnvNodes {
|
||
godot::DirectionalLight3D *sun = nullptr;
|
||
godot::DirectionalLight3D *character_light = nullptr;
|
||
godot::WorldEnvironment *world_env = nullptr;
|
||
};
|
||
|
||
// 在 parent 下建 / 配 DirectionalLight3D + WorldEnvironment。已存在则复用。
|
||
EnvNodes apply_environment(const fmt::Environment &env, godot::Node *parent,
|
||
const fmt::AssetResolver *resolver = nullptr);
|
||
|
||
} // namespace mtgodot
|