texturebrush 平铺渲染_dotnet-api-docs.zh-cn

System.Drawing

1.0.5000.0

2.0.0.0

4.0.0.0

System.Drawing.Common

4.0.0.0

4.0.0.1

4.0.1.0

4.0.2.0

5.0.0.0

System.Drawing.Brush

类的每个属性都是 对象,这种对象使用图像来填充形状的内部。 此类不能被继承。

## Examples

下面的代码示例演示如何使用方法获取新位图 。 它还演示了 。

此示例旨在与 Windows 窗体一起使用。 创建一个包含名为 "Button2" 的按钮的窗体。 将代码粘贴到窗体中,并将 Button2_Click 方法与按钮的 `Click` 事件关联。

[!code-cpp[System.Drawing.ImageExample#2](~/samples/snippets/cpp/VS_Snippets_Winforms/System.Drawing.ImageExample/CPP/form1.cpp#2)]

[!code-csharp[System.Drawing.ImageExample#2](~/samples/snippets/csharp/VS_Snippets_Winforms/System.Drawing.ImageExample/CS/form1.cs#2)]

[!code-vb[System.Drawing.ImageExample#2](~/samples/snippets/visualbasic/VS_Snippets_Winforms/System.Drawing.ImageExample/VB/form1.vb#2)]

]]>

System.Drawing

4.0.0.0

初始化使用指定图像的新 对象。

Constructor

System.Drawing

1.0.5000.0

2.0.0.0

4.0.0.0

System.Drawing.Common

4.0.0.0

4.0.0.1

4.0.1.0

4.0.2.0

5.0.0.0

[System.Runtime.TargetedPatchingOptOut("Performance critical to inline this type of method across NGen image boundaries")]

[<System.Runtime.TargetedPatchingOptOut("Performance critical to inline this type of method across NGen image boundaries")>]

对象,此 对象使用它来填充其内部。

初始化使用指定图像的新 对象。

## Examples

下面的代码示例演示如何使用方法获取新位图 。 它还演示了 。

此示例旨在与 Windows 窗体一起使用。 创建一个包含名为 "Button2" 的按钮的窗体。 将代码粘贴到窗体中,并将 Button2_Click 方法与按钮的 `Click` 事件关联。

[!code-cpp[System.Drawing.ImageExample#2](~/samples/snippets/cpp/VS_Snippets_Winforms/System.Drawing.ImageExample/CPP/form1.cpp#2)]

[!code-csharp[System.Drawing.ImageExample#2](~/samples/snippets/csharp/VS_Snippets_Winforms/System.Drawing.ImageExample/CS/form1.cs#2)]

[!code-vb[System.Drawing.ImageExample#2](~/samples/snippets/visualbasic/VS_Snippets_Winforms/System.Drawing.ImageExample/VB/form1.vb#2)]

]]>

Constructor

System.Drawing

1.0.5000.0

2.0.0.0

4.0.0.0

System.Drawing.Common

4.0.0.0

4.0.0.1

4.0.1.0

4.0.2.0

5.0.0.0

对象,此 对象使用它来填充其内部。

一个 枚举,它指定此 对象的平铺方式。

初始化使用指定的图像和自动换行模式的新 对象。

To be added.

Constructor

System.Drawing

1.0.5000.0

2.0.0.0

4.0.0.0

System.Drawing.Common

4.0.0.0

4.0.0.1

4.0.1.0

4.0.2.0

5.0.0.0

[System.Runtime.TargetedPatchingOptOut("Performance critical to inline this type of method across NGen image boundaries")]

[<System.Runtime.TargetedPatchingOptOut("Performance critical to inline this type of method across NGen image boundaries")>]

对象,此 对象使用它来填充其内部。

一个 结构,它表示此 对象的边框。

初始化使用指定图像和边框的新 对象。

To be added.

Constructor

System.Drawing

1.0.5000.0

2.0.0.0

4.0.0.0

System.Drawing.Common

4.0.0.0

4.0.0.1

4.0.1.0

4.0.2.0

5.0.0.0

[System.Runtime.TargetedPatchingOptOut("Performance critical to inline this type of method across NGen image boundaries")]

[<System.Runtime.TargetedPatchingOptOut("Performance critical to inline this type of method across NGen image boundaries")>]

对象,此 对象使用它来填充其内部。

一个 结构,它表示此 对象的边框。

初始化使用指定图像和边框的新 对象。

To be added.

Constructor

System.Drawing

1.0.5000.0

2.0.0.0

4.0.0.0

System.Drawing.Common

4.0.0.0

4.0.0.1

4.0.1.0

4.0.2.0

5.0.0.0

对象,此 对象使用它来填充其内部。

一个 枚举,它指定此 对象的平铺方式。

一个 结构,它表示此 对象的边框。

初始化使用指定图像、自动换行模式和边框的新 对象。

To be added.

Constructor

System.Drawing

1.0.5000.0

2.0.0.0

4.0.0.0

System.Drawing.Common

4.0.0.0

4.0.0.1

4.0.1.0

4.0.2.0

5.0.0.0

对象,此 对象使用它来填充其内部。

一个 枚举,它指定此 对象的平铺方式。

一个 结构,它表示此 对象的边框。

初始化使用指定图像、自动换行模式和边框的新 对象。

To be added.

Constructor

System.Drawing

1.0.5000.0

2.0.0.0

4.0.0.0

System.Drawing.Common

4.0.0.0

4.0.0.1

4.0.1.0

4.0.2.0

5.0.0.0

对象,此 对象使用它来填充其内部。

一个 结构,它表示此 对象的边框。

一个 对象,它包含有关此 对象所使用的图像的附加信息。

初始化使用指定的图像、边框和图像特性的新 对象。

To be added.

Constructor

System.Drawing

1.0.5000.0

2.0.0.0

4.0.0.0

System.Drawing.Common

4.0.0.0

4.0.0.1

4.0.1.0

4.0.2.0

5.0.0.0

对象,此 对象使用它来填充其内部。

一个 结构,它表示此 对象的边框。

一个 对象,它包含有关此 对象所使用的图像的附加信息。

初始化使用指定的图像、边框和图像特性的新 对象。

To be added.

Method

System.Drawing

1.0.5000.0

2.0.0.0

4.0.0.0

System.Drawing.Common

4.0.0.0

4.0.0.1

4.0.1.0

4.0.2.0

5.0.0.0

System.Object

创建此 对象的一个精确副本。

此方法创建的作为 对象转换的 对象。

## Examples

下面的示例旨在与 Windows 窗体一起使用,并且它需要作为 `e` `Paint` 事件处理程序的参数。 该代码将创建一个 对象和该纹理画笔的精确副本,然后使用该副本在屏幕上填充一个矩形。

[!code-cpp[System.Drawing.ClassicTextureBrushExamples#1](~/samples/snippets/cpp/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/CPP/form1.cpp#1)]

[!code-csharp[System.Drawing.ClassicTextureBrushExamples#1](~/samples/snippets/csharp/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/CS/form1.cs#1)]

[!code-vb[System.Drawing.ClassicTextureBrushExamples#1](~/samples/snippets/visualbasic/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/VB/form1.vb#1)]

]]>

Property

System.Drawing

1.0.5000.0

2.0.0.0

4.0.0.0

System.Drawing.Common

4.0.0.0

4.0.0.1

4.0.1.0

4.0.2.0

5.0.0.0

System.Drawing.Image

获取与此 对象关联的 对象。

对象,它表示一种图像,此 对象就用该图像填充各种形状。

To be added.

System.Drawing

4.0.0.0

将表示此 对象的局部几何转换的 对象与指定的 对象按指定顺序相乘。

Method

System.Drawing

1.0.5000.0

2.0.0.0

4.0.0.0

System.Drawing.Common

4.0.0.0

4.0.0.1

4.0.1.0

4.0.2.0

5.0.0.0

[System.Runtime.TargetedPatchingOptOut("Performance critical to inline this type of method across NGen image boundaries")]

[<System.Runtime.TargetedPatchingOptOut("Performance critical to inline this type of method across NGen image boundaries")>]

System.Void

要乘以几何转换的 对象。

通过预先计算指定的 对象,将表示此 对象的局部几何转换的 对象与指定 对象相乘。

## Remarks

对象的转换矩阵 指定如何转换定义纹理的图像。 例如,如果变换矩阵指定了顺时针旋转90度,纹理图像将会顺时针旋转90度。

## Examples

下面的示例旨在与 Windows 窗体一起使用,并且它需要作为 `e` `Paint` 事件处理程序的参数。 此代码执行以下操作:

- 创建一个 对象。

- 创建一个新矩阵,该矩阵指定 x 方向上50个单位的平移。

- 将矩阵与纹理画笔的变换矩阵相乘。

- 使用纹理画笔填充矩形。

[!code-cpp[System.Drawing.ClassicTextureBrushExamples#2](~/samples/snippets/cpp/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/CPP/form1.cpp#2)]

[!code-csharp[System.Drawing.ClassicTextureBrushExamples#2](~/samples/snippets/csharp/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/CS/form1.cs#2)]

[!code-vb[System.Drawing.ClassicTextureBrushExamples#2](~/samples/snippets/visualbasic/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/VB/form1.vb#2)]

]]>

Method

System.Drawing

1.0.5000.0

2.0.0.0

4.0.0.0

System.Drawing.Common

4.0.0.0

4.0.0.1

4.0.1.0

4.0.2.0

5.0.0.0

System.Void

要乘以几何转换的 对象。

用于指定两个矩阵相乘的顺序的 枚举。

将表示此 对象的局部几何转换的 对象与指定的 对象按指定顺序相乘。

## Remarks

对象的转换矩阵 指定如何转换定义纹理的图像。 例如,如果变换矩阵指定了顺时针旋转90度,纹理图像将会顺时针旋转90度。

## Examples

下面的示例旨在与 Windows 窗体一起使用,并且它需要作为 `e` `Paint` 事件处理程序的参数。 此代码执行以下操作:

- 创建一个 对象。

- 创建一个新矩阵,该矩阵指定 x 方向上50个单位的平移。

- 将矩阵与纹理画笔的变换矩阵相乘。

- 使用纹理画笔填充矩形。

[!code-cpp[System.Drawing.ClassicTextureBrushExamples#3](~/samples/snippets/cpp/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/CPP/form1.cpp#3)]

[!code-csharp[System.Drawing.ClassicTextureBrushExamples#3](~/samples/snippets/csharp/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/CS/form1.cs#3)]

[!code-vb[System.Drawing.ClassicTextureBrushExamples#3](~/samples/snippets/visualbasic/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/VB/form1.vb#3)]

]]>

Method

System.Drawing

1.0.5000.0

2.0.0.0

4.0.0.0

System.Drawing.Common

4.0.0.0

4.0.0.1

4.0.1.0

4.0.2.0

5.0.0.0

System.Void

将此 对象的 属性重置为标识。

## Examples

下面的示例旨在与 Windows 窗体一起使用,并且它需要作为 `e` `Paint` 事件处理程序的参数。 此代码执行以下操作:

- 创建一个 对象。

- 将纹理图像旋转90度。

- 填充矩形。

- 将变换矩阵重置为标识。

- 填充第二个矩形。

[!code-cpp[System.Drawing.ClassicTextureBrushExamples#4](~/samples/snippets/cpp/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/CPP/form1.cpp#4)]

[!code-csharp[System.Drawing.ClassicTextureBrushExamples#4](~/samples/snippets/csharp/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/CS/form1.cs#4)]

[!code-vb[System.Drawing.ClassicTextureBrushExamples#4](~/samples/snippets/visualbasic/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/VB/form1.vb#4)]

]]>

System.Drawing

4.0.0.0

将 对象的局部几何转换旋转指定量。 此方法将旋转添加到转换前。

Method

System.Drawing

1.0.5000.0

2.0.0.0

4.0.0.0

System.Drawing.Common

4.0.0.0

4.0.0.1

4.0.1.0

4.0.2.0

5.0.0.0

[System.Runtime.TargetedPatchingOptOut("Performance critical to inline this type of method across NGen image boundaries")]

[<System.Runtime.TargetedPatchingOptOut("Performance critical to inline this type of method across NGen image boundaries")>]

System.Void

旋转角度。

将 对象的局部几何转换旋转指定量。 此方法将旋转添加到转换前。

## Examples

下面的示例旨在与 Windows 窗体一起使用,并且它需要作为 `e` `Paint` 事件处理程序的参数。 此代码执行以下操作:

- 创建一个 对象。

- 将纹理图像旋转90度。

- 填充矩形。

[!code-cpp[System.Drawing.ClassicTextureBrushExamples#5](~/samples/snippets/cpp/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/CPP/form1.cpp#5)]

[!code-csharp[System.Drawing.ClassicTextureBrushExamples#5](~/samples/snippets/csharp/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/CS/form1.cs#5)]

[!code-vb[System.Drawing.ClassicTextureBrushExamples#5](~/samples/snippets/visualbasic/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/VB/form1.vb#5)]

]]>

Method

System.Drawing

1.0.5000.0

2.0.0.0

4.0.0.0

System.Drawing.Common

4.0.0.0

4.0.0.1

4.0.1.0

4.0.2.0

5.0.0.0

System.Void

旋转角度。

一个 枚举,指定是在后面追加还是在前面添加旋转矩阵。

以指定顺序将 对象的局部几何转换旋转指定的量。

## Examples

下面的示例旨在与 Windows 窗体一起使用,并且它需要作为 `e` `Paint` 事件处理程序的参数。 此代码执行以下操作:

- 创建一个 对象。

- 将纹理图像旋转90度。

- 填充矩形。

[!code-cpp[System.Drawing.ClassicTextureBrushExamples#6](~/samples/snippets/cpp/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/CPP/form1.cpp#6)]

[!code-csharp[System.Drawing.ClassicTextureBrushExamples#6](~/samples/snippets/csharp/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/CS/form1.cs#6)]

[!code-vb[System.Drawing.ClassicTextureBrushExamples#6](~/samples/snippets/visualbasic/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/VB/form1.vb#6)]

]]>

System.Drawing

4.0.0.0

将此 对象的局部几何变换缩放指定的倍数。 此方法将缩放矩阵添加到转换前。

Method

System.Drawing

1.0.5000.0

2.0.0.0

4.0.0.0

System.Drawing.Common

4.0.0.0

4.0.0.1

4.0.1.0

4.0.2.0

5.0.0.0

[System.Runtime.TargetedPatchingOptOut("Performance critical to inline this type of method across NGen image boundaries")]

[<System.Runtime.TargetedPatchingOptOut("Performance critical to inline this type of method across NGen image boundaries")>]

System.Void

沿 x 方向缩放转换的量。

沿 y 方向缩放转换的量。

将此 对象的局部几何变换缩放指定的倍数。 此方法将缩放矩阵添加到转换前。

## Examples

下面的示例旨在与 Windows 窗体一起使用,并且它需要作为 `e` `Paint` 事件处理程序的参数。 此代码执行以下操作:

- 创建一个 对象。

- 在 x 方向上将纹理图像缩小两倍。

- 使用纹理画笔在屏幕上填充矩形。

[!code-cpp[System.Drawing.ClassicTextureBrushExamples#7](~/samples/snippets/cpp/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/CPP/form1.cpp#7)]

[!code-csharp[System.Drawing.ClassicTextureBrushExamples#7](~/samples/snippets/csharp/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/CS/form1.cs#7)]

[!code-vb[System.Drawing.ClassicTextureBrushExamples#7](~/samples/snippets/visualbasic/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/VB/form1.vb#7)]

]]>

Method

System.Drawing

1.0.5000.0

2.0.0.0

4.0.0.0

System.Drawing.Common

4.0.0.0

4.0.0.1

4.0.1.0

4.0.2.0

5.0.0.0

System.Void

沿 x 方向缩放转换的量。

沿 y 方向缩放转换的量。

一个 枚举,指定是在后面追加缩放矩阵还是在前面添加缩放矩阵。

以指定顺序将此 对象的局部几何转换按指定量进行缩放。

## Examples

下面的示例旨在与 Windows 窗体一起使用,并且它需要作为 `e` `Paint` 事件处理程序的参数。 此代码执行以下操作:

- 创建一个 对象。

- 在 x 方向上将纹理图像缩小两倍。

- 使用纹理画笔在屏幕上填充矩形。

[!code-cpp[System.Drawing.ClassicTextureBrushExamples#8](~/samples/snippets/cpp/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/CPP/form1.cpp#8)]

[!code-csharp[System.Drawing.ClassicTextureBrushExamples#8](~/samples/snippets/csharp/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/CS/form1.cs#8)]

[!code-vb[System.Drawing.ClassicTextureBrushExamples#8](~/samples/snippets/visualbasic/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/VB/form1.vb#8)]

]]>

Property

System.Drawing

1.0.5000.0

2.0.0.0

4.0.0.0

System.Drawing.Common

4.0.0.0

4.0.0.1

4.0.1.0

4.0.2.0

5.0.0.0

[get: System.Runtime.TargetedPatchingOptOut("Performance critical to inline this type of method across NGen image boundaries")]

[<get: System.Runtime.TargetedPatchingOptOut("Performance critical to inline this type of method across NGen image boundaries")>]

System.Drawing.Drawing2D.Matrix

获取或设置 对象的副本,该对象为与此 对象关联的图像定义局部几何变换。

用于定义几何变换的 对象的副本,该变换仅适用于通过此 对象绘制的填充。

## Remarks

几何转换可用于平移、缩放、旋转或倾斜定义此画笔纹理的图像。 由于由属性返回的矩阵 是画笔几何转换的副本,因此,当您不再需要矩阵时,您应该释放它。

]]>

System.Drawing

4.0.0.0

按指定顺序将此 对象的局部几何转换平移指定的尺寸。

Method

System.Drawing

1.0.5000.0

2.0.0.0

4.0.0.0

System.Drawing.Common

4.0.0.0

4.0.0.1

4.0.1.0

4.0.2.0

5.0.0.0

[System.Runtime.TargetedPatchingOptOut("Performance critical to inline this type of method across NGen image boundaries")]

[<System.Runtime.TargetedPatchingOptOut("Performance critical to inline this type of method across NGen image boundaries")>]

System.Void

沿 x 方向平移变换时要使用的维度。

沿 y 方向平移变换时要使用的维度。

根据指定维度,转换此 对象的局部几何变换。 此方法将平移添加到转换前。

## Examples

下面的示例旨在与 Windows 窗体一起使用,并且它需要作为 `e` `Paint` 事件处理程序的参数。 此代码执行以下操作:

- 创建一个 对象。

- 将纹理图像50单位转换为 x 方向。

- 使用纹理画笔在屏幕上填充矩形。

[!code-cpp[System.Drawing.ClassicTextureBrushExamples#9](~/samples/snippets/cpp/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/CPP/form1.cpp#9)]

[!code-csharp[System.Drawing.ClassicTextureBrushExamples#9](~/samples/snippets/csharp/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/CS/form1.cs#9)]

[!code-vb[System.Drawing.ClassicTextureBrushExamples#9](~/samples/snippets/visualbasic/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/VB/form1.vb#9)]

]]>

Method

System.Drawing

1.0.5000.0

2.0.0.0

4.0.0.0

System.Drawing.Common

4.0.0.0

4.0.0.1

4.0.1.0

4.0.2.0

5.0.0.0

System.Void

沿 x 方向平移变换时要使用的维度。

沿 y 方向平移变换时要使用的维度。

应用转换的顺序(在前面添加或在后面追加)。

按指定顺序将此 对象的局部几何转换平移指定的尺寸。

## Examples

下面的示例旨在与 Windows 窗体一起使用,并且它需要作为 `e` `Paint` 事件处理程序的参数。 此代码执行以下操作:

- 创建一个 对象。

- 将纹理图像50单位转换为 x 方向。

- 使用纹理画笔在屏幕上填充矩形。

[!code-cpp[System.Drawing.ClassicTextureBrushExamples#10](~/samples/snippets/cpp/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/CPP/form1.cpp#10)]

[!code-csharp[System.Drawing.ClassicTextureBrushExamples#10](~/samples/snippets/csharp/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/CS/form1.cs#10)]

[!code-vb[System.Drawing.ClassicTextureBrushExamples#10](~/samples/snippets/visualbasic/VS_Snippets_Winforms/System.Drawing.ClassicTextureBrushExamples/VB/form1.vb#10)]

]]>

Property

System.Drawing

1.0.5000.0

2.0.0.0

4.0.0.0

System.Drawing.Common

4.0.0.0

4.0.0.1

4.0.1.0

4.0.2.0

5.0.0.0

[get: System.Runtime.TargetedPatchingOptOut("Performance critical to inline this type of method across NGen image boundaries")]

[<get: System.Runtime.TargetedPatchingOptOut("Performance critical to inline this type of method across NGen image boundaries")>]

System.Drawing.Drawing2D.WrapMode

获取或设置 枚举,它指示此 对象的换行模式。

枚举,它指定通过此 对象绘制的填充的平铺方式。

## Examples

下面的代码示例演示如何使用方法获取新位图 。 它还演示 属性和 枚举。

此示例旨在与 Windows 窗体一起使用。 创建一个包含名为 "Button2" 的按钮的窗体。 将代码粘贴到窗体中,并将 Button2_Click 方法与按钮的 `Click` 事件关联。

[!code-cpp[System.Drawing.ImageExample#2](~/samples/snippets/cpp/VS_Snippets_Winforms/System.Drawing.ImageExample/CPP/form1.cpp#2)]

[!code-csharp[System.Drawing.ImageExample#2](~/samples/snippets/csharp/VS_Snippets_Winforms/System.Drawing.ImageExample/CS/form1.cs#2)]

[!code-vb[System.Drawing.ImageExample#2](~/samples/snippets/visualbasic/VS_Snippets_Winforms/System.Drawing.ImageExample/VB/form1.vb#2)]

]]>

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值