summaryrefslogtreecommitdiff
path: root/src/generated/music_data.cc
blob: cd5c406652888794475a3ceabf23cecdc6eb7c4c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
// Generated by tracker_compiler. Do not edit.

#include "audio/tracker.h"

#include "generated/assets.h"

const NoteParams g_tracker_samples[] = {
    {0}, // ASSET_KICK_1 (ASSET)
    {0}, // ASSET_KICK_2 (ASSET)
    {0}, // ASSET_SNARE_1 (ASSET)
    {0}, // ASSET_SNARE_2 (ASSET)
    {0}, // ASSET_SNARE_3 (ASSET)
    {0}, // ASSET_RIDE_1 (ASSET)
};
const uint32_t g_tracker_samples_count = 6;

const AssetId g_tracker_sample_assets[] = {
    AssetId::ASSET_KICK_1,  AssetId::ASSET_KICK_2,  AssetId::ASSET_SNARE_1,
    AssetId::ASSET_SNARE_2, AssetId::ASSET_SNARE_3, AssetId::ASSET_RIDE_1,
};

static const TrackerEvent PATTERN_EVENTS_kick_1[] = {
    {0.00f, 0, 1.0f, 0.0f},
    {0.50f, 0, 1.0f, 0.0f},
};
static const TrackerEvent PATTERN_EVENTS_kick_2[] = {
    {0.00f, 1, 1.0f, 0.0f},
    {0.50f, 1, 1.0f, 0.0f},
};
static const TrackerEvent PATTERN_EVENTS_snare_1[] = {
    {0.25f, 2, 1.0f, 0.0f},
    {0.75f, 2, 1.0f, 0.0f},
};
static const TrackerEvent PATTERN_EVENTS_snare_2[] = {
    {0.25f, 3, 1.0f, 0.0f},
    {0.75f, 3, 1.0f, 0.0f},
};
static const TrackerEvent PATTERN_EVENTS_snare_3[] = {
    {0.25f, 4, 1.0f, 0.0f},
    {0.75f, 4, 1.0f, 0.0f},
};
static const TrackerEvent PATTERN_EVENTS_ride[] = {
    {0.00f, 5, 0.7f, 0.2f},
    {0.25f, 5, 0.6f, 0.2f},
    {0.50f, 5, 0.7f, 0.2f},
    {0.75f, 5, 0.6f, 0.2f},
};

const TrackerPattern g_tracker_patterns[] = {
    {PATTERN_EVENTS_kick_1, 2, 1.00f},  // kick_1
    {PATTERN_EVENTS_kick_2, 2, 1.00f},  // kick_2
    {PATTERN_EVENTS_snare_1, 2, 1.00f}, // snare_1
    {PATTERN_EVENTS_snare_2, 2, 1.00f}, // snare_2
    {PATTERN_EVENTS_snare_3, 2, 1.00f}, // snare_3
    {PATTERN_EVENTS_ride, 4, 1.00f},    // ride
};
const uint32_t g_tracker_patterns_count = 6;

static const TrackerPatternTrigger SCORE_TRIGGERS[] = {
    {0.0f, 0},  {0.0f, 2},  {0.5f, 0},  {0.5f, 2},  {1.0f, 0},  {1.0f, 2},
    {1.5f, 0},  {1.5f, 2},  {2.0f, 0},  {2.0f, 3},  {2.5f, 0},  {2.5f, 3},
    {3.0f, 0},  {3.0f, 3},  {3.5f, 0},  {3.5f, 3},  {4.0f, 1},  {4.0f, 4},
    {4.5f, 1},  {4.5f, 4},  {5.0f, 1},  {5.0f, 4},  {5.5f, 1},  {5.5f, 4},
    {6.0f, 1},  {6.0f, 2},  {6.5f, 1},  {6.5f, 2},  {7.0f, 1},  {7.0f, 2},
    {7.5f, 1},  {7.5f, 2},  {8.0f, 0},  {8.0f, 3},  {8.0f, 5},  {8.5f, 0},
    {8.5f, 3},  {8.5f, 5},  {9.0f, 0},  {9.0f, 3},  {9.0f, 5},  {9.5f, 0},
    {9.5f, 3},  {9.5f, 5},  {10.0f, 1}, {10.0f, 4}, {10.0f, 5}, {10.5f, 1},
    {10.5f, 4}, {10.5f, 5}, {11.0f, 1}, {11.0f, 4}, {11.0f, 5}, {11.5f, 1},
    {11.5f, 4}, {11.5f, 5}, {12.0f, 0}, {12.0f, 2}, {12.0f, 5}, {12.5f, 0},
    {12.5f, 2}, {12.5f, 5}, {13.0f, 0}, {13.0f, 2}, {13.0f, 5}, {13.5f, 0},
    {13.5f, 2}, {13.5f, 5}, {14.0f, 1}, {14.0f, 3}, {14.0f, 5}, {14.5f, 1},
    {14.5f, 3}, {14.5f, 5}, {15.0f, 1}, {15.0f, 3}, {15.0f, 5}, {15.5f, 1},
    {15.5f, 3}, {15.5f, 5},
};

const TrackerScore g_tracker_score = {SCORE_TRIGGERS, 80, 120.0f};

// ============================================================
// RESOURCE USAGE ANALYSIS (for synth.h configuration)
// ============================================================
// Total samples: 6 (6 assets + 0 generated notes)
// Max simultaneous pattern triggers: 3
// Estimated max polyphony: 6 voices
//
// REQUIRED (minimum to avoid pool exhaustion):
//   MAX_VOICES: 6
//   MAX_SPECTROGRAMS: 6 (no caching)
//
// RECOMMENDED (with 50% safety margin):
//   MAX_VOICES: 12
//   MAX_SPECTROGRAMS: 9 (no caching)
//
// NOTE: With spectrogram caching by note parameters,
//       MAX_SPECTROGRAMS could be reduced to ~6
// ============================================================