diff options
Diffstat (limited to 'README.md')
| -rw-r--r-- | README.md | 8 |
1 files changed, 5 insertions, 3 deletions
@@ -124,7 +124,7 @@ State. `imageAt`, `target`, `blend`, `text`, `print`, `clip`, `canvas`, `cursor`, `voice`, `gain`, `audio`, `microphone`, `pixels`, `gpu`, `compute`, `upload`, `download`, `openFile`, `run`, `quit`, plus the three allocators and `f.host` (`loadImage`, `decodeImage`, `newImage`, `newBuffer`, `loadSound`, -`decodeSound`, `newSound`, `samples`, `readFile`, `appendFile`, `env`, `log`, `textSize`). Commands may be built +`decodeSound`, `newSound`, `samples`, `readFile`, `appendFile`, `writeFile`, `env`, `log`, `textSize`). Commands may be built from locals: the methods copy what they keep (text, GPU descriptions, uniforms) into scratch. Bulk data (vertices, samples, pixels, uploads) is not copied and must outlive the frame: scratch or session memory. @@ -172,8 +172,10 @@ files are already written, say). run`), creating it, and returns its path for `readFile` ("" when nothing was written, and always on the web). Only `draw` and `command` can call it, and a write is not replayed, like sound. `readFile` maps a file once, so -what is appended afterwards is not in what it returned. micscope writes -each take to `take-<id>.f32` as it records. +what is appended afterwards is not in what it returned. +`f.host.writeFile(name, bytes)` does the same to a new, empty file of that +name. micscope starts each take's `take-<id>.f32` so, and appends to it as +it records. `f.download(buffer, .{ .size = n, .key = k })` reads a GPU buffer back without stalling: the bytes arrive in a later frame's `in.downloads`, a |
