TextureBrush コンストラクタとは? わかりやすく解説

Weblio 辞書 > コンピュータ > .NET Framework クラス ライブラリ リファレンス > TextureBrush コンストラクタの意味・解説 

TextureBrush コンストラクタ (Image)

指定イメージ使用する新しTextureBrush オブジェクト初期化します。

名前空間: System.Drawing
アセンブリ: System.Drawing (system.drawing.dll 内)
構文構文

使用例使用例

FromFile メソッド使用して新しビットマップ取得する方法次のコード例示しますTextureBrush の例も示します

この例は、Windows フォームでの使用意図してデザインされています。Button2 という名前のボタンを含むフォーム作成しますコードフォーム貼り付け、Button2_Click メソッドボタンClick イベント関連付けます。

Private Sub Button2_Click(ByVal
 sender As System.Object, _
    ByVal e As System.EventArgs) Handles
 Button2.Click
    Try
        Dim image1 As Bitmap = _
            CType(Image.FromFile("C:\Documents and Settings\"
 _
            & "All Users\Documents\My Music\music.bmp",
 True), Bitmap)

        Dim texture As New
 TextureBrush(image1)
        texture.WrapMode = Drawing2D.WrapMode.Tile
        Dim formGraphics As Graphics = Me.CreateGraphics()
        formGraphics.FillEllipse(texture, _
            New RectangleF(90.0F, 110.0F, 100, 100))
        formGraphics.Dispose()

    Catch ex As System.IO.FileNotFoundException
        MessageBox.Show("There was an error opening the bitmap."
 _
            & "Please check the path.")
    End Try

End Sub
private void Button2_Click(System.Object sender,
 System.EventArgs e)
{
    try
    {
        Bitmap image1 = (Bitmap) Image.FromFile(@"C:\Documents and Settings\"
 +
            @"All Users\Documents\My Music\music.bmp", true);

        TextureBrush texture = new TextureBrush(image1);
        texture.WrapMode = System.Drawing.Drawing2D.WrapMode.Tile;
        Graphics formGraphics = this.CreateGraphics();
        formGraphics.FillEllipse(texture, 
            new RectangleF(90.0F, 110.0F, 100, 100));
        formGraphics.Dispose();

    }
    catch(System.IO.FileNotFoundException)
    {
        MessageBox.Show("There was an error opening the bitmap." +
            "Please check the path.");
    }

}
private:
   void Button2_Click( System::Object^ /*sender*/, System::EventArgs^
 /*e*/ )
   {
      try
      {
         Bitmap^ image1 = dynamic_cast<Bitmap^>(Image::FromFile( "C:\\Documents
 and Settings\\"
         "All Users\\Documents\\My Music\\music.bmp", true
 ));
         TextureBrush^ texture = gcnew TextureBrush( image1 );
         texture->WrapMode = System::Drawing::Drawing2D::WrapMode::Tile;
         Graphics^ formGraphics = this->CreateGraphics();
         formGraphics->FillEllipse( texture, RectangleF(90.0F,110.0F,100,100)
 );
         delete formGraphics;
      }
      catch ( System::IO::FileNotFoundException^ ) 
      {
         MessageBox::Show( "There was an error opening the bitmap."
         "Please check the path." );
      }
   }
private void button2_Click(Object sender, System.EventArgs
 e)
{
    try {
        Bitmap image1 = ((Bitmap)(Image.FromFile(
            "C:\\Documents and Settings\\"  
            + "All Users\\Documents\\My Music\\music.bmp", true)));
        TextureBrush texture = new TextureBrush(image1);

        texture.set_WrapMode(System.Drawing.Drawing2D.WrapMode.Tile);

        Graphics formGraphics = this.CreateGraphics();

        formGraphics.FillEllipse(texture, new RectangleF(90, 110,
 100,100));
        formGraphics.Dispose();
    }
    catch (System.IO.FileNotFoundException exp) {
        MessageBox.Show(("There was an error opening the bitmap."  
            + "Please check the path."));
    }
} //button2_Click
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照

TextureBrush コンストラクタ (Image, WrapMode, Rectangle)

指定イメージラップ モード、および外接する四角形使用する新しTextureBrush オブジェクト初期化します。

名前空間: System.Drawing
アセンブリ: System.Drawing (system.drawing.dll 内)
構文構文

Public Sub New ( _
    image As Image, _
    wrapMode As WrapMode, _
    dstRect As Rectangle _
)
Dim image As Image
Dim wrapMode As WrapMode
Dim dstRect As Rectangle

Dim instance As New TextureBrush(image,
 wrapMode, dstRect)
public TextureBrush (
    Image image,
    WrapMode wrapMode,
    Rectangle dstRect
)
public:
TextureBrush (
    Image^ image, 
    WrapMode wrapMode, 
    Rectangle dstRect
)
public TextureBrush (
    Image image, 
    WrapMode wrapMode, 
    Rectangle dstRect
)
public function TextureBrush (
    image : Image, 
    wrapMode : WrapMode, 
    dstRect : Rectangle
)

