diff options
author | RealBadAngel <maciej.kasatkin@o2.pl> | 2014-11-21 08:41:21 +0100 |
---|---|---|
committer | RealBadAngel <maciej.kasatkin@o2.pl> | 2014-11-23 00:51:08 +0100 |
commit | 016448331061f87a63b8f9ef33671d81e8922ad1 (patch) | |
tree | a768373184e59fe96793814a6f0a532bfb740c26 /src/mesh.h | |
parent | 21464639b3f593ddc35b0283becc0c7c9b05dcac (diff) | |
download | hax-minetest-server-016448331061f87a63b8f9ef33671d81e8922ad1.tar.gz hax-minetest-server-016448331061f87a63b8f9ef33671d81e8922ad1.zip |
Port createForsythOptimizedMesh from Irrlicht 1.8
Mesh rotation helpers.
Diffstat (limited to 'src/mesh.h')
-rw-r--r-- | src/mesh.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/mesh.h b/src/mesh.h index 29f5ec76c..761842b0d 100644 --- a/src/mesh.h +++ b/src/mesh.h @@ -65,6 +65,13 @@ void setMeshColorByNormalXYZ(scene::IMesh *mesh, void rotateMeshBy6dFacedir(scene::IMesh *mesh, int facedir); /* + Rotate the mesh around the axis and given angle in degrees. +*/ +void rotateMeshXYby (scene::IMesh *mesh, f64 degrees); +void rotateMeshXZby (scene::IMesh *mesh, f64 degrees); +void rotateMeshYZby (scene::IMesh *mesh, f64 degrees); + +/* Clone the mesh. */ scene::IMesh* cloneMesh(scene::IMesh *src_mesh); @@ -79,4 +86,11 @@ scene::IMesh* convertNodeboxNodeToMesh(ContentFeatures *f); */ void recalculateBoundingBox(scene::IMesh *src_mesh); +/* + Vertex cache optimization according to the Forsyth paper: + http://home.comcast.net/~tom_forsyth/papers/fast_vert_cache_opt.html + Ported from irrlicht 1.8 +*/ +scene::IMesh* createForsythOptimizedMesh(const scene::IMesh *mesh); + #endif |