All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
SceneModelMaterial.h
1 // Copyright eeGeo Ltd (2012-2014), All Rights Reserved
2 
3 #pragma once
4 
5 #include "ModelMaterial.h"
6 #include "Types.h"
7 #include "Rendering.h"
8 #include "GlobalLighting.h"
9 #include "GlobalFogging.h"
10 #include "TextureMinifyType.h"
11 #include "ModelShader.h"
12 #include "SceneModelTextureResource.h"
13 #include <string>
14 
15 namespace Eegeo
16 {
17  namespace Rendering
18  {
19  namespace Materials
20  {
22  {
23  public:
24 
25  SceneModelMaterial(const TMaterialId materialId,
26  const std::string& name,
27  Shaders::ModelShader& shader,
28  const Lighting::GlobalLighting& lighting,
29  const Lighting::GlobalFogging& fogging,
30  SceneModels::SceneModelTextureResource& sceneModelTexture,
31  Rendering::TextureMinifyType textureMinifyType,
32  bool textureRepeat);
34 
35  void SetDiffuseTexture(Rendering::AsyncTexturing::IAsyncTexture& textureId);
36  void SetStatePerRenderable(const Rendering::RenderableBase* renderableBase, Rendering::GLState& glState) const;
37 
38  Rendering::AsyncTexturing::IAsyncTexture& GetTextureId() const { return m_textureResource.GetTexture(); }
39 
40  private:
41 
42  SceneModels::SceneModelTextureResource& m_textureResource;
43  };
44  }
45  }
46 }