Problem with Terrain
BlitzMax Forums/MiniB3D Module/Problem with Terrain
| ||
I am learning to use terrain. For that I stripped the example from klepto. But I dont see any terrain. And I believe I have to see the wireframe, even if texturing fails. But I only see my created cube. Any idea where I failed? |
| ||
Ok, I found my terrain, lost in space. Setting camera range from default (1000?) to 25000 made it visible far far away. If I set ScaleTerrain to 500,1,1 the terrain appears not a 0,0,0 but at 500,1,1. Looks ScaleTerrain changes the position of the terrain. |
| ||
I'm trying to use the terrain example from Klepto as well to learn how terrain works. Stripping down klepto's example is a good way to start Also the B3D Docs are a good help : http://www.blitzmax.com/b3ddocs/command.php?name=loadterrain&ref=goto Looking at the example the height can be between 0 and 255 depending on the red channel of the picture you load and by scaling the Y value. The only thing I want to know at this moment is how to change the height value realtime for maybe a map editor lateron... I see Blitz3D has the function ModifyTerrain for that... Will look at this later when I get home. |
| ||
The implemented Version is total different in behaviour than the original in B3D. My Terrainsystem is just a try to get as max compatibility to standard B3D as possible. In B3D the terrainmesh is generated new each frame, so in fact you modify the heightdata and not the mesh directly. This is currently not possible with my Terrain, well not completely true It will be possible in the new version we're developing. Also a lot of bugs will be removed. So unfortunatly there is no way currently to modify the terrain directly. But some hints what you have to do. (Needs a deep look into the Terrain source). With some hacking you could get the correct surface of a Terranpatch you would like to modify. Within this patch you should be able to apply changes, but keep in mind that this will possibly break up the whole mesh (resulting in gaps etc). |
| ||
Cannot wait until the new version will be finished. I don't think I'll try changing the source right now... :-p But I cannot complaint because BlitzMax wasn't intended to do 3D stuff anyway in the first place. That's why they have Blitz3D. Great job on the 2.0 shaders, that really makes a big difference. |