3d model to greyscale heightmap

3d model to greyscale heightmap

Discuss maps & map creation - from concept to execution to the ever elusive release.

Moderator: Moderators

Post Reply
User avatar
knorke
Posts: 7971
Joined: 22 Feb 2006, 01:02

3d model to greyscale heightmap

Post by knorke »

Anyone ever tried that?
My idea was to model the terrain in wings3D and then create the heightmap from that.

There is a "depth" shader in wings3d, so that faces further away from the camera are black and near faces are white. But there is no way to controll the "range" of that so it is very hard to get a real greyscale heightmap with it, either everything is all white or all black. Tried playing with height differences, camera distance and all that but did not manage a good result.

Is there a way to it with free software only?
Only find some forum posts about doing it in 3d max and they are mostly fail ie
http://forums.cgsociety.org/showthread.php?t=901756
User avatar
MR.D
Posts: 1527
Joined: 06 Aug 2005, 13:15

Re: 3d model to greyscale heightmap

Post by MR.D »

I thought I remember Picasso doing a few maps like that, maybe he can help out.
User avatar
bobthedinosaur
Blood & Steel Developer
Posts: 2702
Joined: 25 Aug 2004, 13:31

Re: 3d model to greyscale heightmap

Post by bobthedinosaur »

I have in the past. I find that for the work a painter is much easier than setting up the 3d and rendering and re rendering. Also the rendering sometimes has issues if you don't remove all the shadows and other default 3d rendering settings.
User avatar
Beherith
Posts: 5145
Joined: 26 Oct 2007, 16:21

Re: 3d model to greyscale heightmap

Post by Beherith »

Xnormal, render heightmap, make the output 16 bits.
User avatar
bobthedinosaur
Blood & Steel Developer
Posts: 2702
Joined: 25 Aug 2004, 13:31

Re: 3d model to greyscale heightmap

Post by bobthedinosaur »

xnormal? this: http://www.xnormal.net/Tutorials.aspx ??

wow what an awesome tool.

great find behe


behe: do you use this for map shadows too? if so how do you do it?
User avatar
Beherith
Posts: 5145
Joined: 26 Oct 2007, 16:21

Re: 3d model to greyscale heightmap

Post by Beherith »

Xnormal rocks, its originally designed to bake very high poly models onto low poly ones, but does a wonderful ao bake as well.

To use xnormal to render a 16bit, 100% true heightmap, do the following:
Export your full rez mesh as obj, and make a flat plane object that is the same size as your map. Make sure this model is the same dimensions and is placed at the lowest point of your heightmap mesh.

Then you can easily 'bake' your high poly map mesh onto the texture of the plane you just made, at any precision you desire (make sure to use 16bit png output, 8 bits just wont cut it at this scale).

Bob: I dont use it for map shadows, I use world machine for all my map lighting needs, though a few of my more recent maps have featured map-wide ambient occlusion faked through the use of Xnormal.
User avatar
rattle
Damned Developer
Posts: 8278
Joined: 01 Jun 2006, 13:15

Re: 3d model to greyscale heightmap

Post by rattle »

MeshMapper can bake displacement maps too
Image
User avatar
enetheru
Posts: 627
Joined: 11 Jun 2010, 07:32

Re: 3d model to greyscale heightmap

Post by enetheru »

knorke wrote:Anyone ever tried that?
My idea was to model the terrain in wings3D and then create the heightmap from that.

There is a "depth" shader in wings3d, so that faces further away from the camera are black and near faces are white. But there is no way to controll the "range" of that so it is very hard to get a real greyscale heightmap with it, either everything is all white or all black. Tried playing with height differences, camera distance and all that but did not manage a good result.

Is there a way to it with free software only?
Only find some forum posts about doing it in 3d max and they are mostly fail ie
http://forums.cgsociety.org/showthread.php?t=901756
sorry for the resurrection of an old thread, but... blender can render to 16bpp per channel tiff images at 2048x2048 easily..(for the height map) although sculpting a mesh thats 2048x2048 verts does take a chunk of ram(more than i have) and worked a lot better if you use the multirez modifyer, or even make it in parts.

for textures it can also render in segments so I tried the other day and successfully rendered a 32768x32768 dimensioned image in 1024x1024 segments and stitched it together with imagemagick on a core i5 with 4 gig of ram. :wink:
Pika
Posts: 9
Joined: 31 May 2012, 02:50

Re: 3d model to greyscale heightmap

Post by Pika »

I prefer mudbox for very fast making of grayscale hightmap, it is also nice option to use worldmachine for some predefined surface efects like erosion and more...

Got no problem with 10k*10k map... but this is my question...
I know that I can use only 32 and its <do not know the english word> 128/256/512/1024 etc. but what is the higer resolution that I can use with spring??
User avatar
Beherith
Posts: 5145
Joined: 26 Oct 2007, 16:21

Re: 3d model to greyscale heightmap

Post by Beherith »

Maps that are 32*32 are the practical limit (which means a heightmap of 2049*2049 and textures of 16ki*16Ki), anything larger will probably not play too well. The engine limit is higher than that, but you will start running into issues.

Enetheru: World machine does tiled renders too :D
Pika
Posts: 9
Joined: 31 May 2012, 02:50

Re: 3d model to greyscale heightmap

Post by Pika »

thx for reply, that means that the max resolution is 2k? I don't get a point... is the 3d heightmap res and from it i can generate 16k grayscal hightmap to cover all noise and efect(cover as mutch poly as possible)?



At world machine it's render take a lot more time then do it in mudbox... but it can make an "mozaic" (cut to quaters) texture (I think that only pro version can handle it)

Sorry 4 my english...
User avatar
enetheru
Posts: 627
Joined: 11 Jun 2010, 07:32

Re: 3d model to greyscale heightmap

Post by enetheru »

Beherith wrote:Enetheru: World machine does tiled renders too :D
Haha yeah I stick to floss exclusively. I bet there are tons of proprietary specialist solutions that make incredible tools for the job, I just won't pirate them and I prefer to spend my money on booze yeah!
Post Reply

Return to “Map Creation”