Share via


Surface.FromBitmap(Device,Bitmap,Pool) Method (Microsoft.DirectX.Direct3D)

Creates a surface from a Microsoft .NET bitmap object.

Definition

Visual Basic Public Shared Function FromBitmap( _
    ByVal device As Device, _
    ByVal image As BitmapLeave Site, _
    ByVal pool As Pool _
) As Surface
C# public static Surface FromBitmap(
    Device device,
    BitmapLeave Site image,
    Pool pool
);
C++ public:
static SurfaceFromBitmap(
    Devicedevice,
    BitmapLeave Siteimage,
    Pool pool
);
JScript public static function FromBitmap(
    device : Device,
    image : BitmapLeave Site,
    pool : Pool
) : Surface;

Parameters

device Microsoft.DirectX.Direct3D.Device
Reference to the Device associated with the surface.
image System.Drawing.Bitmap
Reference to a BitmapLeave Site object that contains the bitmap for the surface.
pool Microsoft.DirectX.Direct3D.Pool
A Pool object that defines the memory class of the surface.

Return Value

Microsoft.DirectX.Direct3D.Surface
A Surface object that represents the newly created surface.