SwRasterizer: Corrected the light LUT lookups.
This commit is contained in:
parent
80b6fc592e
commit
f2d4d5c219
2 changed files with 48 additions and 33 deletions
|
@ -30,6 +30,11 @@ public:
|
|||
return {xyz * other.w + other.xyz * w + Cross(xyz, other.xyz),
|
||||
w * other.w - Dot(xyz, other.xyz)};
|
||||
}
|
||||
|
||||
Quaternion<T> Normalized() const {
|
||||
T length = std::sqrt(xyz.Length2() + w * w);
|
||||
return {xyz / length, w / length};
|
||||
}
|
||||
};
|
||||
|
||||
template <typename T>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue