mirror of
https://github.com/vsariola/sointu.git
synced 2025-07-18 21:14:31 -04:00
feat(sointu): add SynthService for recompiling the synth when needed
This commit is contained in:
@ -13,6 +13,14 @@ import (
|
||||
"github.com/vsariola/sointu/compiler"
|
||||
)
|
||||
|
||||
type BridgeService struct {
|
||||
}
|
||||
|
||||
func (s BridgeService) Compile(patch sointu.Patch) (sointu.Synth, error) {
|
||||
synth, err := Synth(patch)
|
||||
return synth, err
|
||||
}
|
||||
|
||||
func Synth(patch sointu.Patch) (*C.Synth, error) {
|
||||
s := new(C.Synth)
|
||||
comPatch, err := compiler.Encode(&patch, compiler.AllFeatures{})
|
||||
|
Reference in New Issue
Block a user