summaryrefslogtreecommitdiff
path: root/reduced_system_layer.c
diff options
context:
space:
mode:
authorMitya Selivanov <automainint@guattari.tech>2025-01-06 13:12:18 +0100
committerMitya Selivanov <automainint@guattari.tech>2025-01-06 13:12:18 +0100
commit3359f068dc9e8ac036f0f709aeccf11dfba3cf03 (patch)
tree2a392e893e819a7ef7ea01e953bbddc9dad185f0 /reduced_system_layer.c
parent820298fa61835c53694c4ec58d6c5328947ad4ca (diff)
downloadreduced_system_layer-3359f068dc9e8ac036f0f709aeccf11dfba3cf03.zip
No buildin
Diffstat (limited to 'reduced_system_layer.c')
-rwxr-xr-xreduced_system_layer.c16
1 files changed, 4 insertions, 12 deletions
diff --git a/reduced_system_layer.c b/reduced_system_layer.c
index 64b7cfb..a5e63e0 100755
--- a/reduced_system_layer.c
+++ b/reduced_system_layer.c
@@ -1613,18 +1613,6 @@ void p_render_frame(void) {
p_render_frame_impl();
}
- __attribute__((export_name("js_memset"))) void js_memset(void *dst, i32 val, u32 num) {
- if (dst == NULL) return;
- for (u32 i = 0; i < num; ++i)
- ((u8 *) dst)[i] = (u8) val;
-}
-
-__attribute__((export_name("js_memcpy"))) void js_memcpy(void *dst, void const *src, u32 num) {
- if (dst == NULL || src == NULL) return;
- for (u32 i = 0; i < num; ++i)
- ((u8 *) dst)[i] = ((u8 const *) src)[i];
-}
-
__attribute__((export_name("js_main"))) void js_main(c8 *href) {
main(1, &href);
}
@@ -1703,6 +1691,10 @@ __attribute__((export_name("js_keyup"))) void js_keyup(u32 key, u32 mod) {
//
// Web audio
//
+// TODO: Shared memory buffer
+// https://developer.mozilla.org/en-US/docs/WebAssembly/JavaScript_interface/Memory
+// https://developer.mozilla.org/en-US/docs/Web/API/AudioWorkletNode/port
+//
// ================================================================
#ifdef __wasm__