パラメータ

image

TextureBrush オブジェクト内部塗りつぶすために使用する Image オブジェクト

wrapMode

TextureBrush オブジェクト並べ方を指定する WrapMode 列挙体。

dstRect

この TextureBrush オブジェクト外接する四角形を表す Rectangle 構造体

プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照

TextureBrush コンストラクタ (Image, Rectangle)

指定したイメージおよび外接する四角形使用する新しTextureBrush オブジェクト初期化します。

名前空間: System.Drawing
アセンブリ: System.Drawing (system.drawing.dll 内)
構文構文

Public Sub New ( _
    image As Image, _
    dstRect As Rectangle _
)
Dim image As Image
Dim dstRect As Rectangle

Dim instance As New TextureBrush(image,
 dstRect)
public TextureBrush (
    Image image,
    Rectangle dstRect
)
public:
TextureBrush (
    Image^ image, 
    Rectangle dstRect
)
public TextureBrush (
    Image image, 
    Rectangle dstRect
)
public function TextureBrush (
    image : Image, 
    dstRect : Rectangle
)

パラメータ

image

TextureBrush オブジェクト内部塗りつぶすために使用する Image オブジェクト

dstRect

この TextureBrush オブジェクト外接する四角形を表す Rectangle 構造体

プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照

TextureBrush コンストラクタ (Image, WrapMode, RectangleF)

指定イメージラップ モード、および外接する四角形使用する新しTextureBrush オブジェクト初期化します。

名前空間: System.Drawing
アセンブリ: System.Drawing (system.drawing.dll 内)
構文構文

Public Sub New ( _
    image As Image, _
    wrapMode As WrapMode, _
    dstRect As RectangleF _
)
Dim image As Image
Dim wrapMode As WrapMode
Dim dstRect As RectangleF

Dim instance As New TextureBrush(image,
 wrapMode, dstRect)
public TextureBrush (
    Image image,
    WrapMode wrapMode,
    RectangleF dstRect
)
public:
TextureBrush (
    Image^ image, 
    WrapMode wrapMode, 
    RectangleF dstRect
)
public TextureBrush (
    Image image, 
    WrapMode wrapMode, 
    RectangleF dstRect
)
public function TextureBrush (
    image : Image, 
    wrapMode : WrapMode, 
    dstRect : RectangleF
)

パラメータ

image

TextureBrush オブジェクト内部塗りつぶすために使用する Image オブジェクト

wrapMode

TextureBrush オブジェクト並べ方を指定する WrapMode 列挙体。

dstRect

この TextureBrush オブジェクト外接する四角形を表す RectangleF 構造体

プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照

TextureBrush コンストラクタ (Image, Rectangle, ImageAttributes)

指定したイメージ外接する四角形、およびイメージ属性使用する新しTextureBrush オブジェクト初期化します。

名前空間: System.Drawing
アセンブリ: System.Drawing (system.drawing.dll 内)
構文構文

Public Sub New ( _
    image As Image, _
    dstRect As Rectangle, _
    imageAttr As ImageAttributes _
)
Dim image As Image
Dim dstRect As Rectangle
Dim imageAttr As ImageAttributes

Dim instance As New TextureBrush(image,
 dstRect, imageAttr)
public TextureBrush (
    Image image,
    Rectangle dstRect,
    ImageAttributes imageAttr
)
public:
TextureBrush (
    Image^ image, 
    Rectangle dstRect, 
    ImageAttributes^ imageAttr
)
public TextureBrush (
    Image image, 
    Rectangle dstRect, 
    ImageAttributes imageAttr
)
public function TextureBrush (
    image : Image, 
    dstRect : Rectangle, 
    imageAttr : ImageAttributes
)

パラメータ

image

TextureBrush オブジェクト内部塗りつぶすために使用する Image オブジェクト

dstRect

この TextureBrush オブジェクト外接する四角形を表す Rectangle 構造体

imageAttr

この TextureBrush オブジェクト使用されるイメージについての追加情報格納している ImageAttributes オブジェクト

プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照

TextureBrush コンストラクタ

指定イメージ使用する新しい TextureBrush オブジェクト初期化します。
オーバーロードの一覧オーバーロードの一覧

名前 説明
TextureBrush (Image) 指定イメージ使用する新しTextureBrush オブジェクト初期化します。

.NET Compact Framework によってサポートされています。

