DrawUserPrimitives with GraphicsBuffer
i recently tried to draw some lines using DrawUserPrimitive method, but in the last DirectX (assembly 2.0) they changed this function and now i must send GraphicsBuffer data to draw the vertices, i don′t know how to use it, i looked other web pages and found tips, like this:
GraphicsBuffer<
PositionColored> gb =new GraphicsBuffer<PositionColored>(3);gb.Write(vertices);
but it doesn't compile, it sends this:
Error 3 "The non-generic type 'Microsoft.DirectX.GraphicsBuffer' cannot be used with type arguments "
what can i do? please help
[803 byte] By [
el-chema] at [2007-12-23]
Hello:
I want to render a tringle with postionColored vertex. I have made the
same that the last examples. The problem that I have is that the
tringle don't paint with the colors I want.
The vertex are red, green and blue and the triangle is painted orange.
The color orange must be for a texture that I use to paint a map.
Almbcn wrote: |
| Hello: I want to render a tringle with postionColored vertex. I have made the same that the last examples. The problem that I have is that the tringle don't paint with the colors I want.
|
|
You might want to create a new thread for this, since it doesn't sound like the same issue.
What does your code look like? What colors does the triangle get drawn with?