Add way to change from int seed to long seed
xandergos opened this issue · comments
I'm using FastNoiseLite in Java, and would like to use the same seed for both a Java Random
class instance, and for FastNoiseLite. Obviously, I can convert the long to an int, and make overflows a feature, but for the sake of consistency and variety, it would be appreciated if there was a mechanism similar to that which is used for swapping floats and doubles.
*Just realized that this has been asked before, so apologies for that.
Adding long seeds would slow down the noise generation and there is no easy
way to add it as an extra anyway. Either the code would need to be changed
to always use long seeds or a copy of most the functions would be required
to support both seed types, neither option is feasible.
My suggestion would be to fold the long seed into an int. 'long ^ (long >>
32)'
…On Mon, 19 Jul 2021, 05:33 BudgetToaster, ***@***.***> wrote:
I'm using FastNoiseLite in Java, and would like to use the same seed for
both a Java Random class instance, and for FastNoiseLite. Obviously, I
can convert the long to an int, and make overflows a feature, but for the
sake of consistency and variety, it would be appreciated if there was a
mechanism similar to that which is used for swapping floats and doubles.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#73>, or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAKJPLHRINKGJW4V47UVHVDTYOTIVANCNFSM5AS4ZKIQ>
.
Ok, I will fold it.