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

Function TriColorFromVector

trinity/TriMath.cpp:245–255  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

243/////////////////////////////////////////////////////////////////////////////////////////
244
245Color* TriColorFromVector(
246 Color* c,
247 const Vector3* v,
248 float height )
249{
250 c->r = 0.5f * v->x + 0.5f;
251 c->g = 0.5f * v->y + 0.5f;
252 c->b = 0.5f * v->z + 0.5f;
253 c->a = height;
254 return c;
255}
256
257
258/////////////////////////////////////////////////////////////////////////////////////////

Callers 1

SetVectorMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected