Commit Graph

5 Commits

Author SHA1 Message Date
swipelab
e4a502e922 P10.7: soften the SFX bank (gentler / less aggressive)
DSP-soften the existing P10.6 CC0 bank in place — same filenames, same
canonical WAVE/mono/44100/Int16 format, drop-in (engine untouched):

- Onset eased in: short qsin fade-in (8-14 ms) tames the attack transient
  so pops bloop instead of snap (onset peak in first 20 ms down 5.6-8.7 dB
  per cue; combo attack-to-peak 1.4-2.4 ms -> 15-26 ms).
- Highs rolled off: warm two-pole low-pass (2.6 kHz swap/lose, 3.0 kHz
  match/combo, 3.6 kHz win) for a rounded tone. Spectral centroid down
  ~40-60%; >4 kHz energy collapses (win 76%->28%, combos ~10%->0.5%).
- Quieter: re-normalized to -15.5 dBFS (swap/lose -17.5), down from ~-9/-12,
  lowering both peak and RMS on every cue.

Candy character retained; cascade ladder preserved (combo1..5 fundamentals
still ascend 1045<1173<1317<1566<1758 Hz). LICENSE provenance updated.
2026-06-06 06:52:51 +03:00
swipelab
f3e3876574 P10.6: tune SFX bank to the candy character (real CC0 marimba/glock + pops)
Refine the same drop-in bank toward Candy-Crush candy/jelly character; engine
(audio.sx) untouched, same filenames/format.

- swap: freesound CC0 "Pop 01" (LilMati #506546) — soft light blip.
- match: freesound CC0 "Cartoon Pop" (Mish7913 #741368) — bright juicy candy pop.
- combo1..5: VCSL CC0 Marimba F5, real-resample pitch-laddered to a C-major
  pentatonic (C5 D5 E5 G5 A5) — warm/sweet mallet sparkle, not glassy; ascending.
- win: VCSL CC0 Glockenspiel C5/G5/C6 sequenced into a sugary ascending bell
  fanfare.
- lose: VCSL CC0 Marimba B4->G4 descending — soft gentle "aww".

All real free CC0 assets (NOT ripped from Candy Crush); provenance + license per
cue in LICENSE.txt. Mono/44100/Int16, <=580 ms, peak <=-9 dBFS (lose -12).
Combos ascend (1045<1173<1317<1566<1758 Hz). Gate green; all 9 cues load on sim.
2026-06-05 23:20:50 +03:00
swipelab
ae44e5b7fb P10.5: replace synth SFX bank with real CC0 Kenney assets (quieter, cleaner)
QA: "the sfx is too loud and scratchy." Drop-in asset swap — no engine change.

Replace the 9 synthesized cues (swap, match, combo1..combo5, win, lose) with
real free-licensed (CC0 1.0) sound effects from Kenney's Interface Sounds /
Digital Audio packs:
  swap  <- pluck_002        match <- confirmation_002
  win   <- powerUp7         lose  <- minimize_006
  combo1..5 <- glass_001 pitch-laddered up a pentatonic run (0,+2,+4,+7,+9 st)
              via resample DSP -> ascending fundamentals 1918..3226 Hz.

Every cue: mono / 44100 Hz / Int16 PCM, <=0.54 s. Whole bank peak-normalized to
-9 dBFS, so peak AND RMS are well below the old synth (old peak -0.7..-2.9 dB,
mean -5.8..-9.3 dB; new peak -9.0 dB, mean -22..-30 dB). Audibly cleaner — no
synth harmonics.

LICENSE.txt rewritten with real per-file provenance (source URL + CC0). clear.wav
(already a CC0 Kenney clip, not loaded by the engine) left unchanged. Engine
(audio.sx/board_view.sx/main.sx) untouched; sim build loads all 9 cues, zero
"load failed".
2026-06-05 22:41:52 +03:00
swipelab
7f23bc8b19 P10.1: candy-vibe higher-pitched SFX bank (sx / iOS assets)
Produce the first deliverable of the Candy-Crush vibe pass: a bank of bright,
glossy, higher-pitched SFX WAVs under assets/audio/, all in the exact canonical
iOS System-Sound format clear.wav uses (mono, 44100 Hz, signed-16-bit PCM).

Bank: swap, match, combo1..combo5 (ascending pentatonic run C6 D6 E6 G6 A6),
win (ascending arpeggio), lose (descending stinger). Every cue sits above
clear.wav's ~784 Hz fundamental; combo1<..<combo5 step strictly upward
(1047<1175<1319<1568<1760 Hz). Each loads via AudioServicesCreateSystemSoundID
with status 0.

Synthesized by the build-time tools/synth_audio.py (pure-Python additive
synthesis; the app never runs it) and converted with afconvert. Pitch verified
with tools/measure_pitch.py. Provenance (CC0) recorded in LICENSE.txt. No sx
code changes — engine wiring is P10.2/P10.3.
2026-06-05 19:28:11 +03:00
swipelab
f0a13293bb P8.1: minimal match/clear SFX via iOS System Sound Services (sx FFI)
Feasibility spike outcome: iOS audio from sx is feasible with no sx-library
change. System Sound Services is plain C, reached with the same `#foreign`
FFI uikit.sx already uses (UIApplicationMain / dlsym / CACurrentMediaTime);
AudioToolbox + CoreFoundation are linked per-target in build.sx.

Smallest viable SFX: one short CC0 clip (Kenney Interface Sounds, CC0 1.0)
played when a swap clears a match. Purely additive — audio.sx reads/writes
no score/board/move state; the wiring in board_view only adds a call.

- audio.sx: load clear.wav once, AudioServicesPlaySystemSound on clear
- board_view.sx: trigger sfx_clear() on a legal swap that clears (>=1 round)
- main.sx: allocate + init g_audio at boot
- build.sx: link AudioToolbox + CoreFoundation on iOS
- assets/audio/clear.wav (+ one-line CC0 credit in LICENSE.txt)

Verified: ios-sim build links; 18/18 tests pass; sim boot log shows
"[sx] audio: clear cue loaded" (AudioServicesCreateSystemSoundID succeeded,
asset shipped in the bundle and decoded).
2026-06-05 18:19:33 +03:00