summaryrefslogtreecommitdiff
path: root/src/nodedef.h
diff options
context:
space:
mode:
authorVitaliy <silverunicorn2011@yandex.ru>2017-10-15 10:34:14 +0300
committerLoïc Blot <nerzhul@users.noreply.github.com>2017-10-15 09:34:14 +0200
commit75320e7e88ab5088a46c9e42c1e789cbdacb13b0 (patch)
treeda71a3134f8b42bdabf25ef1df14c5e1a77a439e /src/nodedef.h
parent6bab695479d42ac2b051b8a35639c32b22efbf8d (diff)
downloadminetest-75320e7e88ab5088a46c9e42c1e789cbdacb13b0.tar.gz
minetest-75320e7e88ab5088a46c9e42c1e789cbdacb13b0.tar.bz2
minetest-75320e7e88ab5088a46c9e42c1e789cbdacb13b0.zip
Real global textures (#6105)
* Real global textures * Add world-aligned textures * Update minimal to support world-aligned tiles * Update minimal
Diffstat (limited to 'src/nodedef.h')
-rw-r--r--src/nodedef.h27
1 files changed, 24 insertions, 3 deletions
diff --git a/src/nodedef.h b/src/nodedef.h
index 23100a2ed..790c7fd28 100644
--- a/src/nodedef.h
+++ b/src/nodedef.h
@@ -125,9 +125,25 @@ enum LeavesStyle {
LEAVES_OPAQUE,
};
+enum AutoScale : u8 {
+ AUTOSCALE_DISABLE,
+ AUTOSCALE_ENABLE,
+ AUTOSCALE_FORCE,
+};
+
+enum WorldAlignMode : u8 {
+ WORLDALIGN_DISABLE,
+ WORLDALIGN_ENABLE,
+ WORLDALIGN_FORCE,
+ WORLDALIGN_FORCE_NODEBOX,
+};
+
class TextureSettings {
public:
LeavesStyle leaves_style;
+ WorldAlignMode world_aligned_mode;
+ AutoScale autoscale_mode;
+ int node_texture_size;
bool opaque_water;
bool connected_glass;
bool use_normal_texture;
@@ -198,6 +214,12 @@ enum PlantlikeStyle {
PLANT_STYLE_HASH2,
};
+enum AlignStyle : u8 {
+ ALIGN_STYLE_NODE,
+ ALIGN_STYLE_WORLD,
+ ALIGN_STYLE_USER_DEFINED,
+};
+
/*
Stand-alone definition of a TileSpec (basically a server-side TileSpec)
*/
@@ -212,6 +234,8 @@ struct TileDef
bool has_color = false;
//! The color of the tile.
video::SColor color = video::SColor(0xFFFFFFFF);
+ AlignStyle align_style = ALIGN_STYLE_NODE;
+ u8 scale = 0;
struct TileAnimationParams animation;
@@ -401,9 +425,6 @@ struct ContentFeatures
}
#ifndef SERVER
- void fillTileAttribs(ITextureSource *tsrc, TileLayer *tile, TileDef *tiledef,
- u32 shader_id, bool use_normal_texture, bool backface_culling,
- u8 material_type);
void updateTextures(ITextureSource *tsrc, IShaderSource *shdsrc,
scene::IMeshManipulator *meshmanip, Client *client, const TextureSettings &tsettings);
#endif