Changes to VBO handeling are now in CVS

I've updated VBO handeling in jME. The process should be transparant for most people, but if any of you experience any sudden glitches please let me know.



If you use the same Buffer more than once in different pieces of Geometry (eg if you use CloneCreator) the engine now remembers what VBO was created for your Buffer and instead of making a new VBO it will use the existing one. If you want to use the same Buffer for creating multiple VBOs, then you can use a new method in Renderer: removeFromVBOCache(Buffer). You can also clear all entries with clearVBOCache().



Also, you can now delete your VBOs! Either by their id or by Buffer, see the new methods deleteVBO() in Renderer. Deleting by Buffer also means that if you can reuse that Buffer to create a new VBO.



I've updated TerrainPage and TerrainBlock to delete their VBOs if you update the terrain from the heightmap first, rather than just creating new ones. This was a potentially very "stealthy" memoryleak, because the memory for VBOs is usually allocated on the videocard, not in system memory.



Finally, you can enable VBO for indicis ("IndexBuffer"). Do not use this in combination with CLOD or anything else that dynamically generates indicis. It's off by default, even if you use "new VBOInfo(true)". You need to call setVBOIndexEnabled(true) to enable it.