MCPcopy Create free account
hub / github.com/carbonengine/trinity / MetalTool

Function MetalTool

shadercompiler/EffectCompilerMetal.cpp:4243–4263  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

4241};
4242
4243std::string MetalTool( const char* name )
4244{
4245 std::ostringstream cmd;
4246#ifdef _WIN32
4247 if( !g_metalToolsPath.empty() )
4248 {
4249 cmd << "\"" << g_metalToolsPath << "\\macos\\bin\\" << name << ".exe\"";
4250 }
4251 else
4252 {
4253 char programFiles[MAX_PATH] = { 0 };
4254 size_t programFilesSize;
4255 getenv_s( &programFilesSize, programFiles, "PROGRAMFILES" );
4256
4257 cmd << "\"" << programFiles << "\\Metal Developer Tools\\metal\\macos\\bin\\" << name << ".exe\"";
4258 }
4259#else
4260 cmd << "xcrun -sdk macosx " << name;
4261#endif
4262 return cmd.str();
4263}
4264
4265
4266// Implements a disgusting method of funding which shader parameters turn out to be unused by the shader

Callers 3

DetectUnusedArgumentsFunction · 0.70
CompileCodeFunction · 0.70
CreateMethod · 0.70

Calls 1

emptyMethod · 0.80

Tested by

no test coverage detected