Graphics.TransformPoints メソッド (CoordinateSpace, CoordinateSpace, Point[])
アセンブリ: System.Drawing (system.drawing.dll 内)

Public Sub TransformPoints ( _ destSpace As CoordinateSpace, _ srcSpace As CoordinateSpace, _ pts As Point() _ )
Dim instance As Graphics Dim destSpace As CoordinateSpace Dim srcSpace As CoordinateSpace Dim pts As Point() instance.TransformPoints(destSpace, srcSpace, pts)
public void TransformPoints ( CoordinateSpace destSpace, CoordinateSpace srcSpace, Point[] pts )
public: void TransformPoints ( CoordinateSpace destSpace, CoordinateSpace srcSpace, array<Point>^ pts )
public void TransformPoints ( CoordinateSpace destSpace, CoordinateSpace srcSpace, Point[] pts )
public function TransformPoints ( destSpace : CoordinateSpace, srcSpace : CoordinateSpace, pts : Point[] )

次の例は、Windows フォームでの使用を意図してデザインされており、Paint イベント ハンドラのパラメータである PaintEventArgse が必要です。このコードは次のアクションを実行します。
Public Sub TransformPointsPoint(ByVal e As PaintEventArgs) ' Create array of two points. Dim points As Point() = {New Point(0, 0), New Point(100, 50)} ' Draw line connecting two untransformed points. e.Graphics.DrawLine(New Pen(Color.Blue, 3), points(0), points(1)) ' Set world transformation of Graphics object to translate. e.Graphics.TranslateTransform(40, 30) ' Transform points in array from world to page coordinates. e.Graphics.TransformPoints(CoordinateSpace.Page, _ CoordinateSpace.World, points) ' Reset world transformation. e.Graphics.ResetTransform() ' Draw line that connects transformed points. e.Graphics.DrawLine(New Pen(Color.Red, 3), points(0), points(1)) End Sub
public void TransformPointsPoint(PaintEventArgs e) { // Create array of two points. Point[] points = { new Point(0, 0), new Point(100, 50) }; // Draw line connecting two untransformed points. e.Graphics.DrawLine(new Pen(Color.Blue, 3), points[0], points[1]); // Set world transformation of Graphics object to translate. e.Graphics.TranslateTransform(40, 30); // Transform points in array from world to page coordinates. e.Graphics.TransformPoints(CoordinateSpace.Page, CoordinateSpace.World, points); // Reset world transformation. e.Graphics.ResetTransform(); // Draw line that connects transformed points. e.Graphics.DrawLine(new Pen(Color.Red, 3), points[0], points[1]); }

Windows 98, Windows 2000 SP4, Windows Millennium Edition, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition
開発プラットフォームの中には、.NET Framework によってサポートされていないバージョンがあります。サポートされているバージョンについては、「システム要件」を参照してください。


Graphics.TransformPoints メソッド (CoordinateSpace, CoordinateSpace, PointF[])
アセンブリ: System.Drawing (system.drawing.dll 内)

Public Sub TransformPoints ( _ destSpace As CoordinateSpace, _ srcSpace As CoordinateSpace, _ pts As PointF() _ )
Dim instance As Graphics Dim destSpace As CoordinateSpace Dim srcSpace As CoordinateSpace Dim pts As PointF() instance.TransformPoints(destSpace, srcSpace, pts)
public void TransformPoints ( CoordinateSpace destSpace, CoordinateSpace srcSpace, PointF[] pts )
public: void TransformPoints ( CoordinateSpace destSpace, CoordinateSpace srcSpace, array<PointF>^ pts )
public void TransformPoints ( CoordinateSpace destSpace, CoordinateSpace srcSpace, PointF[] pts )
public function TransformPoints ( destSpace : CoordinateSpace, srcSpace : CoordinateSpace, pts : PointF[] )

次の例は、Windows フォームでの使用を意図してデザインされており、Paint イベント ハンドラのパラメータである PaintEventArgse が必要です。このコードは次のアクションを実行します。
Public Sub TransformPointsPointF(ByVal e As PaintEventArgs) ' Create array of two points. Dim points As PointF() = {New PointF(0.0F, 0.0F), New PointF(100.0F, _ 50.0F)} ' Draw line connecting two untransformed points. e.Graphics.DrawLine(New Pen(Color.Blue, 3), points(0), points(1)) ' Set world transformation of Graphics object to translate. e.Graphics.TranslateTransform(40.0F, 30.0F) ' Transform points in array from world to page coordinates. e.Graphics.TransformPoints(CoordinateSpace.Page, _ CoordinateSpace.World, points) ' Reset world transformation. e.Graphics.ResetTransform() ' Draw line that connects transformed points. e.Graphics.DrawLine(New Pen(Color.Red, 3), points(0), points(1)) End Sub
public void TransformPointsPointF(PaintEventArgs e) { // Create array of two points. PointF[] points = { new PointF(0.0F, 0.0F), new PointF(100.0F, 50.0F) }; // Draw line connecting two untransformed points. e.Graphics.DrawLine(new Pen(Color.Blue, 3), points[0], points[1]); // Set world transformation of Graphics object to translate. e.Graphics.TranslateTransform(40.0F, 30.0F); // Transform points in array from world to page coordinates. e.Graphics.TransformPoints(CoordinateSpace.Page, CoordinateSpace.World, points); // Reset world transformation. e.Graphics.ResetTransform(); // Draw line that connects transformed points. e.Graphics.DrawLine(new Pen(Color.Red, 3), points[0], points[1]); }

Windows 98, Windows 2000 SP4, Windows Millennium Edition, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition
開発プラットフォームの中には、.NET Framework によってサポートされていないバージョンがあります。サポートされているバージョンについては、「システム要件」を参照してください。


Graphics.TransformPoints メソッド

名前 | 説明 |
---|---|
Graphics.TransformPoints (CoordinateSpace, CoordinateSpace, Point[]) | この Graphics の現在のワールド変換とページ変換を使用して、点の配列をある座標空間から別の座標空間に変換します。 |
Graphics.TransformPoints (CoordinateSpace, CoordinateSpace, PointF[]) | この Graphics の現在のワールド変換とページ変換を使用して、点の配列をある座標空間から別の座標空間に変換します。 |

Weblioに収録されているすべての辞書からGraphics.TransformPointsを検索する場合は、下記のリンクをクリックしてください。

- Graphics.TransformPointsのページへのリンク