msvc build fix
This commit is contained in:
parent
1627e21c1d
commit
b3a1cad0e1
@ -93,7 +93,7 @@ assetload::postfunc assetload::atlas(
|
||||
) {
|
||||
AtlasBuilder builder;
|
||||
for (const auto& file : paths->listdir(directory)) {
|
||||
if (!imageio::is_read_supported(file.extension()))
|
||||
if (!imageio::is_read_supported(file.extension().u8string()))
|
||||
continue;
|
||||
if (!append_atlas(builder, file))
|
||||
continue;
|
||||
@ -289,7 +289,7 @@ static bool animation(
|
||||
read_anim_file(animFile, frameList);
|
||||
}
|
||||
for (const auto& file : paths->listdir(animsDir + "/" + name)) {
|
||||
if (!frameList.empty() && !contains(frameList, file.stem())) {
|
||||
if (!frameList.empty() && !contains(frameList, file.stem().u8string())) {
|
||||
continue;
|
||||
}
|
||||
if (!append_atlas(builder, file))
|
||||
|
||||
@ -84,7 +84,7 @@ void LevelScreen::saveWorldPreview() {
|
||||
worldRenderer->draw(ctx, &camera, false, postProcessing.get());
|
||||
auto image = postProcessing->toImage();
|
||||
image->flipY();
|
||||
imageio::write(paths->resolve("world:preview.png"), image.get());
|
||||
imageio::write(paths->resolve("world:preview.png").u8string(), image.get());
|
||||
} catch (const std::exception& err) {
|
||||
logger.error() << err.what();
|
||||
}
|
||||
|
||||
@ -3,6 +3,8 @@
|
||||
#include "../../core/DrawContext.hpp"
|
||||
#include "../../core/Batch2D.hpp"
|
||||
|
||||
#include <algorithm>
|
||||
|
||||
using namespace gui;
|
||||
|
||||
Container::Container(glm::vec2 size) : UINode(size) {
|
||||
|
||||
@ -1,5 +1,7 @@
|
||||
#include "Panel.hpp"
|
||||
|
||||
#include <algorithm>
|
||||
|
||||
using namespace gui;
|
||||
|
||||
Panel::Panel(glm::vec2 size, glm::vec4 padding, float interval)
|
||||
|
||||
@ -53,8 +53,8 @@ Level::~Level(){
|
||||
void Level::loadMatrix(int32_t x, int32_t z, uint32_t radius) {
|
||||
chunks->setCenter(x, z);
|
||||
uint32_t diameter = std::min(
|
||||
radius*2L,
|
||||
(settings.chunks.loadDistance.get() + settings.chunks.padding.get()) * 2
|
||||
radius*2LL,
|
||||
(settings.chunks.loadDistance.get() + settings.chunks.padding.get()) * 2LL
|
||||
);
|
||||
if (chunks->w != diameter) {
|
||||
chunks->resize(diameter, diameter);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user