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

Function ParsePlatform

shadercompiler/Platforms.h:79–96  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

77}
78
79inline Platform ParsePlatform( const char* name )
80{
81 for( int32_t i = 0; i < _PLATFORM_END; ++i )
82 {
83 if( IsValidPlatform( Platform( i ) ) )
84 {
85 if( strcmp( GetPlatformIdString( Platform( i ) ), name ) == 0 )
86 {
87 return Platform( i );
88 }
89 if( _stricmp( GetPlatformShortName( Platform( i ) ), name ) == 0 )
90 {
91 return Platform( i );
92 }
93 }
94 }
95 return PLATFORM_INVALID;
96}

Callers 1

GetPlatformFunction · 0.85

Calls 4

IsValidPlatformFunction · 0.85
GetPlatformIdStringFunction · 0.85
GetPlatformShortNameFunction · 0.85
PlatformEnum · 0.70

Tested by

no test coverage detected