Original Post
🔒 Locked
Vertex buffers
Advertisement
Well they store vertex data in the GPU(hence the name, Vertex Buffer). They're only important if you're using vertices, like if you were using 2D triangles or quads for your drawing. If you're using the sprite interface, then you don't necessarily have to learn them, although learning new concepts never hurt anyone.
Quote:
Original post by Scet
If you're using the sprite interface, then you don't necessarily have to learn them, although learning new concepts never hurt anyone.
If you're using a sprite interface, and you want your project to become any big, you should definitely learn them, because you have hardware acceleration on any stuff you want to do with your 2D images ( e.g. rotation, scaling, ... ).
Quote:
Original post by t0Xic Quote:
Original post by Scet
If you're using the sprite interface, then you don't necessarily have to learn them, although learning new concepts never hurt anyone.
If you're using a sprite interface, and you want your project to become any big, you should definitely learn them, because you have hardware acceleration on any stuff you want to do with your 2D images ( e.g. rotation, scaling, ... ).
ahh, the sprite interface has rotation and scaling, it can be done without Vertex Buffers(well the sprite interface builds the VBs for you). Unless I misinterpeted your post and you meant something else?
I was thinking about dodging the d3dxsprite class and using transformed lit vertices. It seemed to me that there would be a lot of benefit to doing it that way. So if I had say multiple characters that use the same texture than I should set up a vertex buffer? Do I have that correct?
Quote:
Original post by Scet Quote:
Original post by t0Xic Quote:
Original post by Scet
If you're using the sprite interface, then you don't necessarily have to learn them, although learning new concepts never hurt anyone.
If you're using a sprite interface, and you want your project to become any big, you should definitely learn them, because you have hardware acceleration on any stuff you want to do with your 2D images ( e.g. rotation, scaling, ... ).
ahh, the sprite interface has rotation and scaling, it can be done without Vertex Buffers(well the sprite interface builds the VBs for you). Unless I misinterpeted your post and you meant something else?
wait wait... so if I use the sprite interface it will build vertex buffers for me? That's a good thing to know. At that point I wonder if there's much gain in not using the sprite interface. ...I did hear it blurs images but I haven't seen that yet.
Quote:ID3DXSprite is just a helper class. All it does is wrap up a vertex (and index) buffer and renders stuff for you. It's pretty efficient, and you'd struggle to write something more efficient. However, if you write your own version you have more control over what it actually does.
Original post by ELFanatic
wait wait... so if I use the sprite interface it will build vertex buffers for me? That's a good thing to know. At that point I wonder if there's much gain in not using the sprite interface. ...I did hear it blurs images but I haven't seen that yet.
I wrote a Journal Entry on what ID3DXSprite does exactly - all it does it manage a vertex buffer of 12288 vertices (I think, it might have been 16384), and an index buffer of 4096 indices.
Topic Locked
This topic has been locked by a moderator. New replies are not allowed.
Sign in to reply to this topic.
Advertisement