Skip to content

random for Lyte #33

Description

@jersmi7

Reproduce Audulus random node behavior, then add Lyte extended functionality. Something like:

random() -> f32
seed_random(seed: u32)
random(seed: u32) -> f32

Suggested semantics:

random()              // like Audulus random node, advances this script instance’s PRNG
seed_random(seed)     // resets that stream
random(seed)          // stateless deterministic value

seed_random(seed: u32)

Allow Lyte code to reseed from patch logic: knobs, inputs, gates, sequencers, presets, or algorithmic state. Identical seeds produce identical sequences.

random(seed: u32) -> f32

As an optional third function, a stateless deterministic random/hash value: same seed in, same value out, without advancing the random() stream. Great for things like voice IDs, table variation, repeatable per-step offsets, or deterministic “randomized” constants.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions