aboutsummaryrefslogtreecommitdiff
path: root/src/client/client.h
diff options
context:
space:
mode:
authorlhofhansl <larsh@apache.org>2023-02-08 13:42:12 -0800
committerGitHub <noreply@github.com>2023-02-08 13:42:12 -0800
commitd3a6ee00e63cc0a4adcaa7598ad5614f1e419515 (patch)
treeab82ef6f25fe7f314c0065334f7c9c4d56f65426 /src/client/client.h
parent56d2567b5dcf9556cef8352032cede48a5610801 (diff)
downloadminetest-d3a6ee00e63cc0a4adcaa7598ad5614f1e419515.tar.xz
Generalize mesh chunking, and make it configurable. (#13179)
* Generalize mesh chunking. Set 3x3x3 chunks. * Make mesh chunk size configurable... Default to 1 (off). * Extract all mesh grid maths into a dedicated class --------- Co-authored-by: x2048 <codeforsmile@gmail.com>
Diffstat (limited to 'src/client/client.h')
-rw-r--r--src/client/client.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/client/client.h b/src/client/client.h
index c05e6d325..3c7fc0db2 100644
--- a/src/client/client.h
+++ b/src/client/client.h
@@ -39,6 +39,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
#include "network/peerhandler.h"
#include "gameparams.h"
#include <fstream>
+#include "util/numeric.h"
#define CLIENT_CHAT_MESSAGE_LIMIT_PER_10S 10.0f
@@ -437,6 +438,11 @@ public:
{
return m_env.getLocalPlayer()->formspec_prepend;
}
+ inline MeshGrid getMeshGrid()
+ {
+ return m_mesh_grid;
+ }
+
private:
void loadMods();
@@ -602,4 +608,7 @@ private:
u32 m_csm_restriction_noderange = 8;
std::unique_ptr<ModChannelMgr> m_modchannel_mgr;
+
+ // The number of blocks the client will combine for mesh generation.
+ MeshGrid m_mesh_grid;
};