src/gldraw.cpp

changeset 519
63135a8abd41
parent 516
d3373bc7ca3b
child 520
37d5da2f188e
equal deleted inserted replaced
518:623c01862eb8 519:63135a8abd41
496 vertex transformed; 496 vertex transformed;
497 transformed[X] = (m[0] * x) + (m[1] * y) + (m[2] * z) + m[3]; 497 transformed[X] = (m[0] * x) + (m[1] * y) + (m[2] * z) + m[3];
498 transformed[Y] = (m[4] * x) + (m[5] * y) + (m[6] * z) + m[7]; 498 transformed[Y] = (m[4] * x) + (m[5] * y) + (m[6] * z) + m[7];
499 transformed[Z] = (m[8] * x) + (m[9] * y) + (m[10] * z) + m[11]; 499 transformed[Z] = (m[8] * x) + (m[9] * y) + (m[10] * z) + m[11];
500 500
501 double rx = ( ( (transformed[axisX] * negXFac) + m_virtWidth + m_panX) * m_width) / (2 * m_virtWidth); 501 double rx = (((transformed[axisX] * negXFac) + m_virtWidth + m_panX) * m_width) / (2 * m_virtWidth);
502 double ry = ( ( (transformed[axisY] * negYFac) - m_virtHeight + m_panY) * m_height) / (2 * m_virtHeight); 502 double ry = (((transformed[axisY] * negYFac) - m_virtHeight + m_panY) * m_height) / (2 * m_virtHeight);
503 503
504 return QPoint (rx, -ry); 504 return QPoint (rx, -ry);
505 } 505 }
506 506
507 // ============================================================================= 507 // =============================================================================

mercurial