OBS Studio currently does not support retina rendering for any of the
images in the app. This adds support for retina pixmap rendering as
well as adding higher resolution versions of each icon that was not
a high enough resolution to support 2x. The icons work when switching
themes and will only render the 2x versions when the device pixel
ratio is greater than or equal to 2.
I also added credits to the readme for images that were already being
used that require credit to the author. If the OBS community has
paid for these images already, I can remove the credits from the
readme. The credit is for the invisible, visible, and gear icons.
In the Dark theme, disabled UI elements had text that was too close in
color to enabled UI elements. This commit switches them to use the
"light" palette color instead of the "lighter" palette color.
Adds the ability to set the current palette for the program via adding
"OBSTheme" objects to the qss files. The values for the OBSTheme object
are the values used by QPalette::ColorRole.
Modifying the global palette allows the ability to easily/quickly look
up application theme colors (especially if you would like to use them
for QML), as well as the ability to fix the hyperlink color issue. (On
dark themes, links would still be dark blue, causing them to be
difficult to see)
Fixing a reference to Rachni theme folder, some minor tweaks and
reverting volume meter foreground colors to original brightness.
Closesjp9000/obs-studio#1169
The decay rate of the audio meters can now be selected in the audio
settings. The values are:
- "Fast" (OBS default, 40 dB / 1.7s)
- "Medium" (Type I PPM, 20 dB / 1.7s)
- "Slow" (Type II PPM, 24 dB / 2.8s)
Closesjp9000/obs-studio#1143
The following features have been added to the audio-meters:
* Stereo PPM-level meter, with 40 dB/1.7s decay rate.
* Stereo VU-level meter, with 300 ms integration time.
* Stereo Peak-hold meter, with 20 second sustain.
* Input peak level color-squares in front of every meter.
* Minor-ticks for each dB.
* Major-ticks for every 5 dB.
* Meter is divided in sections at -20 dB and -9 dB.
The ballistic parameters chosen here where taken from:
* https://en.wikipedia.org/wiki/Peak_programme_meter (SMPTE RP.0155)
* https://en.wikipedia.org/wiki/VU_meter
In the rework I have removed any ballistic calculations from
libobs/obs-audio-controls.c making the calculations here a lot more
simple doing only MAX and RMS calculations for only the samples in
the current update. The actual ballistics are now done by just
the UI/volume-control.cpp because ballistics need to be updated
based on the repaint-rate of the user-interface.
The dB to pixel conversion has been moved from
libobs/obs-audio-controls.c to UI/volume-control.cpp as well to reduce
coupling between these two objects, especially when implementing the
major- and minor-ticks and the sections.
All colors and ballistic parameters are adjustable via QT style sheets.
There are slight differences in colors for each of the themes.
The tab bars in the Rachni theme had an issue related to an attempted
property of qproperty-drawBase: 0 in the .qss file. This, in theory,
should have worked and removed the base of the tab bar, but there is a
bug that prevents this from consistently applying, as detailed here:
https://bugreports.qt.io/browse/QTBUG-2982
This fix removes that property, and adjusts the styling of the tabs
themselves for a more consistent experience. Tabs should no longer be
cut off or displayed improperly.
In addition, this also corrects an issue with the scene/source rename
QLineEdit field displaying improperly.
This makes it so the buttons appear "pressed" while streaming/recording
to more visibly help indicate that they are currently active.
Closesjp9000/obs-studio#1039
With the addition of the peak volume indicator, themes may wish to change
these colors but there was no way to do so. This change updates the
VolumeControl widget to allow a stylesheet to adjust all possible colors
for the volume bar. In addtion, the Rachni theme is updated to demonstrate
this new capability.
I have always felt that the out of the box themes for OBS were quite
lacking, and have spent a lot of time going through and sorting out the
difficulties with the current setup. I've added a new themeID parameter to
several elements that were otherwise impossible to target with QSS in a
theme. Since Qt has pushed for the use of QML over QSS at this point,
these should be considered workarounds. Included is the theme I was
working on that can serve as a base. I'm hoping to encourage others to
make their own themes, so we can grow the available themes for OBS.
I am happy for any feedback on the theme itself, or other updates that
can me made to make creating new themes easier overall.