Page 1 of 1
Height map problem
Posted: 15 Jun 2007, 19:03
by crimson12
My maps always seem to have very very altitudes. Nomatter how I make my height map, it always ends up having a very simlar low and high point. I use about 100 as my low and 400 as my high, any advice?
Posted: 15 Jun 2007, 19:06
by Neddie
Hurm... well, can you put up an image of your heightmap?
Posted: 15 Jun 2007, 19:25
by crimson12
I also get these very wierd contour lines.
Posted: 15 Jun 2007, 19:31
by Neddie
The contour lines may result from Compression, though I'm not an expert.
Mainly I believe you're letting the gradients darken too fast - Nearly all of that map is in the darker range - I mean, 75% of is virtually black. If you're gradually moving from the black at the rate your height map shows I expect you won't see real difference save for in about a quarter sized area at the very middle.
Try 40 to 380, and possibly make some sectors of the height map lighter. As for the contours, I believe blurring might help there, but at the cost of appearance.
Posted: 15 Jun 2007, 19:44
by crimson12
i used about a 3 pixel gausian blur and still the lines appear, i'll try to brighten the heightmap and see what heppens.
Posted: 15 Jun 2007, 21:58
by AF
a 0.8MB grayscale png at 600x600? whats the world coming too.
Posted: 15 Jun 2007, 22:05
by hunterw
make your sun position higher in the sky, this will help your problem
just take the sun position out of tangerine or tropical
Posted: 16 Jun 2007, 00:25
by Neddie
I'm not sure the Sun Position has any bearing on the height of the terrain, unless, of course, you're referring to the contour issues.
Posted: 16 Jun 2007, 00:28
by muzzybear
Changing sun position is an ugly fix, it doesn't solve the problem. The issue is that the heightmap is actually 16bit and the bmp is only 8bit, so every step is 256 units worth in height. It could be smoother, and there's a parameter to mapconv to run low-pass filter on the data to blur it a little...
My solution is to use imagemagick and a simple filter to add some noise and blur. Here's a snippet from my Makefile:
HMAPFILTER=( -size $(HEIGHTMAPW)x$(HEIGHTMAPH) xc:gray +noise poisson -blur 0x2 -blur 0x7 ) +swap -compose overlay -composite -blur 0x1
"$(WORKDIR)\$(HEIGHTMAP).raw": "$(WORKDIR)\$(HEIGHTMAP)"
$(CONVERT) "$(WORKDIR)\$(HEIGHTMAP)" -depth 16 $(HMAPFILTER) -endian LSB gray:"$(WORKDIR)\$(HEIGHTMAP).raw"
I suppose I should release the whole thing so you can take a look at it... And I just did. It's probably not too useful for you, but someone might find inspiration from it.
There's sources and an nmake Makefile for building my map "Dready Lakes", but I can't post the damn URL due to forum restrictions. Go figure.
[mod edit] URL =
http://spring.unknown-files.net/file/30 ... ady_Lakes/
Posted: 20 Jun 2007, 06:07
by crimson12
It just seems no matter how different I make the heights in the height map, there is little to no difference in Height. The previews I get in L3DT are far from what i get in the end. I'm almost positive I am compiling it right too.
Posted: 20 Jun 2007, 06:25
by hunterw
just use smfed
Posted: 20 Jun 2007, 07:09
by LOrDo
Post the line of code your using to compile your map?
Posted: 20 Jun 2007, 16:06
by crimson12
mapconv -c 0.5 -x 600 -n 350 -o High_and_Low.smf -t texture.bmp -m metal.bmp -a height.bmp -i
Posted: 20 Jun 2007, 17:09
by Neddie
Hurm... something doesn't look right there. I can't put my finger on it, I've been awake for a long time, but... are x and n transposed?
Posted: 20 Jun 2007, 23:04
by crimson12
I used smfed and everything is fine, but there are these very annoying contour lines. It makes the map look very ugly, how can i smooth these out(i already tried a 6 pixel gasusien blur.)
Posted: 21 Jun 2007, 12:40
by aGorm
screen grab perhaps?
:::EDIT:: by the way... -i? isn't it -l for low pass?
aGorm
Posted: 21 Jun 2007, 14:37
by Weaver
I think -i is for invert, depending on how your heightmap is saved it may need to be flipped.
Posted: 21 Jun 2007, 22:05
by LOrDo
Yah, I is for invert. Try using -l (lowpass) to filter out those contour lines your getting.