Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No 1D functions #14

Open
hamarb123 opened this issue Feb 16, 2022 · 1 comment
Open

No 1D functions #14

hamarb123 opened this issue Feb 16, 2022 · 1 comment

Comments

@hamarb123
Copy link

Hi @KdotJPG, I'm using the _old version of the C# one (but I haven't seen it in any others as well) and was looking for 1D generators.
Can it be made from using the 2D generator along one axis, or is there a proper way to do it?
Also, the reason I'm using the _old one is because it seems more optimised by caching more, is this accurate?
Thanks!

@KdotJPG
Copy link
Owner

KdotJPG commented Feb 25, 2022

You can sample the 2D generator just fine. There is a way to write 1D versions of the noise. I might consider including them when I get time. Note that 1D noise will cross zero on regular intervals, which a 1D slice of 2D noise will not as long as you don't sample along a grid line (e.g. Noise(seed, t, t)).

The _old implementations do use lookup tables, if that's what you mean. From the performance tests I ran, especially OpenSimplex2S when I originally devised the current implementation as part of my contributions to FastNoiseLite, I found the newer implementation to be faster.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants