Moved heightmap to vks namespace (Refs #260)
This commit is contained in:
parent
c1575e4fe5
commit
7f1c376550
2 changed files with 184 additions and 181 deletions
|
|
@ -14,7 +14,9 @@
|
|||
#include "VulkanDevice.hpp"
|
||||
#include "VulkanBuffer.hpp"
|
||||
|
||||
namespace vkTools
|
||||
namespace vks
|
||||
{
|
||||
namespace utils
|
||||
{
|
||||
class HeightMap
|
||||
{
|
||||
|
|
@ -252,3 +254,4 @@ namespace vkTools
|
|||
}
|
||||
};
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -197,7 +197,7 @@ public:
|
|||
vks::Texture2D source;
|
||||
} textures;
|
||||
|
||||
vkTools::HeightMap *heightMap = nullptr;
|
||||
vks::utils::HeightMap *heightMap = nullptr;
|
||||
|
||||
struct {
|
||||
VkPipelineVertexInputStateCreateInfo inputState;
|
||||
|
|
@ -660,11 +660,11 @@ public:
|
|||
// Generate a terrain quad patch for feeding to the tessellation control shader
|
||||
void generateTerrain()
|
||||
{
|
||||
heightMap = new vkTools::HeightMap(vulkanDevice, queue);
|
||||
heightMap = new vks::utils::HeightMap(vulkanDevice, queue);
|
||||
#if defined(__ANDROID__)
|
||||
heightMap->loadFromFile(getAssetPath() + "textures/terrain_heightmap_r16.ktx", 128, glm::vec3(2.0f, 48.0f, 2.0f), vkTools::HeightMap::topologyTriangles, androidApp->activity->assetManager);
|
||||
heightMap->loadFromFile(getAssetPath() + "textures/terrain_heightmap_r16.ktx", 128, glm::vec3(2.0f, 48.0f, 2.0f), vks::utils::HeightMap::topologyTriangles, androidApp->activity->assetManager);
|
||||
#else
|
||||
heightMap->loadFromFile(getAssetPath() + "textures/terrain_heightmap_r16.ktx", 128, glm::vec3(2.0f, 48.0f, 2.0f), vkTools::HeightMap::topologyTriangles);
|
||||
heightMap->loadFromFile(getAssetPath() + "textures/terrain_heightmap_r16.ktx", 128, glm::vec3(2.0f, 48.0f, 2.0f), vks::utils::HeightMap::topologyTriangles);
|
||||
#endif
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue