ascii-chat
Binary v0.16.114-28-gf5913657f
Library lib/v0.3.2-3302-gf5913657f
Video chat in your terminal
Loading...
Searching...
No Matches
lib/wasm/stubs/stats.c
Go to the documentation of this file.
1/* JavaScript owns browser presentation and the native stats UI is unavailable. */
3
4asciichat_error_t stats_runtime_start(const char *mode, unsigned interval_seconds) {
5 (void)mode;
6 (void)interval_seconds;
7 return SET_ERRNO(ERROR_INVALID_STATE, "Native statistics runtime is unavailable in browsers");
8}
9void stats_runtime_stop(void) {}
11 return NULL;
12}
14 (void)peer;
15 return NULL;
16}
18 (void)provider;
19 (void)data;
20}
21void stats_view_add(stats_view_t *view, const char *format, ...) {
22 (void)view;
23 (void)format;
24}
27 return false;
28}
29stats_peer_t *stats_runtime_peer_open(const char *transport) {
30 (void)transport;
31 return NULL;
32}
34 (void)peer;
35}
36void stats_runtime_packet(stats_peer_t *peer, unsigned type, size_t bytes, bool sent, bool success) {
37 (void)peer;
38 (void)type;
39 (void)bytes;
40 (void)sent;
41 (void)success;
42}
43void stats_runtime_connection_state(const char *state) {
44 (void)state;
45}
46void stats_runtime_media(unsigned width, unsigned height, double position, double duration) {
47 (void)width;
48 (void)height;
49 (void)position;
50 (void)duration;
51}
#define SET_ERRNO(code,...)
unsigned int height
Definition fft.c:24
unsigned int width
Definition fft.c:24
asciichat_error_t
Error and exit codes - unified status values (0-255).
Definition error_codes.h:48
@ ERROR_INVALID_STATE
struct stats_scope stats_scope_t
stats_scope_t * stats_runtime_peer_scope(stats_peer_t *peer)
void stats_runtime_packet(stats_peer_t *peer, unsigned type, size_t bytes, bool sent, bool success)
void stats_runtime_set_provider(stats_provider_fn provider, void *data)
void stats_runtime_toggle(void)
void stats_runtime_connection_state(const char *state)
void stats_runtime_peer_close(stats_peer_t *peer)
void stats_runtime_media(unsigned width, unsigned height, double position, double duration)
void stats_runtime_stop(void)
bool stats_runtime_active(void)
stats_peer_t * stats_runtime_peer_open(const char *transport)
void stats_view_add(stats_view_t *view, const char *format,...)
asciichat_error_t stats_runtime_start(const char *mode, unsigned interval_seconds)
stats_scope_t * stats_runtime_scope(void)
void(* stats_provider_fn)(stats_view_t *view, void *data)
struct stats_peer stats_peer_t