Add bitrate auto-adjustment toggle and reset button

This change adds a 'Use Default' button next to the bitrate slider that resets the bitrate to the default value for the current resolution/FPS. It also implements an autoAdjustBitrate setting that controls whether the bitrate is automatically updated when resolution/FPS/YUV444 settings change.

- When the user manually adjusts the bitrate slider, autoAdjustBitrate is set to false
- When the user clicks the 'Use Default' button, autoAdjustBitrate is set to true
- Bitrate is only updated automatically when settings change if autoAdjustBitrate is true
This commit is contained in:
MoreOrLessSoftware
2025-03-24 13:17:10 -07:00
committed by Cameron Gutman
parent 9c9bfd8428
commit e807a52cfa
3 changed files with 62 additions and 29 deletions
+3
View File
@@ -110,6 +110,7 @@ public:
Q_PROPERTY(int fps MEMBER fps NOTIFY displayModeChanged)
Q_PROPERTY(int bitrateKbps MEMBER bitrateKbps NOTIFY bitrateChanged)
Q_PROPERTY(bool unlockBitrate MEMBER unlockBitrate NOTIFY unlockBitrateChanged)
Q_PROPERTY(bool autoAdjustBitrate MEMBER autoAdjustBitrate NOTIFY autoAdjustBitrateChanged)
Q_PROPERTY(bool enableVsync MEMBER enableVsync NOTIFY enableVsyncChanged)
Q_PROPERTY(bool gameOptimizations MEMBER gameOptimizations NOTIFY gameOptimizationsChanged)
Q_PROPERTY(bool playAudioOnHost MEMBER playAudioOnHost NOTIFY playAudioOnHostChanged)
@@ -149,6 +150,7 @@ public:
int fps;
int bitrateKbps;
bool unlockBitrate;
bool autoAdjustBitrate;
bool enableVsync;
bool gameOptimizations;
bool playAudioOnHost;
@@ -185,6 +187,7 @@ signals:
void displayModeChanged();
void bitrateChanged();
void unlockBitrateChanged();
void autoAdjustBitrateChanged();
void enableVsyncChanged();
void gameOptimizationsChanged();
void playAudioOnHostChanged();