Got a bit sidetracked - the motherboard in my dev machine decided to give up after months of threatening it, and my HD died in sympathy. :(
Well, as a start, here's a function to create a square, flat terrain mesh. :P
Unfortunately, I don't know the maths off the top of my head for creating curves - I'd have to think about that, once I've got the PC working again. TBH, I thought someone who has already done this kind of thing would have dropped in by now. Oh, well.
Sorry, you've lost me there.
What do you mean by 'vertical' and 'horizontal' curves? I was thinking you just wanted to grab a vert and pull it straight up, affecting all verts in a certain radius of it - or have I mis-understood what you want?
BTW, have you tried Wings 3D to do this? It let's you pull vertices about and affect all other verts in a certain radius, using 'magnets'.
Since I will start with a flat surface I guess that should be easy to get in place of the sphere.
Well, as a start, here's a function to create a square, flat terrain mesh. :P
Function create_mesh_terrain(size%, scale#=1.0) mesh = CreateMesh() surf = CreateSurface(mesh) For z = 0 To -size Step -1 For x = 0 To size AddVertex(surf,x,0,z) Next Next For z = 0 To size-1 n = z*(size+1) For x = 0 To size-1 AddTriangle(surf,n,n+1,n+size+1) AddTriangle(surf,n+1,n+size+2,n+size+1) n = n + 1 Next Next PositionMesh mesh,-(size/2.0),0,size/2.0 ScaleMesh mesh,scale,1,scale UpdateNormals mesh Return mesh End Function
Unfortunately, I don't know the maths off the top of my head for creating curves - I'd have to think about that, once I've got the PC working again. TBH, I thought someone who has already done this kind of thing would have dropped in by now. Oh, well.
Problaby will improve on any camera distortion too I guess?
Sorry, you've lost me there.
Next item would be to give choices as to how big I want a circle to be in diameter and then have each vertex moved an amount to form a nice curve.Either vertical or horizontal.
What do you mean by 'vertical' and 'horizontal' curves? I was thinking you just wanted to grab a vert and pull it straight up, affecting all verts in a certain radius of it - or have I mis-understood what you want?
BTW, have you tried Wings 3D to do this? It let's you pull vertices about and affect all other verts in a certain radius, using 'magnets'.