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

Function PatchStdlibFunctions

shadercompiler/EffectCompilerMetal.cpp:73–89  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

71}
72
73void PatchStdlibFunctions( ParserState& state )
74{
75 Symbol* symbol = state.GetSymbolTable().Lookup( MakeInlineString( "lerp" ) );
76 symbol->name = MakeInlineString( "mix" );
77
78 symbol = state.GetSymbolTable().Lookup( MakeInlineString( "frac" ) );
79 symbol->name = MakeInlineString( "fract" );
80
81 symbol = state.GetSymbolTable().Lookup( MakeInlineString( "ddx" ) );
82 symbol->name = MakeInlineString( "dfdx" );
83
84 symbol = state.GetSymbolTable().Lookup( MakeInlineString( "ddy" ) );
85 symbol->name = MakeInlineString( "dfdy" );
86
87 symbol = state.GetSymbolTable().Lookup( MakeInlineString( "atan2" ) );
88 symbol->name = MakeInlineString( "precise::atan2" );
89}
90
91void ReplaceFloatModulo( ParserState& state )
92{

Callers 1

CompileEffectMethod · 0.85

Calls 2

MakeInlineStringFunction · 0.85
LookupMethod · 0.80

Tested by

no test coverage detected