Overte C++ Documentation
CalculateMeshNormalsTask.h
1 //
2 // CalculateMeshNormalsTask.h
3 // model-baker/src/model-baker
4 //
5 // Created by Sabrina Shanman on 2019/01/07.
6 // Copyright 2019 High Fidelity, Inc.
7 //
8 // Distributed under the Apache License, Version 2.0.
9 // See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
10 //
11 
12 #ifndef hifi_CalculateMeshNormalsTask_h
13 #define hifi_CalculateMeshNormalsTask_h
14 
15 #include <hfm/HFM.h>
16 
17 #include "Engine.h"
18 #include "BakerTypes.h"
19 
20 // Calculate mesh normals if not already present in the mesh
21 class CalculateMeshNormalsTask {
22 public:
23  using Input = std::vector<hfm::Mesh>;
24  using Output = baker::NormalsPerMesh;
25  using JobModel = baker::Job::ModelIO<CalculateMeshNormalsTask, Input, Output>;
26 
27  void run(const baker::BakeContextPointer& context, const Input& input, Output& output);
28 };
29 
30 #endif // hifi_CalculateMeshNormalsTask_h