Fix for the quad-structure search + make target change

1) fix the quad-structure search for large areas did not work correctly
2) changed make clean target to also clean up the cubiomes library
This commit is contained in:
Cubitect 2021-12-07 22:36:09 +01:00
parent fbeee36a9e
commit 9571e70499
2 changed files with 5 additions and 0 deletions

View File

@ -25,6 +25,7 @@ win32: {
# also compile cubiomes
QMAKE_PRE_LINK += $(MAKE) -C $$CUPATH -f $$CUPATH/makefile CFLAGS="-DSTRUCT_CONFIG_OVERRIDE=1" all
QMAKE_CLEAN += $$CUPATH/*.o $$CUPATH/libcubiomes.a
TARGET = cubiomes-viewer

View File

@ -268,11 +268,15 @@ bool applyTranspose(std::vector<uint64_t>& slist,
// does the set of candidates for this condition fit in memory?
if ((uint64_t)slist.size() * sizeof(int64_t) * w*h >= bufmax)
{
slist.clear();
return false;
}
try {
list48.resize(slist.size() * w*h);
} catch (...) {
slist.clear();
return false;
}