@@ -45,7 +45,7 @@ option(MATERIALX_BUILD_GEN_MSL "Build the MSL shader generator back-end." ON)
4545option (MATERIALX_BUILD_GEN_SLANG "Build the Slang shader generator back-end." ON )
4646option (MATERIALX_BUILD_RENDER "Build the MaterialX Render modules." ON )
4747option (MATERIALX_BUILD_RENDER_PLATFORMS "Build platform-specific render modules for each shader generator." ON )
48- option (MATERIALX_RENDER_MSL_ONLY "On macOS, render with Metal Shading Language only (disables GLSL rendering )." OFF )
48+ option (MATERIALX_RENDER_MSL_ONLY "On macOS, use Metal Shading Language only for tests and viewer (skips GLSL render tests )." OFF )
4949option (MATERIALX_BUILD_OIIO "Build OpenImageIO support for MaterialXRender." OFF )
5050option (MATERIALX_BUILD_OCIO "Build OpenColorIO support for shader generators." OFF )
5151option (MATERIALX_BUILD_TESTS "Build unit tests." OFF )
@@ -121,7 +121,7 @@ if(MATERIALX_RENDER_MSL_ONLY)
121121 if (NOT MATERIALX_BUILD_GEN_MSL)
122122 message (FATAL_ERROR "MATERIALX_RENDER_MSL_ONLY requires MATERIALX_BUILD_GEN_MSL to be enabled" )
123123 endif ()
124- message (STATUS "MSL-only rendering mode enabled - GLSL rendering will be disabled " )
124+ message (STATUS "MSL-only testing mode enabled - MaterialXTest will not link MaterialXRenderGlsl " )
125125endif ()
126126
127127# All hardware shading languages currently depend on the GLSL shader generator.
@@ -515,11 +515,8 @@ if(MATERIALX_BUILD_RENDER)
515515 if (MATERIALX_BUILD_RENDER_PLATFORMS)
516516 set (MATERIALX_BUILD_RENDER_HW OFF )
517517 if (MATERIALX_BUILD_GEN_GLSL AND NOT MATERIALX_BUILD_APPLE_EMBEDDED)
518- # Skip GLSL rendering on macOS if MSL-only mode is enabled
519- if (NOT (APPLE AND MATERIALX_RENDER_MSL_ONLY))
520- set (MATERIALX_BUILD_RENDER_HW ON )
521- add_subdirectory (source /MaterialXRenderGlsl )
522- endif ()
518+ set (MATERIALX_BUILD_RENDER_HW ON )
519+ add_subdirectory (source /MaterialXRenderGlsl )
523520 endif ()
524521 if (MATERIALX_BUILD_GEN_MSL AND APPLE )
525522 set (MATERIALX_BUILD_RENDER_HW ON )
@@ -539,12 +536,7 @@ if(MATERIALX_BUILD_RENDER)
539536 add_subdirectory (source /MaterialXView )
540537 endif ()
541538 if (MATERIALX_BUILD_GRAPH_EDITOR)
542- # Graph Editor currently requires GLSL rendering
543- if (APPLE AND MATERIALX_RENDER_MSL_ONLY)
544- message (WARNING "MaterialXGraphEditor requires GLSL rendering and will not be built when MATERIALX_RENDER_MSL_ONLY is enabled on macOS" )
545- else ()
546- add_subdirectory (source /MaterialXGraphEditor )
547- endif ()
539+ add_subdirectory (source /MaterialXGraphEditor )
548540 endif ()
549541 if (MATERIALX_INSTALL_RESOURCES AND NOT SKBUILD)
550542 add_subdirectory (resources )
0 commit comments