Overte C++ Documentation
AssembleLightingStageTask.h
1 //
2 // Created by Samuel Gateau on 2018/12/06
3 // Copyright 2013-2018 High Fidelity, Inc.
4 //
5 // Distributed under the Apache License, Version 2.0.
6 // See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
7 //
8 
9 #ifndef hifi_AssembleLightingStageTask_h
10 #define hifi_AssembleLightingStageTask_h
11 
12 #include <render/RenderFetchCullSortTask.h>
13 #include "LightingModel.h"
14 
15 #include "LightStage.h"
16 #include "BackgroundStage.h"
17 #include "HazeStage.h"
18 #include "BloomStage.h"
19 #include "TonemappingStage.h"
20 #include "AmbientOcclusionStage.h"
21 #include "NormalMapAttenuationStage.h"
22 
23 #include "ZoneRenderer.h"
24 
25 
26 class FetchCurrentFrames {
27 public:
28  using Output = render::VaryingSet7<LightStage::FramePointer, BackgroundStage::FramePointer, HazeStage::FramePointer,
29  BloomStage::FramePointer, TonemappingStage::FramePointer, AmbientOcclusionStage::FramePointer, NormalMapAttenuationStage::FramePointer>;
30  using JobModel = render::Job::ModelO<FetchCurrentFrames, Output>;
31 
32  FetchCurrentFrames() {}
33 
34  void run(const render::RenderContextPointer& renderContext, Output& output);
35 };
36 
37 class AssembleLightingStageTask {
38 public:
39  using Input = RenderFetchCullSortTask::Output;
40  using Output = render::VaryingSet2<FetchCurrentFrames::Output, ZoneRendererTask::Output>;
41  using JobModel = render::Task::ModelIO<AssembleLightingStageTask, Input, Output, render::Task::Config>;
42 
43  AssembleLightingStageTask() {}
44 
45  void build(JobModel& task, const render::Varying& input, render::Varying& output);
46 };
47 
48 #endif