MCPcopy Create free account
hub / github.com/RenderKit/embree / string_to_Vec2f

Function string_to_Vec2f

common/sys/estring.cpp:16–22  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

14 std::string toUpperCase(const std::string& s) { std::string dst(s); std::transform(dst.begin(), dst.end(), dst.begin(), to_upper); return dst; }
15
16 Vec2f string_to_Vec2f ( std::string str )
17 {
18 size_t next = 0;
19 const float x = std::stof(str,&next); str = str.substr(next+1);
20 const float y = std::stof(str,&next);
21 return Vec2f(x,y);
22 }
23
24 Vec3f string_to_Vec3f ( std::string str )
25 {

Callers 1

parm_Vec2fMethod · 0.85

Calls 1

substrMethod · 0.80

Tested by

no test coverage detected