diff options
-rw-r--r-- | engine/xe_image.cpp | 6 | ||||
-rw-r--r-- | res/image/blocks.png | bin | 0 -> 7481 bytes | |||
-rw-r--r-- | src/chunk.hpp | 7 |
3 files changed, 7 insertions, 6 deletions
diff --git a/engine/xe_image.cpp b/engine/xe_image.cpp index 64538ce..7be2b3b 100644 --- a/engine/xe_image.cpp +++ b/engine/xe_image.cpp @@ -223,9 +223,9 @@ void Image::createTextureSampler() { samplerInfo.sType = VK_STRUCTURE_TYPE_SAMPLER_CREATE_INFO; samplerInfo.magFilter = VK_FILTER_LINEAR; samplerInfo.minFilter = VK_FILTER_LINEAR; - samplerInfo.addressModeU = VK_SAMPLER_ADDRESS_MODE_REPEAT; - samplerInfo.addressModeV = VK_SAMPLER_ADDRESS_MODE_REPEAT; - samplerInfo.addressModeW = VK_SAMPLER_ADDRESS_MODE_REPEAT; + samplerInfo.addressModeU = VK_SAMPLER_ADDRESS_MODE_CLAMP_TO_EDGE; + samplerInfo.addressModeV = VK_SAMPLER_ADDRESS_MODE_CLAMP_TO_EDGE; + samplerInfo.addressModeW = VK_SAMPLER_ADDRESS_MODE_CLAMP_TO_EDGE; samplerInfo.anisotropyEnable = VK_TRUE; samplerInfo.maxAnisotropy = xeDevice.getAnisotropy(); samplerInfo.borderColor = VK_BORDER_COLOR_INT_OPAQUE_BLACK; diff --git a/res/image/blocks.png b/res/image/blocks.png Binary files differnew file mode 100644 index 0000000..24f734a --- /dev/null +++ b/res/image/blocks.png diff --git a/src/chunk.hpp b/src/chunk.hpp index 4c6101c..d10adc9 100644 --- a/src/chunk.hpp +++ b/src/chunk.hpp @@ -14,6 +14,7 @@ #define INVALID 0 #define AIR 1 #define DIRT 2 +#define GRASS 3 namespace app { @@ -110,12 +111,12 @@ const float nm[6][3] = { const float uv[6][2] = { + {1.f,0.f}, {1.f,1.f}, {0.f,1.f}, + {0.f,1.f}, {0.f,0.f}, - {0.f,0.f}, - {1.f,0.f}, - {1.f,1.f} + {1.f,0.f} }; }
\ No newline at end of file |