227 Commits

Author SHA1 Message Date
Translation Updater
ac8dbf67be Update translations from Crowdin 2022-02-06 02:24:08 +00:00
Richard Stanway
42fc705333 obs-filters: Fix incorrect format string
Detected by PVS Studio.
2022-01-15 00:17:02 +01:00
jp9000
006fdd2be5 Revert "obs-filters: Remove duplicate color correction code"
This reverts commit 6940495e79d6313f61e9c73a0bb75b078810f118.
2021-12-25 17:10:44 -08:00
jp9000
c16f27d269 Revert "obs-filters: Remove duplicate code from color key filter"
This reverts commit a4045ed31aee67649e71d10e2793b39677ce2c04.
2021-12-25 17:10:43 -08:00
jp9000
f4317888de Revert "obs-filters: Remove duplicate code from chroma key filter"
This reverts commit 311330628d2eb197b5bff88c05bedcc21a47ca55.
2021-12-25 17:10:41 -08:00
Translation Updater
062de2c998 Update translations from Crowdin 2021-12-17 08:01:29 +00:00
Translation Updater
261345f9ef Update translations from Crowdin 2021-12-12 02:38:59 +00:00
gxalpha
ec7c49a569 obs-filters: Fix unused parameter warnings with speex disabled 2021-12-04 15:23:07 -08:00
Clayton Groeneveld
41e465492f obs-filters: Remove duplicate code from chroma key filter
This removes duplicate code from the chroma key filter from
when it was versioned.
2021-10-28 09:14:23 -07:00
Clayton Groeneveld
8b634ab15a obs-filters: Remove duplicate code from color key filter
This removes duplicate code from the color key filter when
it was versioned.
2021-10-28 09:14:23 -07:00
Clayton Groeneveld
5483aba814 obs-filters: Remove duplicate color correction code
This removes duplicate code from the color correction filter
when it was versioned.
2021-10-28 09:14:23 -07:00
Tommy Vercetti
232c35cc22 obs-filters: Add libSpeexDSP guard to method
`method` should be used under the same condition as they were defined. That is when both `LIBRNNOISE_ENABLED` and  `LIBSPEEXDSP_ENABLED` are defined.
2021-10-24 02:02:53 -07:00
Ryan Foster
424128a825 clang-format: Commit file changes for clang-format 11 2021-10-13 20:00:04 +11:00
Vainock
11a690b038 Update translations from Crowdin 2021-09-24 09:42:08 -07:00
jpark37
3d342cd1e1 obs-filters: Fix NvAFX mutex leak 2021-08-23 23:15:11 -07:00
Ryan Foster
835ac0a556 obs-filters: Correct log prefix for noise suppression filter 2021-07-31 15:32:35 -07:00
Ryan Foster
41b3913793 obs-filters: Use correct NVIDIA capitalization 2021-07-31 15:32:35 -07:00
jpark37
ffac4c3733 obs-filters: Sample mask/blend texture linearly
Makes behavior of blend addition more reasonable.
2021-07-30 23:39:02 -07:00
Richard Stanway
5d54cc36a7 obs-filters: Minor NVAFX cleanup
Remove some unused variables, fix incorrect mutex initializer, fix
exporting NVAFX functions via dllexport.
2021-07-24 23:15:45 +02:00
jpark37
4d9d7b7070 obs-filters: Fix comparison type mismatch 2021-07-06 14:08:28 -07:00
Translation
ef2b1eb1c6 Update translations from Crowdin 2021-06-11 07:18:15 -07:00
jpark37
08c5f02010 obs-filters: Fix swapped chroma distance values 2021-06-02 03:37:46 -07:00
Gol-D-Ace
90df8d44df Update translations from Crowdin 2021-05-30 20:33:35 +02:00
Richard Stanway
c5bb1278f4 obs-filters: Test if NVAFX is supported on load
Prevents situations where the redistributable is installed and OBS
enables the RTX denoiser but it is non-functional. Changes were tested
on systems with both supported / unsupported GPUs and it adds around
10-20ms to the load time in both cases.
2021-05-28 23:14:37 -07:00
jpark37
5fcffb066e obs-filters: Fix blend state for Scale filter
Was incorrectly using straight alpha blend instead of premultiplied.
2021-05-14 01:01:05 -07:00
jpark37
9e3dfa2409 obs-filters: Premultiply alpha for precision
For Apply LUT, and Luma Key, multiply alpha in shader instead of blend
unit for extra precision.
2021-05-14 01:01:05 -07:00
jpark37
9e092bf28e obs-filters: Fix color key distance
Was incorrectly computing distance between linear color and nonlinear
key. Make color nonlinear to match previous behavior.
2021-05-11 20:23:19 -07:00
jpark37
f40eede37a obs-filters: Fix unreferenced variable warning 2021-05-08 14:12:54 -07:00
jpark37
67c2c45964 obs-filters: Fix shader for LUT on OpenGL 2021-05-05 09:42:11 -07:00
jpark37
ae7718a765 libobs, obs-filters: SRGB backwards compatibility
Add OBS_SOURCE_SRGB to indicate sources that support SRGB rendering. We
can use this flag to know which sources do not know how to handle SRGB,
and disable accordingly inside obs_source_main_render().

