|
|
Ahh, here I go again. :-)
I've been working on a macro to create a landscape from an array, with several
different realisatoin types..
This landscape is a two parted thing in a rather high resolution for the array.
200x200 poitns for the land, and 300x300 for the sea. The land is parsed with a
few macros to create heights, and shallows on different points, with a equation
to change theese.
Let me describe it.
First, initzialise the array for the ground. create another, exact duplicate of
this.
in the copy, select a point and "raise" this using the length from this point to
the others, together with a function to "smooth" or in other ways change it.
Then, change the layout so all points are >0. find the highest point, and scale
everything down to the range 0..1 . This will make sure that the diffrerent
functions all have a equal effect on the landscape. After this, add to the big
landscape array.
Doing this with some points, will make the global landscape have several effects
applied to them. Then, I scale all points down to the range 0..1, and create a
output from this. The output is in the scale 0..1 in x,y and z, just like a
heightfield.
I'm still working on this, but may clean it up for a release someday. Currently
I haven't worked on the smooth_triangle output yet.
the sea is a specific hack, not using the same function as the land, but I will
change this so it has the same possibilities.
This method is rather flexible in the resolution, since all coordinates are
applyable to a "virtual" grid, and therefore I can increase the scale of the
arrays, thus getting a higher resolution(more triangles, or whatever).
statistics:
Sea array: 300x300. 177 608 triangles in a mesh. This is totally unecessary.
World array: 200x200, 40000 boxes.
Well, this takes the checker plane into 3D... :-)
as you see, the sea mesh is not necessary, but this was a test render...
And more, I can optimize the other out-puts as well, but I don't really have the
time now. Just giving a slight taste of what I'm working on.
--
//Spider
[ spi### [at] bahnhofse ]-[ http://www.bahnhof.se/~spider/ ]
What I can do and what I could do, I just don't know anymore
"Marian"
By: "Sisters Of Mercy"
Post a reply to this message
|
|