Banjo API 1.1.0-alpha
Low-level C99 game development API
Loading...
Searching...
No Matches
system.h
Go to the documentation of this file.
1
70#ifndef BJ_SYSTEM_H
71#define BJ_SYSTEM_H
72
73#include <banjo/api.h>
74#include <banjo/error.h>
75
76#include <stddef.h> /* size_t */
77
84
103 int systems,
104 struct bj_error** error
105);
106
136 const char** p_names,
137 size_t cap
138);
139
169 const char** p_names,
170 size_t cap
171);
172
181 void
182);
183
228 enum bj_system system,
229 const char* backend_name,
230 struct bj_error** error
231);
232
248 enum bj_system system,
249 struct bj_error** error
250);
251
289 const char* path,
290 struct bj_error** error
291);
292
318 void* handle
319);
320
357 void* handle,
358 const char* name,
359 struct bj_error** error
360);
361
362#endif
General-purpose definitions for Banjo API.
Recoverable error handling.
struct bj_error bj_error
Definition api.h:348
#define BANJO_EXPORT
Definition api.h:179
uint32_t bj_bool
Boolean type used throughout the Banjo API.
Definition api.h:264
bj_bool bj_begin(int systems, struct bj_error **error)
Initialises the system.
void bj_end_system(enum bj_system system, struct bj_error **error)
De-initialises a single system with reference counting.
void * bj_load_library(const char *path, struct bj_error **error)
Load the provided dynamic library and returns and opaque handle to it.
size_t bj_video_backends(const char **p_names, size_t cap)
Enumerate the video backends compiled into this build.
void bj_end(void)
De-initialises the system.
bj_system
Definition system.h:78
bj_bool bj_begin_system(enum bj_system system, const char *backend_name, struct bj_error **error)
Initialise one subsystem (refcounted), optionally pinning a backend.
void * bj_library_symbol(void *handle, const char *name, struct bj_error **error)
Get the address of a function exported by handle given its name.
void bj_unload_library(void *handle)
Unload a library loaded with bj_load_library from memory.
size_t bj_audio_backends(const char **p_names, size_t cap)
Enumerate the audio backends compiled into this build.
@ BJ_VIDEO_SYSTEM
Definition system.h:81
@ BJ_NETWORK_SYSTEM
Definition system.h:82
@ BJ_AUDIO_SYSTEM
Definition system.h:80
@ BJ_NO_SYSTEM
Definition system.h:79