• Welcome to World Machine Community. Please login or sign up.
July 22, 2019, 03:44:20 am


Read the Development Diary for an inside look at World Machine's progress!

.r16 file output - Use of all 256 level?

Started by WiZaxx, August 23, 2007, 03:29:20 pm

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.


Surely hope this is not too silly...

I would like to force WM to output the r16 highmap using all 256 shades of grays.

Is it possible?



I'm not sure if I follow?

The .r16 format is a 16bit RAW format, in which each height value contains a value between 0 and 65535 denoting the elevation.

If you want a 256-shade file, use the basic 8-bit RAW option.
-- Stephen Schmitt
- Creator of World Machine


August 23, 2007, 04:08:06 pm #2 Last Edit: August 23, 2007, 04:11:27 pm by WiZaxx
OK then.

I'm converting to 256 levels eh?!

My only allowed input is r16 RAW, though.
So Is there a trick to force the terrain to the full spectrum in WM? What I need is actually a relative elevation rather than an absolute one; hoping that this will translate in having 256 levels after converting.

I must sound like a mad scientist here...


If you want to make sure that the terrain spans the entire range on export, insert a Clamp device between your terrain and the file output node. Check the "Normalize" box in the Clamp, then export. It should now span the entire range of terrain heights.
-- Stephen Schmitt
- Creator of World Machine



Am I getting it right, if i don't use the normalize option, it doesn't use the whole 65535 scale ?


_Potentially_, yes.

When you setup your height range in WM, a value of 0 in a 16bit raw will correspond to elevation 0m, and a value of 65535 will correspond to, say, 3000m.

For example, If your terrain's lowest point is only 500m, then the smallest value in the raw output will be 500m/3000m * 65535 = 10922.

This is by design; however, if you don't have to try to match heightfields or anything else similar, you can normalize the terrain which will ensure that the HF spans the entire 0..65535 range.
-- Stephen Schmitt
- Creator of World Machine

Quick Reply

With Quick-Reply you can write a post when viewing a topic without loading a new page. You can still use bulletin board code and smileys as you would in a normal post.

Warning: this topic has not been posted in for at least 120 days.
Unless you're sure you want to reply, please consider starting a new topic.

Note: this post will not display until it's been approved by a moderator.

Please leave this box empty:
Type the letters shown in the picture
Listen to the letters / Request another image

Type the letters shown in the picture:

Shortcuts: ALT+S save/post or ALT+P preview