[obsidian] vault backup: 2023-11-22 16:15:03[

This commit is contained in:
松浦 知也 Matsuura Tomoya 2023-11-22 16:15:03 +09:00
parent effbc9db16
commit e197479fa4

View File

@ -85,14 +85,21 @@ Program as a Format - MPEG-Structured Audio(CSoundベースの音源配布フォ
まだシンタックスパーサーが実装されてないので、Rust風の擬似ソースコード
```rust
let sinewave =|freq,amp,phase|{
...
}
let apply_fadeinout = |start,dur,time_in,time_out,content|{
...
}
let FadeInOut = |time_in,time_out,origin|{
let time_in = Param("time_in",0.01,0.0..inf);
let time_out = Param("time_out",0.01,0.0..inf);
Region({
start: origin.start
dur : origin.dur
content: apply_fadeinout(start,dur,time_in,time_out,origin.content)
})
}
let project = |sample_rate|{
let tracks = Track([
FadeInOut(
@ -109,9 +116,7 @@ let project = |sample_rate|{
}
)
]);
tracks.map(||
)
tracks.map(|t| t.render()).sum()
}
```