Lire en anglais

Partager via


Matrix.RotateAt(Double, Double, Double) Méthode

Définition

Fait pivoter cette matrice par rapport au point spécifié.

C#
public void RotateAt (double angle, double centerX, double centerY);

Paramètres

angle
Double

L'angle, en degrés, selon lequel faire pivoter cette matrice.

centerX
Double

La coordonnée x du point par rapport auquel faire pivoter cette matrice.

centerY
Double

La coordonnée y du point par rapport auquel faire pivoter cette matrice.

Exemples

L’exemple suivant montre comment faire pivoter un Matrix point spécifié.

C#
private Matrix rotateAboutPointExample()
{
    
    // Creating a Matrix structure.
    Matrix myMatrix = new Matrix(5, 10, 15, 20, 25, 30);
    
    // Rotate the matrix 90 degrees about the point (100,100).
    // myMatrix becomes equal to (-10, 4, -20, 15, 170, 25).
    myMatrix.RotateAt(90, 100, 100);
    
    return myMatrix; 
}

S’applique à

Produit Versions
.NET Framework 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8
Windows Desktop 3.0, 3.1, 5, 6, 7