mirror of
https://github.com/juanjiant-bit/JIANT.git
synced 2026-12-05 20:34:27 +01:00
(the owner: "si dale" / "pasá todas esas"; "renombrar cada parte y proyecto desde Studio, management de proyectos
desde el celular"; RESOUND: "me gusta la canción pero no los sonidos")
- ANALOG WHEEL PHASE MATH/LOFI STRING's creatures through vx_gx (codex/gx-creatures 37d7a765), closer to their
own: WHEEL's worms out of their tubes waving at their harmonic, crowns of tentacles; ANALOG's isotherms
wobbling, spikes, cilia and the two oscillators orbiting; PHASE's body doubled, its tail curled; MATH's segments
doubled. WEST, VOICE, ANIMAL, FM6 and DRUM-X keep their own (protected pictures untouched).
- Editor protocol, Studio's project library (editor_backup.c ed_pj_handle; app_contract_test, backup_test):
95 PROJ_LIST () -> rc 0, NSONG, NSONG x (n, parts, flags, name[12])
parts: bit k = part A..D stored; flags: 1 the open project, 2 a GEN draft; name: part A's, ASCII
0-padded (the project's name)
96 PROJ_NAME (n, part 0..3, ASCII up to 12) -> n, part, rc (part 0's name is the project's; live, in flash)
97 PROJ_OP (op, from, to, force) -> op, from, to, rc
op 0 COPY, 1 MOVE (not the open project), 2 DELETE (from; to ignored); COPY/MOVE never onto the
open project; an occupied target only with force 1 (Studio: BACKUP_GET it first)
rc: 0 done, 1 refused (bad request, the open project as target or moved, empty part), 2 flash failed
(the target as it was), 3 playing (STOP first), 4 the target holds a project (force 0)
No BACKUP object 72+p: the names travel in PROJ_LIST and in part A's own object (40 + 4n).
- GLO + A4: RESOUND (gen.c gen_rs_prep / gen_rs_apply, the web's web_gen_resound now calls them): new sounds
for every track by its role (GEN's genre, or a seed's near the tempo), the notes, steps and song kept, the next
sections keep them (a player's sound), "RESOUND #seed"; GLO + G4 the sounds back. The GLO map's A4 RESOUND.
- Banners: RESTART (GLO + PLAY playing), a DRUM sound's mute (EDIT + black: "SD MUTED"), LANE (SEQ + black),
REC GRID n% (REC + KNOB 2), PROJECT n / LET GO: OPEN (SAVE + KNOB 1), KNOB 4: DJ FILTER / BPM (MIXER's OCT+),
"A > B NEXT BAR". A lens page's OCT+ gestures in its footer for 1.5 s on entering and while OCT+ is held
(EDIT 1 HOLD: K4 GAIN, FILTER K2 KEY TRK, REVERB / DLY K4 GATE, EUCLID, PRESETS, SCENE, PUNCH IN, TRACK GEN,
ARRANGE, TAKE, SYSTEM).
- tests/ui_render.c builds and runs its scenes again (dk_keep gone in V10.8.21; STEREO's title; pages since gone
drawn where they are).
Layout recorded again (FELUCCA_REPIN=keep); the plain build passes. Image 580784 of 584336 (3552 B free), BT
segment 72680 of 73728 (1048 B free), RAM code 32700 (the calls into the image moved; no RAM code added), pool
spare 8480. audio.c as V23's.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01KMHk6yH4XbP1xxHYKCo9Mh
88 lines
4.5 KiB
C
88 lines
4.5 KiB
C
/* SPDX-License-Identifier: GPL-3.0-only */
|
|
/* Copyright (C) 2026 Juan Ignacio Antonucci (Juan Jiant) */
|
|
#define UI_TEST_NO_MAIN 1
|
|
#include "ui_test.c"
|
|
|
|
int main(void)
|
|
{
|
|
int bad = 0;
|
|
uint32_t before, after, other;
|
|
char label[12];
|
|
ui_power_on();
|
|
song.sel = 0;
|
|
my_steps(&trk[0]); my_steps(&trk[1]);
|
|
before = steps_sig(&trk[0]); other = steps_sig(&trk[1]);
|
|
press(B_REC);
|
|
bad += check("arming REC captures the music before the take", undo_ok && song.rec == 1);
|
|
trk[0].step[0].note[0] = 77; after = steps_sig(&trk[0]);
|
|
ly_white(B_REC, 2);
|
|
bad += check("REC+A3 restores the take; shortcut key is not recorded and REC disarms",
|
|
steps_sig(&trk[0]) == before && steps_sig(&trk[1]) == other && !song.rec && !gates());
|
|
ly_white(B_REC, 2);
|
|
bad += check("REC+A3 again redoes the same take", steps_sig(&trk[0]) == after && !song.rec);
|
|
ly_white(B_GLO, GLO_UNDO);
|
|
bad += check("original GLO+G4 shares the same undo/redo snapshot", steps_sig(&trk[0]) == before);
|
|
|
|
ui_power_on(); undo_ok = 0;
|
|
ly_white(B_REC, 2);
|
|
bad += check("empty undo reports NOTHING TO UNDO and never arms REC", msg_is("NOTHING TO UNDO") && !song.rec);
|
|
undo_mark(); trk[0].step[0].note[0] = 70; after = steps_sig(&trk[0]);
|
|
chain.running = 1;
|
|
ly_white(B_REC, 2);
|
|
bad += check("song-chain guard refuses undo without changing notes", msg_is("SONG PLAYS: STOP IT TO EDIT") && steps_sig(&trk[0]) == after);
|
|
chain.running = 0;
|
|
|
|
ui_power_on(); song.sel = 2;
|
|
trk[2].p[P_HRQ] = 127; trk[1].p[P_HRQ] = 64;
|
|
ly_white(B_REC, 3);
|
|
bad += check("REC+B3 turns recording quantization off on selected track only",
|
|
!trk[2].p[P_HRQ] && trk[1].p[P_HRQ] == 64 && !song.rec && !gates());
|
|
ly_white(B_REC, 3);
|
|
bad += check("REC+B3 toggles hard quantization back to 100 percent", trk[2].p[P_HRQ] == 127 && !song.rec);
|
|
rec_down(); frames(512);
|
|
turn(EN_K2, -8);
|
|
bad += check("REC+K2 exposes partial recording quantization", trk[2].p[P_HRQ] > 0 && trk[2].p[P_HRQ] < 127);
|
|
turn(EN_K2, -1000);
|
|
bad += check("REC+K2 reaches fully unquantized recording", !trk[2].p[P_HRQ] && !song.rec);
|
|
bad += check("REC map labels UNDO and quantization state",
|
|
(ly_keyname(LAYER_REC, 0, 2, label), str_eq(label,"UNDO")));
|
|
bad += check("REC map shows Q OFF", (ly_keyname(LAYER_REC, 0, 3, label), str_eq(label,"Q OFF")));
|
|
rec_up();
|
|
|
|
ui_power_on(); my_steps(&trk[0]); before=steps_sig(&trk[0]); press(B_REC);
|
|
trk[0].step[0].note[0]=78; frames(400); press(B_REC);
|
|
ly_white(B_REC,2);
|
|
bad += check("disarming REC keeps the original pre-take undo snapshot", steps_sig(&trk[0])==before);
|
|
ui_power_on(); go_page(GR_ROLL); cursor_set(3); frame();
|
|
press(B_REC);
|
|
bad += check("REC arms stopped step entry without issuing PLAY",song.rec==1 && !song.playing && !transport_req && !seq_counting());
|
|
{uint32_t pg=ui.page;turn(EN_SELECT,1);
|
|
bad += check("SELECT changes SEQ page while REC is armed, keeping the step cursor",ui.page!=pg && ui.cursor==3 && song.rec==1 && !song.playing);
|
|
turn(EN_SELECT,-1);turn(EN_PRESET,2);
|
|
bad += check("PRESET keeps horizontal SEQ movement while REC is armed",ui.page==pg && ui.cursor==5 && !song.playing);
|
|
key_down(7);frame();key_up(7);frame();
|
|
bad += check("stopped REC inserts a note and advances without starting the sequencer",TSEL->step[5].n==1 && ui.cursor==6 && !song.playing && !transport_req);
|
|
}
|
|
press(B_PLAY);
|
|
bad += check("PLAY independently starts an already armed recording",transport_req==1 && song.rec==1);
|
|
song.playing=1;transport_req=0;frames(400);press(B_REC);
|
|
bad += check("REC disarms during playback without stopping PLAY",song.rec==0 && song.playing && !transport_req);
|
|
/* (V10.8.21: GLO > G.COMP gone) */
|
|
bad += test_rec();
|
|
bad += test_rec_layer();
|
|
bad += test_rec_combos();
|
|
{ /* (V10.8.54) GLO + A4: RESOUND, the notes kept, new sounds; GLO + G4 the sounds back */
|
|
uint32_t e0, p0, sig;
|
|
ui_power_on(); song.sel = 0;
|
|
my_steps(&trk[0]); sig = steps_sig(&trk[0]);
|
|
e0 = trk[0].eng_req; p0 = trk[0].preset;
|
|
ly_white(B_GLO, GLO_RESOUND);
|
|
bad += check("GLO+A4 RESOUND: the notes kept, another sound, its banner",
|
|
steps_sig(&trk[0]) == sig && (trk[0].eng_req != e0 || trk[0].preset != p0) && !strncmp(ui.msg, "RESOUND #", 9));
|
|
ly_white(B_GLO, GLO_UNDO);
|
|
bad += check("GLO+G4 after RESOUND: the sound back", trk[0].eng_req == e0 && trk[0].preset == p0 && steps_sig(&trk[0]) == sig);
|
|
}
|
|
return bad != 0;
|
|
}
|
|
|