diff --git a/cmake/module.cpp.in b/cmake/module.cpp.in index 07e7967..754e011 100644 --- a/cmake/module.cpp.in +++ b/cmake/module.cpp.in @@ -1,5 +1,12 @@ +#ifdef _MSC_VER +#pragma warning(push) +#pragma warning(disable : 4201) +#endif #include #include +#ifdef _MSC_VER +#pragma warning(pop) +#endif OBS_DECLARE_MODULE(); OBS_MODULE_AUTHOR("@PROJECT_AUTHORS@"); diff --git a/source/filters/filter-blur.cpp b/source/filters/filter-blur.cpp index 31089ad..efa027c 100644 --- a/source/filters/filter-blur.cpp +++ b/source/filters/filter-blur.cpp @@ -134,7 +134,7 @@ filter::blur::blur_factory::blur_factory() this->gaussian_widths.resize(max_kernel_size + 1); for (size_t w = 1; w <= max_kernel_size; w++) { for (double_t h = FLT_EPSILON; h <= w; h += search_density) { - if (util::math::gaussian(w, h) > search_threshold) { + if (util::math::gaussian(double_t(w), h) > search_threshold) { this->gaussian_widths[w] = h; break; } diff --git a/source/filters/filter-transform.cpp b/source/filters/filter-transform.cpp index cfab01a..e11e8df 100644 --- a/source/filters/filter-transform.cpp +++ b/source/filters/filter-transform.cpp @@ -334,7 +334,7 @@ filter::transform::transform_instance::transform_instance(obs_data_t* data, obs_ { m_source_rendertarget = std::make_shared(GS_RGBA, GS_ZS_NONE); m_shape_rendertarget = std::make_shared(GS_RGBA, GS_ZS_NONE); - m_vertex_buffer = std::make_shared(4u, 1u); + m_vertex_buffer = std::make_shared(uint32_t(4u), uint8_t(1u)); m_position = std::make_unique(); m_rotation = std::make_unique(); diff --git a/source/gfx/gfx-effect-source.cpp b/source/gfx/gfx-effect-source.cpp index eec012f..1219254 100644 --- a/source/gfx/gfx-effect-source.cpp +++ b/source/gfx/gfx-effect-source.cpp @@ -16,12 +16,12 @@ // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA #include "gfx-effect-source.hpp" -#include -#include -#include "strings.hpp" #include #include #include +#include +#include +#include "strings.hpp" // OBS #ifdef _MSC_VER @@ -96,8 +96,7 @@ bool gfx::effect_source::property_texture_type_modified(void* priv, obs_properti return true; } -bool gfx::effect_source::property_texture_input_modified(void*, obs_properties_t*, obs_property_t*, - obs_data_t*) +bool gfx::effect_source::property_texture_input_modified(void*, obs_properties_t*, obs_property_t*, obs_data_t*) { return false; } diff --git a/source/obs/gs/gs-mipmapper.cpp b/source/obs/gs/gs-mipmapper.cpp index 998cba0..1dc1e49 100644 --- a/source/obs/gs/gs-mipmapper.cpp +++ b/source/obs/gs/gs-mipmapper.cpp @@ -50,7 +50,14 @@ struct graphics_subsystem { #if defined(WIN32) || defined(WIN64) #include #include +#ifdef _MSC_VER +#pragma warning(push) +#pragma warning(disable : 4201) +#endif #include +#ifdef _MSC_VER +#pragma warning(pop) +#endif // Slaughtered copy of d3d11-subsystem.hpp gs_device. We only need up to device and context, the rest is "unknown" to us. struct gs_d3d11_device { @@ -71,7 +78,7 @@ gs::mipmapper::~mipmapper() gs::mipmapper::mipmapper() { - vertex_buffer = std::make_unique(6, 1); + vertex_buffer = std::make_unique(uint32_t(6u), uint8_t(1u)); auto v0 = vertex_buffer->at(0); v0.position->x = 0; v0.position->y = 0;