GraphicsPath.Warp メソッド (PointF[], RectangleF)
アセンブリ: System.Drawing (system.drawing.dll 内)

Dim instance As GraphicsPath Dim destPoints As PointF() Dim srcRect As RectangleF instance.Warp(destPoints, srcRect)


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 によってサポートされていないバージョンがあります。サポートされているバージョンについては、「システム要件」を参照してください。


GraphicsPath.Warp メソッド (PointF[], RectangleF, Matrix, WarpMode, Single)
アセンブリ: System.Drawing (system.drawing.dll 内)

Public Sub Warp ( _ destPoints As PointF(), _ srcRect As RectangleF, _ matrix As Matrix, _ warpMode As WarpMode, _ flatness As Single _ )
Dim instance As GraphicsPath Dim destPoints As PointF() Dim srcRect As RectangleF Dim matrix As Matrix Dim warpMode As WarpMode Dim flatness As Single instance.Warp(destPoints, srcRect, matrix, warpMode, flatness)
public void Warp ( PointF[] destPoints, RectangleF srcRect, Matrix matrix, WarpMode warpMode, float flatness )
public: void Warp ( array<PointF>^ destPoints, RectangleF srcRect, Matrix^ matrix, WarpMode warpMode, float flatness )
public void Warp ( PointF[] destPoints, RectangleF srcRect, Matrix matrix, WarpMode warpMode, float flatness )
public function Warp ( destPoints : PointF[], srcRect : RectangleF, matrix : Matrix, warpMode : WarpMode, flatness : float )

