rant about simplex noise, incompetence and stuff.

2111111111111111221111111 … 1111122111111


That’s the output of the simplex noise I’m using… what does this mean? How does it work? Don’t ask me, I’m just as baffled. My scene generates with three block types visible (at least, since I use stone as the fallback material for non-grass/air blocks), the blocks I see in my scene are:
id 1: air
id 2: grass
id 3+: stone.
How is this when the simplex only generates values of 1 and 2? I take a plain integer as block id, that should reasonably cause it to only generate grass and air, given that this only contains id 1 and 2.
simplex is weird.

What happens if I clamp it to 1-32?

1614121110910101091011 … 51413121214

The chunk generated however does not have any similarity to the screenshot at all, reasonably one would expect more than an empty shell, no?


this thing is hollow btw, in case you’re wondering.

How am I printing these numbers?
std::ofstream f;
f.open(“Chunk_plaintext.txt”, std::ios::out | std::ios::ate | std::ios::app);

are they floating point? sure, we could print them as float but my blocks have index values and I have no useful way to cast them to int that doesn’t have data loss, this would be an issue with 2D simplex as well though, given that you have to put a roundoff point somewhere to get a sample at every pixel and a pixel can’t have a floating point value,
what happens if we multiply the float by 100, divide that result by 2 and then cast to int?
I don’t know, let’s try.

2 1.83933 1.73532 1.66185 1.60199 1.56883 1.59679 1.64369 1.59767 1.53981 1.5873 1.64683 1.67224 1.74292 1.79105 1.80853 2.19107 2.05502 1.92196 1.82605 1.7717 1.72561 … 1.80914 1.76124 1.75255 1.84197

This is the raw noise, added some space padding code, still don’t see how this (when implicitly cast to int, which truncates it) would generate three different blocks when it would only truncate to 1’s and 2’s, that only covers 2 block id’s.
I am confused, I don’t understand why this black magic doesn’t work as expected and I don’t even know where to begin looking.
I’d wager I’m just incompetent, maybe I should just quit; given that I can’t even get simplex noise to work right.

All examples truncated for brevity, I’d wager no one wants to read 2 lists of 4096 integers and one list of 4096 floating point values.


Write your text word response things here and I might read them when I get around to it.

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s