@libraz/libcantus - v0.9.3
    Preparing search index...

    Type Alias RhythmOptions

    Options controlling generateRhythm.

    type RhythmOptions = {
        seed?: number;
        bars?: number;
        subdivision?: number;
        density?: number;
    }
    Index
    seed?: number

    Seed for the deterministic PRNG.

    0
    
    bars?: number

    Number of bars to generate.

    1
    
    subdivision?: number

    Grid resolution as the number of equal grid steps per quarter-note beat. The default of 2 yields an eighth-note grid; 4 yields a sixteenth-note grid, 3 an eighth-note triplet grid, and so on.

    2
    
    density?: number

    Overall onset density in [0, 1]. Scales the per-slot onset probability, so higher values fill more grid slots. Values outside [0, 1] are clamped into range.

    0.5