TextureBrush (Image, Rectangle) 指定したイメージおよび外接する四角形使用する新しTextureBrush オブジェクト初期化します。
TextureBrush (Image, RectangleF) 指定したイメージおよび外接する四角形使用する新しTextureBrush オブジェクト初期化します。
TextureBrush (Image, WrapMode) 指定イメージラップ モード使用する新しTextureBrush オブジェクト初期化します。
TextureBrush (Image, Rectangle, ImageAttributes) 指定したイメージ外接する四角形、およびイメージ属性使用する新しTextureBrush オブジェクト初期化します。
TextureBrush (Image, RectangleF, ImageAttributes) 指定したイメージ外接する四角形、およびイメージ属性使用する新しTextureBrush オブジェクト初期化します。
TextureBrush (Image, WrapMode, Rectangle) 指定イメージラップ モード、および外接する四角形使用する新しTextureBrush オブジェクト初期化します。
TextureBrush (Image, WrapMode, RectangleF) 指定イメージラップ モード、および外接する四角形使用する新しTextureBrush オブジェクト初期化します。
参照参照

関連項目

TextureBrush クラス
TextureBrush メンバ
System.Drawing 名前空間

TextureBrush コンストラクタ (Image, RectangleF, ImageAttributes)

指定したイメージ外接する四角形、およびイメージ属性使用する新しTextureBrush オブジェクト初期化します。

名前空間: System.Drawing
アセンブリ: System.Drawing (system.drawing.dll 内)
構文構文

Public Sub New ( _
    image As Image, _
    dstRect As RectangleF, _
    imageAttr As ImageAttributes _
)
Dim image As Image
Dim dstRect As RectangleF
Dim imageAttr As ImageAttributes

Dim instance As New TextureBrush(image,
 dstRect, imageAttr)
public TextureBrush (
    Image image,
    RectangleF dstRect,
    ImageAttributes imageAttr
)
public:
TextureBrush (
    Image^ image, 
    RectangleF dstRect, 
    ImageAttributes^ imageAttr
)
public TextureBrush (
    Image image, 
    RectangleF dstRect, 
    ImageAttributes imageAttr
)
public function TextureBrush (
    image : Image, 
    dstRect : RectangleF, 
    imageAttr : ImageAttributes
)

パラメータ

image

TextureBrush オブジェクト内部塗りつぶすために使用する Image オブジェクト

dstRect

この TextureBrush オブジェクト外接する四角形を表す RectangleF 構造体

imageAttr

この TextureBrush オブジェクト使用されるイメージについての追加情報格納している ImageAttributes オブジェクト

プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照

TextureBrush コンストラクタ (Image, WrapMode)

指定イメージラップ モード使用する新しTextureBrush オブジェクト初期化します。

名前空間: System.Drawing
アセンブリ: System.Drawing (system.drawing.dll 内)
構文構文

Public Sub New ( _
    image As Image, _
    wrapMode As WrapMode _
)
Dim image As Image
Dim wrapMode As WrapMode

Dim instance As New TextureBrush(image,
 wrapMode)
public TextureBrush (
    Image image,
    WrapMode wrapMode
)
public:
TextureBrush (
    Image^ image, 
    WrapMode wrapMode
)
public TextureBrush (
    Image image, 
    WrapMode wrapMode
)
public function TextureBrush (
    image : Image, 
    wrapMode : WrapMode
)

パラメータ

image

TextureBrush オブジェクト内部塗りつぶすために使用する Image オブジェクト

wrapMode

TextureBrush オブジェクト並べ方を指定する WrapMode 列挙体。

プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照

TextureBrush コンストラクタ (Image, RectangleF)

指定したイメージおよび外接する四角形使用する新しTextureBrush オブジェクト初期化します。

名前空間: System.Drawing
アセンブリ: System.Drawing (system.drawing.dll 内)
構文構文

Public Sub New ( _
    image As Image, _
    dstRect As RectangleF _
)
Dim image As Image
Dim dstRect As RectangleF

Dim instance As New TextureBrush(image,
 dstRect)
public TextureBrush (
    Image image,
    RectangleF dstRect
)
public:
TextureBrush (
    Image^ image, 
    RectangleF dstRect
)
public TextureBrush (
    Image image, 
    RectangleF dstRect
)
public function TextureBrush (
    image : Image, 
    dstRect : RectangleF
)

パラメータ

image

TextureBrush オブジェクト内部塗りつぶすために使用する Image オブジェクト

dstRect

この TextureBrush オブジェクト外接する四角形を表す RectangleF 構造体

プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照



英和和英テキスト翻訳>> Weblio翻訳
英語⇒日本語日本語⇒英語
  

辞書ショートカット

すべての辞書の索引

「TextureBrush コンストラクタ」の関連用語

TextureBrush コンストラクタのお隣キーワード
検索ランキング

   

英語⇒日本語
日本語⇒英語
   



TextureBrush コンストラクタのページの著作権
Weblio 辞書 情報提供元は 参加元一覧 にて確認できます。

   
日本マイクロソフト株式会社日本マイクロソフト株式会社
© 2025 Microsoft.All rights reserved.

©2025 GRAS Group, Inc.RSS