Quaternion to Matrix using glm
<p>I am trying to convert quat in glm to mat4.</p>

<p>My code is :</p>

<pre><code>#include &lt;iostream&gt;
#include&lt;glm/glm.hpp&gt;
#include&lt;glm/gtc/quaternion.hpp&gt;
#include&lt;glm/common.hpp&gt;
using namespace std;


int main()
{
    glm::mat4 MyMatrix=glm::mat4();
    glm::quat myQuat;

    myQuat=glm::quat(0.707107,0.707107,0.00,0.000);
    glm::mat4 RotationMatrix = quaternion::toMat4(myQuat);

    for(int i=0;i&lt;4;++i)
    {
        for(int j=0;j&lt;4;++j)
        {
            cout&lt;&lt;RotationMatrix[i][j]&lt;&lt;" ";
        }
        cout&lt;&lt;"\n";
    }
    return 0;
}
</code></pre>

<p>When i run the program it shows the error "error: ‘quaternion’ has not been declared".</p>

<p>Can anyone help me with this?</p>