mirror of
https://github.com/vsariola/sointu.git
synced 2025-05-28 03:10:24 -04:00
The preprocessing is done sointu-cli and (almost) nothing is done by the NASM preprocessor anymore (some .strucs are still there. Now, sointu-cli loads the .yml song, defines bunch of macros (go functions / variables) and passes the struct to text/template parses. This a lot more powerful way to generate .asm code than trying to fight with the nasm preprocessor. At the moment, tests pass but the repository is a bit of monster, as the library is still compiled using the old approach. Go should generate the library also from the templates.
44 lines
1.5 KiB
NASM
44 lines
1.5 KiB
NASM
;-------------------------------------------------------------------------------
|
|
; unit struct
|
|
;-------------------------------------------------------------------------------
|
|
struc su_unit
|
|
.state resd 8
|
|
.ports resd 8
|
|
.size:
|
|
endstruc
|
|
|
|
;-------------------------------------------------------------------------------
|
|
; voice struct
|
|
;-------------------------------------------------------------------------------
|
|
struc su_voice
|
|
.note resd 1
|
|
.release resd 1
|
|
.inputs resd 8
|
|
.reserved resd 6 ; this is done to so the whole voice is 2^n long, see polyphonic player
|
|
.workspace resb 63 * su_unit.size
|
|
.size:
|
|
endstruc
|
|
|
|
;-------------------------------------------------------------------------------
|
|
; synthworkspace struct
|
|
;-------------------------------------------------------------------------------
|
|
struc su_synthworkspace
|
|
.curvoices resb 32 ; these are used by the multitrack player to store which voice is playing on which track
|
|
.left resd 1
|
|
.right resd 1
|
|
.aux resd 6 ; 3 auxiliary signals
|
|
.voices resb 32 * su_voice.size
|
|
.size:
|
|
endstruc
|
|
|
|
;-------------------------------------------------------------------------------
|
|
; su_delayline_wrk struct
|
|
;-------------------------------------------------------------------------------
|
|
struc su_delayline_wrk
|
|
.dcin resd 1
|
|
.dcout resd 1
|
|
.filtstate resd 1
|
|
.buffer resd 65536
|
|
.size:
|
|
endstruc
|