diff options
author | Weblate <42@minetest.ru> | 2013-05-01 15:33:15 +0200 |
---|---|---|
committer | Weblate <42@minetest.ru> | 2013-05-01 15:33:15 +0200 |
commit | 97cddd1b960e3b60ce74ff9ad16307b39676144e (patch) | |
tree | 0547ab284acc0fdf8aad2a36643be6f78f786ef1 /src/tile.h | |
parent | f1f2004cb9efb026625b192b404064c26ceb6d5f (diff) | |
parent | 898a4e441fc0245aaf4821ff5e3dad0daccda3b5 (diff) | |
download | minetest-97cddd1b960e3b60ce74ff9ad16307b39676144e.tar.gz minetest-97cddd1b960e3b60ce74ff9ad16307b39676144e.tar.bz2 minetest-97cddd1b960e3b60ce74ff9ad16307b39676144e.zip |
Merge remote-tracking branch 'origin/master'
Diffstat (limited to 'src/tile.h')
-rw-r--r-- | src/tile.h | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/tile.h b/src/tile.h index c5c7f9303..ea5c4be54 100644 --- a/src/tile.h +++ b/src/tile.h @@ -162,6 +162,7 @@ IWritableTextureSource* createTextureSource(IrrlichtDevice *device); enum MaterialType{ TILE_MATERIAL_BASIC, + TILE_MATERIAL_ALPHA, TILE_MATERIAL_LIQUID_TRANSPARENT, TILE_MATERIAL_LIQUID_OPAQUE, }; @@ -222,6 +223,9 @@ struct TileSpec case TILE_MATERIAL_BASIC: material.MaterialType = video::EMT_TRANSPARENT_ALPHA_CHANNEL_REF; break; + case TILE_MATERIAL_ALPHA: + material.MaterialType = video::EMT_TRANSPARENT_ALPHA_CHANNEL; + break; case TILE_MATERIAL_LIQUID_TRANSPARENT: material.MaterialType = video::EMT_TRANSPARENT_VERTEX_ALPHA; break; @@ -233,12 +237,16 @@ struct TileSpec } void applyMaterialOptionsWithShaders(video::SMaterial &material, const video::E_MATERIAL_TYPE &basic, - const video::E_MATERIAL_TYPE &liquid) const + const video::E_MATERIAL_TYPE &liquid, + const video::E_MATERIAL_TYPE &alpha) const { switch(material_type){ case TILE_MATERIAL_BASIC: material.MaterialType = basic; break; + case TILE_MATERIAL_ALPHA: + material.MaterialType = alpha; + break; case TILE_MATERIAL_LIQUID_TRANSPARENT: material.MaterialType = liquid; break; |