Changes

Jump to navigation Jump to search

Sead/Color4f

723 bytes added, 17:56, 15 November 2018
document setLerp
=== setLerp(sead::Color4f, sead::Color4f, float) ===
TODOLinearly interpolates between 2 Color4f values, with the float being the interpolation valueAn implementation looks something like this: void __fastcall sead::Color4f::setLerp(sead::Color4f *this, const sead::Color4f *start, const sead::Color4f *end, float interpolation) { if ( interpolation >= 0.0 ) { if ( interpolation > 1.0 ) interpolation = 1.0; } else { interpolation = 0.0; } this->alpha = start->alpha + (interpolation * (end->alpha - start->alpha)); this->red = start->red + (interpolation * (end->red - start->red)); this->green = start->green + (interpolation * (end->green - start->green)); this->blue = start->blue + (interpolation * (end->blue - start->blue)); }
=== setGammaCollection(sead::Color4f, float) ===
44
edits

Navigation menu