/
redgpu
/
ezEngine
Обзор
Документация
Войти
/
redgpu
/
ezEngine
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
dev
Code/Engine/RendererCore/Lights/SkyLightComponent.h
88 строк
3 KB
C-Core
Added specular intensity value to skylight component (#1701)
28 окт 2025, 17:47
Не верифицирован
28 окт 2025, 17:47
2ec6dd8
Код
Авторство
О чём код?
#pragma once #include <Core/World/SettingsComponent.h> #include <Core/World/SettingsComponentManager.h> #include <RendererCore/Lights/Implementation/ReflectionProbeData.h> #include <RendererCore/Textures/TextureCubeResource.h> struct ezMsgUpdateLocalBounds; struct ezMsgExtractRenderData; struct ezMsgTransformChanged; using ezSkyLightComponentManager = ezSettingsComponentManager<class ezSkyLightComponent>; class EZ_RENDERERCORE_DLL ezSkyLightComponent : public ezSettingsComponent { EZ_DECLARE_COMPONENT_TYPE(ezSkyLightComponent, ezSettingsComponent, ezSkyLightComponentManager); ////////////////////////////////////////////////////////////////////////// // ezComponent public: virtual void SerializeComponent(ezWorldWriter& inout_stream) const override; virtual void DeserializeComponent(ezWorldReader& inout_stream) override; protected: virtual void OnActivated() override; virtual void OnDeactivated() override; ////////////////////////////////////////////////////////////////////////// // ezSkyLightComponent public: ezSkyLightComponent(); ~ezSkyLightComponent(); void SetReflectionProbeMode(ezEnum<ezReflectionProbeMode> mode); // [ property ] ezEnum<ezReflectionProbeMode> GetReflectionProbeMode() const; // [ property ] void SetDiffuseIntensity(float fIntensity); // [ property ] float GetDiffuseIntensity() const; // [ property ] void SetDiffuseSaturation(float fSaturation); // [ property ] float GetDiffuseSaturation() const; // [ property ] void SetSpecularIntensity(float fIntensity); // [ property ] float GetSpecularIntensity() const; // [ property ] const ezTagSet& GetIncludeTags() const; // [ property ] void InsertIncludeTag(const char* szTag); // [ property ] void RemoveIncludeTag(const char* szTag); // [ property ] const ezTagSet& GetExcludeTags() const; // [ property ] void InsertExcludeTag(const char* szTag); // [ property ] void RemoveExcludeTag(const char* szTag); // [ property ] void SetShowDebugInfo(bool bShowDebugInfo); // [ property ] bool GetShowDebugInfo() const; // [ property ] void SetShowMipMaps(bool bShowMipMaps); // [ property ] bool GetShowMipMaps() const; // [ property ] void SetCubeMapFile(ezStringView sFile); // [ property ] ezStringView GetCubeMapFile() const; // [ property ] ezTextureCubeResourceHandle GetCubeMap() const { return m_hCubeMap; } float GetNearPlane() const { return m_Desc.m_fNearPlane; } // [ property ] void SetNearPlane(float fNearPlane); // [ property ] float GetFarPlane() const { return m_Desc.m_fFarPlane; } // [ property ] void SetFarPlane(float fFarPlane); // [ property ] protected: void OnUpdateLocalBounds(ezMsgUpdateLocalBounds& msg); void OnMsgExtractRenderData(ezMsgExtractRenderData& msg) const; void OnTransformChanged(ezMsgTransformChanged& msg); ezReflectionProbeDesc m_Desc; ezTextureCubeResourceHandle m_hCubeMap; ezReflectionProbeId m_Id; mutable bool m_bStatesDirty = true; };