MCPcopy Create free account
hub / github.com/GPUOpen-Effects/GeometryFX / HandleOption

Function HandleOption

amd_geometryfx_sample/src/GeometryFX_Sample.cpp:132–144  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

130
131template <typename T, typename F>
132bool HandleOption(
133 const std::map<std::string, std::string> &options, const char *name, T &variable, F handler)
134{
135 if (options.find(name) != options.end())
136 {
137 variable = handler(options.find(name)->second);
138 return true;
139 }
140 else
141 {
142 return false;
143 }
144}
145
146template <typename T>
147bool HandleOption(const std::map<std::string, std::string> &options, const char *name, T &variable)

Callers 1

SetupMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected