|
ascii-chat 0.6.0
Real-time terminal-based video chat with ASCII art conversion
|
Client mode option parsing. More...
Go to the source code of this file.
Functions | |
| asciichat_error_t | parse_client_options (int argc, char **argv, options_t *opts) |
| Parse client-specific command-line options. | |
| void | usage_client (FILE *stream) |
| Print client mode usage/help text. | |
Client mode option parsing.
Client-specific command-line option parsing and help text. The client mode connects to a server and displays received video streams while capturing and sending local webcam/audio data.
Client-Specific Options:
[address][:port] positional, --port, --lan--webcam-index, --webcam-flip, --test-pattern--width, --height, --color-mode, --render-mode, --fps--audio, --microphone-index, --speakers-index, --audio-analysis--key, --server-key (TOFU verification)--reconnect--compression-level, --no-compress, --encode-audio--show-capabilities, --utf8, --list-webcams, --list-microphones, --list-speakersPositional Arguments:
[address][:port]localhost, 192.168.1.100, example.com:8080, [::1]:27224--port flagShared Options (parsed in options.c):
--palette, --palette-chars--stretch, --quiet, --snapshot, --strip-ansi--encrypt, --no-encrypt, --password, --keyfileDefinition in file lib/options/client.h.
| asciichat_error_t parse_client_options | ( | int | argc, |
| char ** | argv, | ||
| options_t * | opts | ||
| ) |
Parse client-specific command-line options.
Parses all client mode options including:
[address][:port] for server connectionParsing Logic:
Error Handling:
Positional Argument Parsing: After getopt_long() completes, optind points to first non-option argument. Format: [address][:port]
192.168.1.100, 192.168.1.100:8080[::1], [2001:db8::1]:8080localhost, example.com:27224Port conflicts:
Example usage:
Definition at line 50 of file lib/options/client.c.
References ASCIICHAT_OK, options_config_destroy(), options_config_parse(), options_config_set_defaults(), and options_preset_client().
Referenced by options_init().
| void usage_client | ( | FILE * | stream | ) |
Print client mode usage/help text.
Displays comprehensive help for all client options, including:
Output Format:
| stream | Output stream (stdout for –help, stderr for errors) |
Example usage:
Definition at line 86 of file lib/options/client.c.