We can also use this flag to clean up the filter interface and remove
the SRGB-specific functions. We also need to disable direct rendering if
the filter source wants to render SRGB, but the parent source does not
support it.

Scenes and groups are marked as having SRGB support, and those are
internal sources that we control.
2021-05-03 01:19:56 -07:00
jpark37
e55bfa8e20 obs-filters: Increase opacity precision
For v2 filters, switch Opacity settings from integer [0, 100] to
floating-point [0.0, 1.0] with four decimal places for granular blacks.

Also multiply alpha in shader to maintain precision.
2021-04-30 00:19:49 -07:00
jpark37
8c513ab84c obs-filters: Fix bad math in Color Key v1
Do not treat incoming color uniform as premultiplied.
2021-04-29 13:35:50 -07:00
jpark37
607ee098c5 obs-filters: Handle premultiplied alpha input
Mostly by converting to straight alpha in shader when necessary.
2021-04-28 18:09:52 -07:00
Ryan Foster
8946f02270 obs-filters: Use correct branding for NVIDIA Noise Removal
The feature name is "Noise Removal" with that exact capitalization.
"NVIDIA Noise Removal" or "Noise Removal, powered by NVIDIA Broadcast"
are the two valid options for displaying this feature name in the UI.
2021-04-27 15:29:08 -04:00
Richard Stanway
61964d519c obs-filters: Check NVAFX is enabled before using mutexes
Fixes a crash on destroy if NVAFX wasn't actually available.
2021-04-25 19:51:20 +02:00
pkv
a5fab92d6f obs-filters: Better describe denoiser methods in menu
The description of the noise suppression methods was updated to
reflect cpu usage and quality in a more accurate manner.
2021-04-25 09:34:45 -07:00
pkv
535f4765ff obs-filters: RTX denoiser, initialize only output channels
This reduces the initialization from 8 to the actual number of output
channels.
2021-04-25 09:24:07 -07:00
Richard Stanway
64c353c019 obs-filters: Initialize NVIDIA AFX in a thread
Initializing NVAFX is slow as it has to load large models and can cause
significant impact to OBS' startup time. This moves NVAFX initialization
into a separate thread. NVAFX does not appear to be reentrant across
threads, hence a global mutex is also used to avoid reentrancy issues.

The downside of this change is that the first few seconds of audio after
adding the filter or starting OBS will not be filtered, but this is
unlikely to cause any real-world issues.
2021-04-25 09:24:07 -07:00
jpark37
92eb756dab obs-filters: Increase luma key precision 2021-04-13 12:43:25 -07:00
jpark37
7bcd0d25cf obs-filters: Increase brightness precision
Necessary for adjusting colors near black.
2021-04-13 04:48:36 -07:00
jpark37
54656af340 obs-filters: Add color settings to correction v2
Restore color tint/overlay functionality, but with separate controls for
tinting (multiply) and overlay (add).
2021-04-09 06:45:13 -07:00
pkv
38d17acdbb obs-filters: Code cleanup for RTX denoiser
This minor code cleanup commit does the following:
- sets defaults intensity of RTX denoiser to max.
- adds an initialization check of nvafx.
- splits nvafx initialization from channel allocation for better
readibility of the code.
- moves the intensity update from the filter_audio process function
to the plugin update function.
- logs the error code in case nvafx returns an error when running.
(useful for devs; I haven't translated the error codes which are
available in the sdk).
2021-04-05 03:11:51 -07:00
pkv
b46e9bba85 obs-filters: Fix initialization of RTX denoiser
This fixes issue #4441.
The issue occurs when adding the noise suppression filter for the
first time. Rnnoise or speex are the default noise suppression
methods. Line 344 returns which prevents initialization and
allocation for nvafx (rtx denoiser).
With the fix, initialization of nvafx occurs when swapping methods.
2021-04-05 03:11:51 -07:00
jpark37
593835c227 obs-filters: Perform chroma key in nonlinear space
Don't want to deal with regressions from using linear space right now.
2021-04-04 00:58:38 -07:00
jpark37
185df01a96 obs-filters: Use new pattern for SRGB support 2021-04-04 00:58:38 -07:00
Richard Stanway
db7daa6eaf obs-filters: Simplify NVAFX SDK path lookup 2021-03-16 20:34:15 +01:00
Richard Stanway
d8a434bcc8 obs-filters: Minor code cleanup
Remove some unused variables, fix const qualifier and remove printfs.
2021-03-16 20:34:15 +01:00
pkv
54892b27db obs-filters: Add RTX denoiser
This adds RTX denoiser filter to be used with RTX GPUs.
(from Nvidia Audio Effects SDK)
2021-03-13 12:17:11 -08:00
jpark37
0e803c4443 obs-filters: Fix unused parameters 2021-01-29 21:50:32 -08:00
jpark37
b460f025ed obs-filters: Fix pow arguments
GLSL does not auto-promote float to vector where HLSL does.
2021-01-23 01:53:11 -08:00