Skip to content

Commit cabf42a

Browse files
committed
Typos
1 parent bcd57b1 commit cabf42a

File tree

2 files changed

+9
-10
lines changed

2 files changed

+9
-10
lines changed

apps/typegpu-docs/src/content/docs/ecosystem/typegpu-noise.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -276,6 +276,7 @@ You can easily implement your own PRNG and plug it into the pipeline.
276276
import tgpu from 'typegpu';
277277
import * as d from 'typegpu/data';
278278
import { randf } from '@typegpu/noise';
279+
import * as std from 'typegpu/std';
279280

280281
const root = await tgpu.init();
281282

@@ -289,7 +290,6 @@ import {
289290
randomGeneratorSlot,
290291
type StatefulGenerator,
291292
} from '@typegpu/noise';
292-
import * as std from 'typegpu/std';
293293

294294
const LCG: StatefulGenerator = (() => {
295295
const seed = tgpu['~unstable'].privateVar(d.u32);

packages/typegpu-noise/src/index.ts

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -22,22 +22,22 @@ import {
2222
export const randf: {
2323
/**
2424
* Sets the private seed of the thread.
25-
* @param seed seed value to set. For the best results, should be in [0, 1] range.
25+
* @param seed seed value to set. For the best results, should be in [-1000, 1000] range.
2626
*/
2727
seed: typeof randSeed;
2828
/**
2929
* Sets the private seed of the thread.
30-
* @param seed seed value to set. For the best results, all elements should be in [0, 1] range.
30+
* @param seed seed value to set. For the best results, all elements should be in [-1000, 1000] range.
3131
*/
3232
seed2: typeof randSeed2;
3333
/**
3434
* Sets the private seed of the thread.
35-
* @param seed seed value to set. For the best results, all elements should be in [0, 1] range.
35+
* @param seed seed value to set. For the best results, all elements should be in [-1000, 1000] range.
3636
*/
3737
seed3: typeof randSeed3;
3838
/**
3939
* Sets the private seed of the thread.
40-
* @param seed seed value to set. For the best results, all elements should be in [0, 1] range.
40+
* @param seed seed value to set. For the best results, all elements should be in [-1000, 1000] range.
4141
*/
4242
seed4: typeof randSeed4;
4343
/**
@@ -49,18 +49,18 @@ export const randf: {
4949
*/
5050
sampleExclusive: typeof randFloat01Exclusive;
5151
/**
52-
* Returns a random f32 value basen on normal (gaussian) distribution.
52+
* Returns a random f32 value based on normal (gaussian) distribution.
5353
* @param mu mean value.
5454
* @param sigma standard deviation. Must be > 0.
5555
*/
5656
normal: typeof randNormal;
5757
/**
58-
* Returns a random f32 value basen on exponential distribution.
58+
* Returns a random f32 value based on exponential distribution.
5959
* @param rate rate parameter. Must be > 0.
6060
*/
6161
exponential: typeof randExponential;
6262
/**
63-
* Returns a random f32 value basen on cauchy distribution.
63+
* Returns a random f32 value based on cauchy distribution.
6464
* @param x0 location parameter.
6565
* @param gamma scale parameter. Must be > 0.
6666
*/
@@ -128,9 +128,8 @@ export const randf: {
128128
};
129129

130130
export {
131-
// Generators
131+
// --- Generators ---
132132
BPETER,
133-
// ---
134133
// The default (Can change between releases to improve uniformity).
135134
DefaultGenerator,
136135
// ---

0 commit comments

Comments
 (0)