All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
UnityRasterTerrainTextureLoader.h
1 #pragma once
2 
3 #include "UnityTextureFileLoader.h"
4 #include "UnityRasterTerrainTexture.h"
5 #include "IAsyncBufferTextureRequestor.h"
6 
7 namespace Eegeo
8 {
9  namespace Unity
10  {
12  {
13  public:
15  Unity::UnityTextureFileLoader& textureLoader) :
16  m_textureLoader(textureLoader)
17  {
18 
19  }
20 
21  Rendering::AsyncTexturing::IAsyncTexture& RequestTextureFromBuffer(
22  std::vector<Byte>& buffer,
23  const std::string& textureName,
24  const std::string& fileExtension,
25  bool generateMipMaps = true)
26  {
27  return *Eegeo_NEW(UnityRasterTerrainTexture)(buffer, textureName, m_textureLoader, generateMipMaps);
28  }
29 
30  private:
31  Unity::UnityTextureFileLoader& m_textureLoader;
32  };
33  }
34 }
35