public static ScaleAtPrepend ( Avalonia.Matrix matrix, double scaleX, double scaleY, double centerX, double centerY ) : Avalonia.Matrix | ||
matrix | Avalonia.Matrix | The matrix to prepend scale. |
scaleX | double | Scaling factor that is applied along the x-axis. |
scaleY | double | Scaling factor that is applied along the y-axis. |
centerX | double | The center X-coordinate of the scaling. |
centerY | double | The center Y-coordinate of the scaling. |
Résultat | Avalonia.Matrix |
public static Matrix ScaleAtPrepend(Matrix matrix, double scaleX, double scaleY, double centerX, double centerY)
{
return ScaleAt(scaleX, scaleY, centerX, centerY) * matrix;
}
public void ZoomTo(double zoom, Point point) { _matrix = MatrixHelper.ScaleAtPrepend(_matrix, zoom, zoom, point.X, point.Y); Invalidate(); }