mirror of
https://github.com/ClemensFischer/XAML-Map-Control.git
synced 2025-12-06 07:12:04 +01:00
Version 4.7.0: Added UWP Vector class
This commit is contained in:
parent
5ae3f4083e
commit
05cf3e7d3d
|
|
@ -15,11 +15,6 @@ namespace MapControl
|
|||
public double OffsetX { get; set; }
|
||||
public double OffsetY { get; set; }
|
||||
|
||||
public static implicit operator Windows.UI.Xaml.Media.Matrix(Matrix m)
|
||||
{
|
||||
return new Windows.UI.Xaml.Media.Matrix(m.M11, m.M12, m.M21, m.M22, m.OffsetX, m.OffsetY);
|
||||
}
|
||||
|
||||
public Matrix(double m11, double m12, double m21, double m22, double offsetX, double offsetY)
|
||||
{
|
||||
M11 = m11;
|
||||
|
|
@ -30,6 +25,11 @@ namespace MapControl
|
|||
OffsetY = offsetY;
|
||||
}
|
||||
|
||||
public static implicit operator Windows.UI.Xaml.Media.Matrix(Matrix m)
|
||||
{
|
||||
return new Windows.UI.Xaml.Media.Matrix(m.M11, m.M12, m.M21, m.M22, m.OffsetX, m.OffsetY);
|
||||
}
|
||||
|
||||
public Point Transform(Point p)
|
||||
{
|
||||
return new Point(M11 * p.X + M12 * p.Y + OffsetX, M21 * p.X + M22 * p.Y + OffsetY);
|
||||
|
|
|
|||
Loading…
Reference in a new issue