Fixed a bug in the terrain mesh generation.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@1408 dfc29bdd-3216-0410-991c-e03cc46cb475master
parent
3807fcf362
commit
a0709c155f
|
@ -31,9 +31,6 @@ namespace scene
|
|||
{
|
||||
public:
|
||||
|
||||
//! Destructor
|
||||
virtual ~IMeshManipulator() {}
|
||||
|
||||
//! Flips the direction of surfaces.
|
||||
/** Changes backfacing triangles to frontfacing
|
||||
triangles and vice versa.
|
||||
|
@ -63,13 +60,13 @@ namespace scene
|
|||
virtual void recalculateNormals(IMeshBuffer* buffer, bool smooth = false, bool angleWeighted = false) const = 0;
|
||||
|
||||
//! Scales the whole mesh.
|
||||
/** \param mesh: Mesh on which the operation is performed.
|
||||
\param scale: Scale factor. */
|
||||
/** \param mesh Mesh on which the operation is performed.
|
||||
\param scale Scale factor. */
|
||||
virtual void scaleMesh(IMesh* mesh, const core::vector3df& scale) const = 0;
|
||||
|
||||
//! Applies a transformation
|
||||
/** \param mesh: Mesh on which the operation is performed.
|
||||
\param m: transformation matrix. */
|
||||
/** \param mesh Mesh on which the operation is performed.
|
||||
\param m transformation matrix. */
|
||||
virtual void transformMesh(IMesh* mesh, const core::matrix4& m) const = 0;
|
||||
|
||||
//! Clones a static IMesh into a modifiable SMesh.
|
||||
|
|
|
@ -880,7 +880,7 @@ namespace scene
|
|||
of triangles created depends on the size of this texture, so use a small
|
||||
heightmap to increase rendering speed.
|
||||
\param stretchSize: Parameter defining how big a is pixel on the heightmap.
|
||||
\param maxHeight: Defines how height a white pixel on the heighmap is.
|
||||
\param maxHeight: Defines how high a white pixel on the heighmap is.
|
||||
\param defaultVertexBlockSize: Defines the initial dimension between vertices.
|
||||
\return Returns null if the creation failed. The reason could be that you
|
||||
specified some invalid parameters, that a mesh with that name already
|
||||
|
|
|
@ -178,9 +178,9 @@ IMesh* CGeometryCreator::createTerrainMesh(video::IImage* texture,
|
|||
|
||||
buffer->Indices.reallocate((blockSize.Height-1)*(blockSize.Width-1)*6);
|
||||
// add indices of vertex block
|
||||
s32 c1 = 0;
|
||||
for (y=0; y<blockSize.Height-1; ++y)
|
||||
{
|
||||
s32 c1 = 0;
|
||||
for (s32 x=0; x<blockSize.Width-1; ++x)
|
||||
{
|
||||
const s32 c = c1 + x;
|
||||
|
|
|
@ -58,7 +58,7 @@ endif
|
|||
ifdef PROFILE
|
||||
CXXFLAGS += -pg
|
||||
endif
|
||||
CFLAGS := -fexpensive-optimizations -O3 -DPNG_NO_MMX_CODE -DPNG_NO_MNG_FEATURES
|
||||
CFLAGS := -fexpensive-optimizations -O3 -DPNG_THREAD_UNSAFE_OK -DPNG_NO_MMX_CODE -DPNG_NO_MNG_FEATURES
|
||||
|
||||
sharedlib sharedlib_win32 : CXXFLAGS += -fpic
|
||||
sharedlib sharedlib_win32 : CFLAGS += -fpic
|
||||
|
|
Loading…
Reference in New Issue