Device.DrawPrimitives Method
Renders a sequence of non-indexed geometric primitives of the specified type from the current set of data input streams.
Namespace: Microsoft.WindowsMobile.DirectX.Direct3D
Assembly: Microsoft.WindowsMobile.DirectX (in microsoft.windowsmobile.directx.dll)
Syntax
'Declaration
Public Sub DrawPrimitives ( _
primitiveType As PrimitiveType, _
startVertex As Integer, _
primitiveCount As Integer _
)
'Usage
Dim instance As Device
Dim primitiveType As PrimitiveType
Dim startVertex As Integer
Dim primitiveCount As Integer
instance.DrawPrimitives(primitiveType, startVertex, primitiveCount)
public void DrawPrimitives (
PrimitiveType primitiveType,
int startVertex,
int primitiveCount
)
public:
void DrawPrimitives (
PrimitiveType primitiveType,
int startVertex,
int primitiveCount
)
public void DrawPrimitives (
PrimitiveType primitiveType,
int startVertex,
int primitiveCount
)
public function DrawPrimitives (
primitiveType : PrimitiveType,
startVertex : int,
primitiveCount : int
)
Parameters
- primitiveType
A member of the PrimitiveType enumerated type that describes the type of primitive to render.
- startVertex
An index of the first vertex to load. Beginning at startVertex, the correct number of vertices is read out of the vertex buffer.
- primitiveCount
A number of primitives to render. To determine the maximum number of primitives allowed, check MaxPrimitiveCount. The primitiveCount is the number of primitives as determined by the primitive type. If it is a line list, each primitive has two vertices. If it is a triangle list, each primitive has three vertices.
Exceptions
Exception type | Condition |
---|---|
The method call is invalid. For example, a method's parameter might contain an invalid value. |
Remarks
This method should not be called with a single triangle at a time.
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see .
Platforms
Windows CE, Windows Mobile for Pocket PC, Windows Mobile for Smartphone
The .NET Framework does not support all versions of every platform. For a list of the supported versions, see System Requirements.
Version Information
.NET Compact Framework
Supported in: 2.0
See Also
Reference
Device Class
Device Members
Microsoft.WindowsMobile.DirectX.Direct3D Namespace