|
ascii-chat 0.6.0
Real-time terminal-based video chat with ASCII art conversion
|
🔧 Shared SIMD utilities: initialization, cleanup, and architecture-specific resource management More...
Go to the source code of this file.
Functions | |
| void | build_ramp64 (uint8_t ramp64[64], const char *ascii_chars) |
| Build 64-entry character ramp cache. | |
| uint64_t | get_current_time_ns (void) |
| Get current time in nanoseconds. | |
| double | calculate_cache_eviction_score (uint64_t last_access_time, uint32_t access_count, uint64_t creation_time, uint64_t current_time) |
| Calculate cache eviction score. | |
| __attribute__ ((no_sanitize("integer"))) | |
| Register a WebRTC client with the server. | |
| void | build_utf8_luminance_cache (const char *ascii_chars, utf8_char_t cache[256]) |
| Build UTF-8 luminance cache. | |
| void | build_utf8_ramp64_cache (const char *ascii_chars, utf8_char_t cache64[64], uint8_t char_index_ramp[64]) |
| Build UTF-8 ramp64 cache. | |
🔧 Shared SIMD utilities: initialization, cleanup, and architecture-specific resource management
Definition in file video/simd/common.c.
| __attribute__ | ( | (no_sanitize("integer")) | ) |
Register a WebRTC client with the server.
Registers a client that connected via WebRTC data channel instead of TCP socket. This function reuses most of add_client() logic but skips:
DIFFERENCES FROM add_client():
| server_ctx | Server context |
| transport | WebRTC transport (already created and connected) |
| client_ip | Client IP address for logging (may be empty for P2P) |
Definition at line 256 of file video/simd/common.c.
References utf8_palette_cache_s::access_count, calculate_cache_eviction_score(), get_current_time_ns(), utf8_palette_cache_s::key, utf8_palette_cache_s::last_access_time, log_debug, and SAFE_FREE.