Created
December 12, 2019 13:04
-
-
Save JacquesLucke/a30303ce4c7d9c3242885f4da7b4412d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
uint a = BLI_rng_get_uint(rng); | |
uint b = 0x3F800000 | (0x007FFFFF & a); | |
float c = *(float *)&b; | |
return c - 1.0f; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment