I want to change the vertex data of a terrainpage dynamically during runtime (bomb big craters in my terrain). Works fine if I use TerrainBlock where all buffering is disabled but if I use the usual TerrainBlock I cant see the crater (although the vertex data and heightmap is changed -> the TerrainBlock's getHeight() method returns the correct values).
I tried to call all the update… methods (also updateVertexBuffer) but nothing happens.
So my question: is there a way to update the vertexbuffer dynamically and what do I have to do for that
TerrainPage (as you know_ uses TerrainBlock which uses VBO, and jME only supports static VBO. Solution: disable VBO. Either by just editing TerrainBlock source, or by calling the the VBO related methods. However, for everything to work correctly you'll need to update not just the vertex data, but also the normals, and the modelbound. I believe TerrainBlock has a method for updating all these at once based on heightmap data.