Overte C++ Documentation
NormalMapAttenuationStage.h
1 //
2 // NormalMapAttenuationStage.h
3 //
4 // Created by HifiExperiments on 7/3/25
5 // Copyright 2025 Overte e.V.
6 //
7 // Distributed under the Apache License, Version 2.0.
8 // See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
9 //
10 
11 #ifndef hifi_render_utils_NormalMapAttenuationStage_h
12 #define hifi_render_utils_NormalMapAttenuationStage_h
13 
14 #include <graphics/NormalMapAttenuation.h>
15 #include <render/Engine.h>
16 #include <render/Stage.h>
17 #include <render/StageSetup.h>
18 
19 #include "LightingModel.h"
20 
21 // NormalMapAttenuation stage to set up normal-map-attenuation-related rendering tasks
22 class NormalMapAttenuationStage : public render::PointerStage<graphics::NormalMapAttenuation, graphics::NormalMapAttenuationPointer> {};
23 using NormalMapAttenuationStagePointer = std::shared_ptr<NormalMapAttenuationStage>;
24 
25 class NormalMapAttenuationStageSetup : public render::StageSetup<NormalMapAttenuationStage> {
26 public:
27  using JobModel = render::Job::Model<NormalMapAttenuationStageSetup>;
28 };
29 
30 class SetNormalMapAttenuation {
31 public:
32  // Inputs: lightingModel, normalMapAttenuationFrame
33  using Inputs = render::VaryingSet2<LightingModelPointer, NormalMapAttenuationStage::FramePointer>;
34  using JobModel = render::Job::ModelI<SetNormalMapAttenuation, Inputs>;
35 
36  void run(const render::RenderContextPointer& renderContext, const Inputs& input);
37 };
38 
39 #endif