Files
Nova64/core/include/wasm_runner.h
T

39 lines
957 B
C

#ifndef WASM_RUNNER_H
#define WASM_RUNNER_H
#include <stdbool.h>
#include <stdint.h>
typedef struct wasm_runner_instance wasm_runner_instance_t;
typedef struct {
bool enabled;
uint16_t x;
uint16_t y;
uint16_t width;
uint16_t height;
} wasm_runner_framebuffer_config_t;
bool wasm_runner_initialize(void);
/**
* @brief Starts a WASM program with optional framebuffer access.
*
* @param module_path Path to the WASM module to start.
* @param framebuffer_config Optional framebuffer configuration. If NULL,
* framebuffer access is disabled.
* @param out_instance Optional output pointer that receives a handle to the
* running WAMR instance.
* @return True on success, false on failure.
*/
bool wasm_runner_start_program(
const char *module_path,
const wasm_runner_framebuffer_config_t *framebuffer_config);
void wasm_runner_terminate(void);
uint32_t wasm_runner_get_active_slots
(void);
#endif // WASM_RUNNER_H