<a name="l1"></a><a href="/Wb/Kernel/KernelA.HH.HTML#l3599"><span class=cF4>CDC</span></a><span class=cF0>'s have a 4x4 matrix for rotating, scaling, skewing and shifting in 3
<a name="l5"></a>The matrix consists of ints that have been scaled 32 bits (</span><a href="/Wb/Adam/Gr/GrDC.HC.HTML#l4"><span class=cF4>GR_SCALE</span></a><span class=cF0>). See </span><span class=cF4>
<a name="l6"></a></span><a href="/Wb/Demo/Lectures/FixedPoint.HC.HTML#l1"><span class=cF4>::/Demo/Lectures/FixedPoint.HC</span></a><span class=cF0> to learn why.
<a name="l9"></a></span><a href="/Wb/Adam/Gr/GrMath.HC.HTML#l113"><span class=cF4>Mat4x4RotX</span></a><span class=cF0>(), </span><a href="/Wb/Adam/Gr/GrMath.HC.HTML#l127"><span class=cF4>Mat4x4RotY</span></a><span class=cF0>(), </span><a href="/Wb/Adam/Gr/GrMath.HC.HTML#l141"><span class=cF4>Mat4x4RotZ</span></a><span class=cF0>() and </span><a href="/Wb/Adam/Gr/GrMath.HC.HTML#l155"><span class=cF4>Mat4x4Scale</span></a><span class=cF0>() to rotate about axes
<a name="l10"></a>and scale. Combine them with </span><a href="/Wb/Adam/Gr/GrMath.HC.HTML#l80"><span class=cF4>Mat4x4MulMat4x4Equ</span></a><span class=cF0>()/</span><a href="/Wb/Adam/Gr/GrMath.HC.HTML#l96"><span class=cF4>Mat4x4MulMat4x4New</span></a><span class=cF0>() and
<a name="l11"></a>assign them to the </span><a href="/Wb/Kernel/KernelA.HH.HTML#l3599"><span class=cF4>CDC</span></a><span class=cF0>.</span><span class=cF2>dc</span><span class=cF0> with </span><a href="/Wb/Adam/Gr/GrDC.HC.HTML#l47"><span class=cF4>DCMat4x4Set</span></a><span class=cF0>(). See </span><a href="/Wb/Demo/Graphics/Box.HC.HTML#l1"><span class=cF4>::/Demo/Graphics/Box.HC</span></a><span class=cF0>.
<a name="l13"></a>You can rotate single points using </span><a href="/Wb/Adam/Gr/GrDC.HC.HTML#l6"><span class=cF4>Mat4x4MulXYZ</span></a><span class=cF0>().
<a name="l16"></a>(translations), into the matrix and </span><a href="/Wb/Adam/Gr/GrMath.HC.HTML#l80"><span class=cF4>Mat4x4MulMat4x4Equ</span></a><span class=cF0>/</span><a href="/Wb/Adam/Gr/GrMath.HC.HTML#l96"><span class=cF4>Mat4x4MulMat4x4New</span></a><span class=cF0> them
<a name="l20"></a>Finally, </span><a href="/Wb/Kernel/KernelA.HH.HTML#l3599"><span class=cF4>CDC</span></a><span class=cF0>'s have an </span><span class=cF2>x</span><span class=cF0>, </span><span class=cF2>y</span><span class=cF0> and </span><span class=cF2>z</span><span class=cF0> which is an additional shift (translation).
<a name="l22"></a>The transformation is implemented as a callback on the </span><a href="/Wb/Kernel/KernelA.HH.HTML#l3599"><span class=cF4>CDC</span></a><span class=cF0>'s </span><span class=cF2>transform()</span><span class=cF0> member.
<a name="l23"></a> The default </span><span class=cF2>transform()</span><span class=cF0> callback is </span><a href="/Wb/Adam/Gr/GrDC.HC.HTML#l15"><span class=cF4>DCTransform</span></a><span class=cF0>(). See </span><span class=cF4>
<a name="l24"></a></span><a href="/Wb/Demo/Games/Talons.HC.HTML#l1"><span class=cF4>::/Demo/Games/Talons.HC</span></a><span class=cF0> or </span><a href="/Wb/Demo/Games/CastleFrankenstein.HC.HTML#l1"><span class=cF4>::/Demo/Games/CastleFrankenstein.HC</span></a><span class=cF0> to see how to