2015-03-21 18:22:03 -07:00
|
|
|
#include <obs-module.h>
|
|
|
|
|
|
|
|
OBS_DECLARE_MODULE()
|
|
|
|
OBS_MODULE_USE_DEFAULT_LOCALE("obs-filters", "en-US")
|
2018-09-11 01:51:38 -07:00
|
|
|
MODULE_EXPORT const char *obs_module_description(void)
|
|
|
|
{
|
|
|
|
return "OBS core filters";
|
|
|
|
}
|
2015-03-21 18:22:03 -07:00
|
|
|
|
2015-03-21 18:27:09 -07:00
|
|
|
extern struct obs_source_info mask_filter;
|
2021-01-16 20:46:09 -08:00
|
|
|
extern struct obs_source_info mask_filter_v2;
|
2015-03-21 18:32:06 -07:00
|
|
|
extern struct obs_source_info crop_filter;
|
2015-06-26 05:31:30 -07:00
|
|
|
extern struct obs_source_info gain_filter;
|
2015-03-21 18:34:29 -07:00
|
|
|
extern struct obs_source_info color_filter;
|
2021-01-16 20:45:02 -08:00
|
|
|
extern struct obs_source_info color_filter_v2;
|
2016-06-29 04:18:34 -07:00
|
|
|
extern struct obs_source_info scale_filter;
|
2015-06-21 01:13:30 -07:00
|
|
|
extern struct obs_source_info scroll_filter;
|
2017-05-16 17:29:26 -07:00
|
|
|
extern struct obs_source_info gpu_delay_filter;
|
2015-03-21 18:38:01 -07:00
|
|
|
extern struct obs_source_info color_key_filter;
|
2021-01-16 20:45:13 -08:00
|
|
|
extern struct obs_source_info color_key_filter_v2;
|
2017-01-04 17:37:38 +01:00
|
|
|
extern struct obs_source_info color_grade_filter;
|
2015-05-01 00:08:10 -07:00
|
|
|
extern struct obs_source_info sharpness_filter;
|
2021-01-19 15:48:47 -08:00
|
|
|
extern struct obs_source_info sharpness_filter_v2;
|
2015-03-21 18:36:48 -07:00
|
|
|
extern struct obs_source_info chroma_key_filter;
|
2021-01-16 20:44:46 -08:00
|
|
|
extern struct obs_source_info chroma_key_filter_v2;
|
2015-03-21 18:22:03 -07:00
|
|
|
extern struct obs_source_info async_delay_filter;
|
2022-03-16 23:10:42 +01:00
|
|
|
#if defined(HAS_NOISEREDUCTION)
|
2016-07-25 19:48:17 -07:00
|
|
|
extern struct obs_source_info noise_suppress_filter;
|
2020-07-11 05:02:06 +02:00
|
|
|
extern struct obs_source_info noise_suppress_filter_v2;
|
2021-08-23 22:07:36 -07:00
|
|
|
extern bool load_nvafx(void);
|
|
|
|
extern void unload_nvafx(void);
|
2016-07-25 19:48:17 -07:00
|
|
|
#endif
|
2018-09-13 02:49:21 -07:00
|
|
|
extern struct obs_source_info invert_polarity_filter;
|
2015-06-19 21:51:40 -07:00
|
|
|
extern struct obs_source_info noise_gate_filter;
|
2017-02-15 20:36:50 -05:00
|
|
|
extern struct obs_source_info compressor_filter;
|
2018-11-28 02:23:03 +01:00
|
|
|
extern struct obs_source_info limiter_filter;
|
2018-11-30 02:56:19 +01:00
|
|
|
extern struct obs_source_info expander_filter;
|
2019-02-24 01:03:09 -06:00
|
|
|
extern struct obs_source_info luma_key_filter;
|
2021-01-16 20:45:24 -08:00
|
|
|
extern struct obs_source_info luma_key_filter_v2;
|
2021-02-01 02:19:56 +01:00
|
|
|
#ifdef LIBNVVFX_ENABLED
|
|
|
|
extern struct obs_source_info nvidia_greenscreen_filter_info;
|
|
|
|
extern bool load_nvvfx(void);
|
|
|
|
extern void unload_nvvfx(void);
|
|
|
|
#endif
|
2015-03-21 18:22:03 -07:00
|
|
|
|
|
|
|
bool obs_module_load(void)
|
|
|
|
{
|
2015-03-21 18:27:09 -07:00
|
|
|
obs_register_source(&mask_filter);
|
2021-01-16 20:46:09 -08:00
|
|
|
obs_register_source(&mask_filter_v2);
|
2015-03-21 18:32:06 -07:00
|
|
|
obs_register_source(&crop_filter);
|
2015-06-26 05:31:30 -07:00
|
|
|
obs_register_source(&gain_filter);
|
2015-03-21 18:34:29 -07:00
|
|
|
obs_register_source(&color_filter);
|
2021-01-16 20:45:02 -08:00
|
|
|
obs_register_source(&color_filter_v2);
|
2016-06-29 04:18:34 -07:00
|
|
|
obs_register_source(&scale_filter);
|
2015-06-21 01:13:30 -07:00
|
|
|
obs_register_source(&scroll_filter);
|
2017-05-16 17:29:26 -07:00
|
|
|
obs_register_source(&gpu_delay_filter);
|
2015-03-21 18:38:01 -07:00
|
|
|
obs_register_source(&color_key_filter);
|
2021-01-16 20:45:13 -08:00
|
|
|
obs_register_source(&color_key_filter_v2);
|
2017-01-04 17:37:38 +01:00
|
|
|
obs_register_source(&color_grade_filter);
|
2015-05-01 00:08:10 -07:00
|
|
|
obs_register_source(&sharpness_filter);
|
2021-01-19 15:48:47 -08:00
|
|
|
obs_register_source(&sharpness_filter_v2);
|
2015-03-21 18:36:48 -07:00
|
|
|
obs_register_source(&chroma_key_filter);
|
2021-01-16 20:44:46 -08:00
|
|
|
obs_register_source(&chroma_key_filter_v2);
|
2015-03-21 18:22:03 -07:00
|
|
|
obs_register_source(&async_delay_filter);
|
2022-03-16 23:10:42 +01:00
|
|
|
#if defined(HAS_NOISEREDUCTION)
|
2020-10-13 00:54:00 +02:00
|
|
|
#ifdef LIBNVAFX_ENABLED
|
|
|
|
/* load nvidia audio fx dll */
|
2021-03-15 19:33:31 +01:00
|
|
|
load_nvafx();
|
2020-10-13 00:54:00 +02:00
|
|
|
#endif
|
2016-07-25 19:48:17 -07:00
|
|
|
obs_register_source(&noise_suppress_filter);
|
2020-07-11 05:02:06 +02:00
|
|
|
obs_register_source(&noise_suppress_filter_v2);
|
2016-07-25 19:48:17 -07:00
|
|
|
#endif
|
2018-09-13 02:49:21 -07:00
|
|
|
obs_register_source(&invert_polarity_filter);
|
2015-06-19 21:51:40 -07:00
|
|
|
obs_register_source(&noise_gate_filter);
|
2017-02-15 20:36:50 -05:00
|
|
|
obs_register_source(&compressor_filter);
|
2018-11-28 02:23:03 +01:00
|
|
|
obs_register_source(&limiter_filter);
|
2018-11-30 02:56:19 +01:00
|
|
|
obs_register_source(&expander_filter);
|
2019-02-24 01:03:09 -06:00
|
|
|
obs_register_source(&luma_key_filter);
|
2021-01-16 20:45:24 -08:00
|
|
|
obs_register_source(&luma_key_filter_v2);
|
2021-02-01 02:19:56 +01:00
|
|
|
#ifdef LIBNVVFX_ENABLED
|
|
|
|
if (load_nvvfx())
|
|
|
|
obs_register_source(&nvidia_greenscreen_filter_info);
|
|
|
|
#endif
|
2015-03-21 18:22:03 -07:00
|
|
|
return true;
|
|
|
|
}
|
2020-10-13 00:54:00 +02:00
|
|
|
|
|
|
|
void obs_module_unload(void)
|
|
|
|
{
|
2021-02-01 02:19:56 +01:00
|
|
|
#ifdef LIBNVAFX_ENABLED
|
2021-08-23 22:07:36 -07:00
|
|
|
unload_nvafx();
|
2020-10-13 00:54:00 +02:00
|
|
|
#endif
|
2021-02-01 02:19:56 +01:00
|
|
|
#ifdef LIBNVVFX_ENABLED
|
|
|
|
unload_nvvfx();
|
|
|
|
#endif
|
|
|
|
}
|