次のコード例は、Windows フォームでの使用を意図してデザインされており、OnPaint イベント オブジェクトである PaintEventArgse が必要です。このコードは次のアクションを実行します。
Public Sub WarpExample(ByVal e As PaintEventArgs) ' Create a path and add a rectangle. Dim myPath As New GraphicsPath Dim srcRect As New RectangleF(0, 0, 100, 200) myPath.AddRectangle(srcRect) ' Draw the source path (rectangle)to the screen. e.Graphics.DrawPath(Pens.Black, myPath) ' Create a destination for the warped rectangle. Dim point1 As New PointF(200, 200) Dim point2 As New PointF(400, 250) Dim point3 As New PointF(220, 400) Dim destPoints As PointF() = {point1, point2, point3} ' Create a translation matrix. Dim translateMatrix As New Matrix translateMatrix.Translate(100, 0) ' Warp the source path (rectangle). myPath.Warp(destPoints, srcRect, translateMatrix, _ WarpMode.Perspective, 0.5F) ' Draw the warped path (rectangle) to the screen. e.Graphics.DrawPath(New Pen(Color.Red), myPath) End Sub
private void WarpExample(PaintEventArgs e) { // Create a path and add a rectangle. GraphicsPath myPath = new GraphicsPath(); RectangleF srcRect = new RectangleF(0, 0, 100, 200); myPath.AddRectangle(srcRect); // Draw the source path (rectangle)to the screen. e.Graphics.DrawPath(Pens.Black, myPath); // Create a destination for the warped rectangle. PointF point1 = new PointF(200, 200); PointF point2 = new PointF(400, 250); PointF point3 = new PointF(220, 400); PointF[] destPoints = {point1, point2, point3}; // Create a translation matrix. Matrix translateMatrix = new Matrix(); translateMatrix.Translate(100, 0); // Warp the source path (rectangle). myPath.Warp(destPoints, srcRect, translateMatrix, WarpMode.Perspective, 0.5f); // Draw the warped path (rectangle) to the screen. e.Graphics.DrawPath(new Pen(Color.Red), myPath); }
private: void WarpExample( PaintEventArgs^ e ) { // Create a path and add a rectangle. GraphicsPath^ myPath = gcnew GraphicsPath; RectangleF srcRect = RectangleF(0,0,100,200); myPath->AddRectangle( srcRect ); // Draw the source path (rectangle)to the screen. e->Graphics->DrawPath( Pens::Black, myPath ); // Create a destination for the warped rectangle. PointF point1 = PointF(200,200); PointF point2 = PointF(400,250); PointF point3 = PointF(220,400); array<PointF>^ destPoints = {point1,point2,point3}; // Create a translation matrix. Matrix^ translateMatrix = gcnew Matrix; translateMatrix->Translate( 100, 0 ); // Warp the source path (rectangle). myPath->Warp( destPoints, srcRect, translateMatrix, WarpMode::Perspective, 0.5f ); // Draw the warped path (rectangle) to the screen. e->Graphics->DrawPath( gcnew Pen( Color::Red ), myPath ); }
private void WarpExample(PaintEventArgs e) { // Create a path and add a rectangle. GraphicsPath myPath = new GraphicsPath(); RectangleF srcRect = new RectangleF(0, 0, 100, 200); myPath.AddRectangle(srcRect); // Draw the source path (rectangle)to the screen. e.get_Graphics().DrawPath(Pens.get_Black(), myPath); // Create a destination for the warped rectangle. PointF point1 = new PointF(200, 200); PointF point2 = new PointF(400, 250); PointF point3 = new PointF(220, 400); PointF destPoints[] = { point1, point2, point3 }; // Create a translation matrix. Matrix translateMatrix = new Matrix(); translateMatrix.Translate(100, 0); // Warp the source path (rectangle). myPath.Warp(destPoints, srcRect, translateMatrix, WarpMode.Perspective, 0.5F); // Draw the warped path (rectangle) to the screen. e.get_Graphics().DrawPath(new Pen(Color.get_Red()), myPath); } //WarpExample

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 によってサポートされていないバージョンがあります。サポートされているバージョンについては、「システム要件」を参照してください。


GraphicsPath.Warp メソッド (PointF[], RectangleF, Matrix)
アセンブリ: System.Drawing (system.drawing.dll 内)

Dim instance As GraphicsPath Dim destPoints As PointF() Dim srcRect As RectangleF Dim matrix As Matrix instance.Warp(destPoints, srcRect, matrix)


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 によってサポートされていないバージョンがあります。サポートされているバージョンについては、「システム要件」を参照してください。


GraphicsPath.Warp メソッド

名前 | 説明 |
---|---|
GraphicsPath.Warp (PointF[], RectangleF) | GraphicsPath に、四角形と平行四辺形によって定義されたワープ変換を適用します。 |
GraphicsPath.Warp (PointF[], RectangleF, Matrix) | GraphicsPath に、四角形と平行四辺形によって定義されたワープ変換を適用します。 |
GraphicsPath.Warp (PointF[], RectangleF, Matrix, WarpMode) | GraphicsPath に、四角形と平行四辺形によって定義されたワープ変換を適用します。 |
GraphicsPath.Warp (PointF[], RectangleF, Matrix, WarpMode, Single) | GraphicsPath に、四角形と平行四辺形によって定義されたワープ変換を適用します。 |

GraphicsPath.Warp メソッド (PointF[], RectangleF, Matrix, WarpMode)
アセンブリ: System.Drawing (system.drawing.dll 内)

Public Sub Warp ( _ destPoints As PointF(), _ srcRect As RectangleF, _ matrix As Matrix, _ warpMode As WarpMode _ )
Dim instance As GraphicsPath Dim destPoints As PointF() Dim srcRect As RectangleF Dim matrix As Matrix Dim warpMode As WarpMode instance.Warp(destPoints, srcRect, matrix, warpMode)
public: void Warp ( array<PointF>^ destPoints, RectangleF srcRect, Matrix^ matrix, WarpMode warpMode )
public function Warp ( destPoints : PointF[], srcRect : RectangleF, matrix : Matrix, warpMode : WarpMode )


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 によってサポートされていないバージョンがあります。サポートされているバージョンについては、「システム要件」を参照してください。


- GraphicsPath.Warpのページへのリンク