format code

This commit is contained in:
pigeatgarlic 2026-04-05 23:37:11 +07:00
parent 8d77b8eb39
commit 4ea91d85b6
5 changed files with 2 additions and 41 deletions

View File

@ -5,8 +5,8 @@
#pragma once
#include "thread_safe.h"
#include <bitset>
#include "utility.h"
#include <bitset>
namespace audio {
enum stream_config_e : int {
STEREO,

View File

@ -169,35 +169,4 @@ void log_flush() {
sink->flush();
}
}
/**
* @brief Print help to stdout.
* @param name The name of the program.
*
* EXAMPLES:
* ```cpp
* print_help("sunshine");
* ```
*/
void print_help(const char *name) {
std::cout
<< "Usage: "sv << name << " [options] [/path/to/configuration_file] [--cmd]"sv << std::endl
<< " Any configurable option can be overwritten with: \"name=value\""sv << std::endl
<< std::endl
<< " Note: The configuration will be created if it doesn't exist."sv << std::endl
<< std::endl
<< " --help | print help"sv << std::endl
<< " --creds username password | set user credentials for the Web manager"sv << std::endl
<< " --version | print the version of sunshine"sv << std::endl
<< std::endl
<< " flags"sv << std::endl
<< " -0 | Read PIN from stdin"sv << std::endl
<< " -1 | Do not load previously saved state and do retain any state after shutdown"sv
<< std::endl
<< " | Effectively starting as if for the first time without overwriting any pairings with your devices"sv
<< std::endl
<< " -2 | Force replacement of headers in video stream"sv << std::endl
<< " -p | Enable/Disable UPnP"sv << std::endl
<< std::endl;
}
} // namespace logging

View File

@ -29,5 +29,4 @@ void deinit();
[[nodiscard]] std::unique_ptr<deinit_t> init(int min_log_level);
void setup_av_logging(int min_log_level);
void log_flush();
void print_help(const char *name);
} // namespace logging

View File

@ -149,7 +149,6 @@ struct touch_port_t {
int width, height;
};
class deinit_t {
public:
virtual ~deinit_t() = default;

View File

@ -654,11 +654,7 @@ encoder_t amdvce{
},
PARALLEL_ENCODING};
static const std::vector<encoder_t *> encoders{
&nvenc,
&quicksync,
&amdvce
};
static const std::vector<encoder_t *> encoders{&nvenc, &quicksync, &amdvce};
static encoder_t *chosen_encoder;
int active_hevc_mode;
@ -2462,7 +2458,6 @@ int probe_encoders() {
return 0;
}
util::Either<avcodec_buffer_t, int>
cuda_init_avcodec_hardware_input_buffer(platf::avcodec_encode_device_t *encode_device) {
avcodec_buffer_t hw_device_buf;
@ -2479,7 +2474,6 @@ cuda_init_avcodec_hardware_input_buffer(platf::avcodec_encode_device_t *encode_d
return hw_device_buf;
}
#ifdef _WIN32
}