Skip to content

Commit 1639c4b

Browse files
committed
Quat: one more use of RandomNumberEngine.nextUnsigned()
1 parent f75974d commit 1639c4b

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

  • src/main/java/com/github/stephengold/joltjni

src/main/java/com/github/stephengold/joltjni/Quat.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -294,7 +294,7 @@ public static Quat sIdentity() {
294294
public static Quat sRandom(RandomNumberEngine engine) {
295295
long em = engine.min();
296296
float er = (float) (engine.max() - em);
297-
float x0 = (engine.nextInt() - em) / er;
297+
float x0 = (engine.nextUnsigned() - em) / er;
298298
float r1 = (float) JphMath.sqrt(1f - x0);
299299
float r2 = (float) JphMath.sqrt(x0);
300300

0 commit comments

Comments
 (0)