MCPcopy Create free account
hub / github.com/OpenStarbound/OpenStarbound / jsonToPolyD

Function jsonToPolyD

source/core/StarJsonExtra.cpp:242–249  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

240}
241
242PolyD jsonToPolyD(Json const& v) {
243 PolyD poly;
244
245 for (Json const& vertex : v.iterateArray())
246 poly.add(jsonToVec2D(vertex));
247
248 return fixInsideOutPoly(poly);
249}
250
251PolyF jsonToPolyF(Json const& v) {
252 PolyF poly;

Callers

nothing calls this directly

Calls 4

jsonToVec2DFunction · 0.85
fixInsideOutPolyFunction · 0.85
iterateArrayMethod · 0.80
addMethod · 0.45

Tested by

no test coverage detected