Commit fd256f83 authored by Sylvain Thery's avatar Sylvain Thery

frame reset slot

parent c65e7dbd
......@@ -366,6 +366,10 @@ public slots:
*/
void frameFromString(QString frame);
/**
* @brief reset the frame manipulator to its initial position
*/
void frameReset();
/*********************************************************
* SIGNALS
......
......@@ -456,6 +456,22 @@ void MapHandlerGen::frameFromString(QString frame)
frameModified();
}
void MapHandlerGen::frameReset()
{
GLdouble mat[16];
// Identity
for (int i = 0; i < 4; ++i)
for (int j = 0; j < 4; ++j)
if (i==j)
mat[i*4+j] = 1;
else
mat[i*4+j] = 0;
m_frame->setFromMatrix(mat);
frameModified();
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment