mirror of https://github.com/AxioDL/boo.git
macOS build fixes
This commit is contained in:
parent
9d91cd459e
commit
a832504456
|
@ -1,5 +1,6 @@
|
||||||
cmake_minimum_required(VERSION 3.10 FATAL_ERROR) # because of c++17
|
cmake_minimum_required(VERSION 3.10 FATAL_ERROR) # because of c++17
|
||||||
project(boo)
|
project(boo)
|
||||||
|
cmake_policy(SET CMP0074 NEW)
|
||||||
|
|
||||||
set(CMAKE_CXX_STANDARD 17)
|
set(CMAKE_CXX_STANDARD 17)
|
||||||
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
||||||
|
@ -21,6 +22,9 @@ if (IPP_FOUND)
|
||||||
include_directories(${IPP_INCLUDE_DIRS})
|
include_directories(${IPP_INCLUDE_DIRS})
|
||||||
list(APPEND _BOO_SYS_INCLUDES ${IPP_INCLUDE_DIRS})
|
list(APPEND _BOO_SYS_INCLUDES ${IPP_INCLUDE_DIRS})
|
||||||
list(APPEND _BOO_SYS_LIBS ${IPP_LIBRARIES})
|
list(APPEND _BOO_SYS_LIBS ${IPP_LIBRARIES})
|
||||||
|
message(STATUS "Building with IPP support")
|
||||||
|
else()
|
||||||
|
message(WARNING "IPP not found; skipping support")
|
||||||
endif ()
|
endif ()
|
||||||
|
|
||||||
set(WITH_LSR_BINDINGS OFF)
|
set(WITH_LSR_BINDINGS OFF)
|
||||||
|
|
|
@ -2,6 +2,7 @@
|
||||||
# Licence for this file: LGPL v2.1 See LICENCE for details.
|
# Licence for this file: LGPL v2.1 See LICENCE for details.
|
||||||
|
|
||||||
cmake_minimum_required (VERSION 2.8 FATAL_ERROR)
|
cmake_minimum_required (VERSION 2.8 FATAL_ERROR)
|
||||||
|
cmake_policy(SET CMP0075 OLD)
|
||||||
|
|
||||||
#project (soxr C)
|
#project (soxr C)
|
||||||
#set (DESCRIPTION_SUMMARY "High quality, one-dimensional sample-rate conversion library")
|
#set (DESCRIPTION_SUMMARY "High quality, one-dimensional sample-rate conversion library")
|
||||||
|
|
|
@ -447,8 +447,6 @@ struct TestApplicationCallback : IApplicationCallback
|
||||||
#elif BOO_HAS_METAL
|
#elif BOO_HAS_METAL
|
||||||
if (plat == IGraphicsDataFactory::Platform::Metal)
|
if (plat == IGraphicsDataFactory::Platform::Metal)
|
||||||
{
|
{
|
||||||
MetalDataFactory::Context& metalF = dynamic_cast<MetalDataFactory::Context&>(ctx);
|
|
||||||
|
|
||||||
static const char* VS =
|
static const char* VS =
|
||||||
"#include <metal_stdlib>\n"
|
"#include <metal_stdlib>\n"
|
||||||
"using namespace metal;\n"
|
"using namespace metal;\n"
|
||||||
|
@ -473,9 +471,11 @@ struct TestApplicationCallback : IApplicationCallback
|
||||||
" return tex.sample(samp, d.out_uv);\n"
|
" return tex.sample(samp, d.out_uv);\n"
|
||||||
"}\n";
|
"}\n";
|
||||||
|
|
||||||
pipeline = metalF.newShaderPipeline(VS, FS, nullptr, nullptr, vfmt,
|
auto vertexMetal = MetalDataFactory::CompileMetal(VS, PipelineStage::Vertex);
|
||||||
BlendFactor::One, BlendFactor::Zero, Primitive::TriStrips,
|
auto vertexShader = ctx.newShaderStage(vertexMetal, PipelineStage::Vertex);
|
||||||
boo::ZTest::LEqual, true, true, true, boo::CullMode::None);
|
auto fragmentMetal = MetalDataFactory::CompileMetal(FS, PipelineStage::Fragment);
|
||||||
|
auto fragmentShader = ctx.newShaderStage(fragmentMetal, PipelineStage::Fragment);
|
||||||
|
pipeline = ctx.newShaderPipeline(vertexShader, fragmentShader, descs, info);
|
||||||
} else
|
} else
|
||||||
#endif
|
#endif
|
||||||
{}
|
{}
|
||||||
|
|
Loading…
Reference in New Issue