------------------------------------------------------------------------------
| 85 | |
| 86 | //------------------------------------------------------------------------------ |
| 87 | void vtkTransform2D::Rotate(double angle) |
| 88 | { |
| 89 | if (angle == 0.0) |
| 90 | { |
| 91 | return; |
| 92 | } |
| 93 | |
| 94 | // convert to radians |
| 95 | angle = vtkMath::RadiansFromDegrees(angle); |
| 96 | double c = cos(angle); |
| 97 | double s = sin(angle); |
| 98 | |
| 99 | double matrix[3][3]; |
| 100 | vtkMatrix3x3::Identity(*matrix); |
| 101 | matrix[0][0] = c; |
| 102 | matrix[0][1] = s; |
| 103 | matrix[1][0] = -s; |
| 104 | matrix[1][1] = c; |
| 105 | vtkMatrix3x3::Multiply3x3(this->Matrix->GetData(), *matrix, this->Matrix->GetData()); |
| 106 | this->Matrix->Modified(); |
| 107 | } |
| 108 | |
| 109 | //------------------------------------------------------------------------------ |
| 110 | void vtkTransform2D::Scale(double x, double y) |