kexVec4 kexVec4::operator|(const kexMatrix &mtx) { return kexVec4( mtx.vectors[1].x * y + mtx.vectors[2].x * z + mtx.vectors[0].x * x + mtx.vectors[3].x, mtx.vectors[1].y * y + mtx.vectors[2].y * z + mtx.vectors[0].y * x + mtx.vectors[3].y, mtx.vectors[1].z * y + mtx.vectors[2].z * z + mtx.vectors[0].z * x + mtx.vectors[3].z, mtx.vectors[1].w * y + mtx.vectors[2].w * z + mtx.vectors[0].w * x + mtx.vectors[3].w); }
kexVec4 kexLexer::GetVector4(void) { #ifdef SC_DEBUG SC_DebugPrintf("get vector4 (%s)\n", token); #endif float x, y, z, w; ExpectNextToken(TK_LBRACK); x = (float)GetFloat(); y = (float)GetFloat(); z = (float)GetFloat(); w = (float)GetFloat(); ExpectNextToken(TK_RBRACK); return kexVec4(x, y, z, w); }