I am looking for some simple tutorials on DX9 and C#. I know some come with the DX9 SDK, but they arent really tutorials. I want to start with the very basics, im new to DX programming, and want to get started in the right direction. Thanks
im sad about that...there was some kind of VB site..you could take a look by there..but i dont remember the link..maybe someone in this forum does..it was something like www.vbdirectx.com ..sorry i dont remember
DX9 is so new, I doubt there are many tutorial about it. Here, you can have what I've written.
It's kind of a game framework in C#. Much left to add and change, but I'm developing it as I go along. Note that there seems to be a bug: every blit that hits pixel (0,0) causes the app to crash. I guess it's a bug in managed DX9. Maybe there already is a patch by MS.
Also, direct locking is extremly slow. Too slow for any real use, and it needs its own bug workaround if you use any color depth than 8 bit.
All the buzzt CornedBee
"Writing specifications is like writing a novel. Writing code is like writing poetry."
- Anonymous, published by Raymond Chen
Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.
hmmm...then dx9 managed sucks? all ppl were waiting 4 it to do games (3d) and then it sucks for that?
also, did u try it using unmanaged? the speed diference is huge?
No, I didn't compare it to unmanaged directly. I know from the past that locking was quite fast in unmanaged. The problem is that managed DX allocates an array that serves as buffer. When done it copies the array to the screen buffer. That's one memory allocation, which is slow in .Net, and one memory copy, which is not very fast either. And a bug makes the array DX allocates useless in any color mode but 8-bit, so you have to allocate ANOTHER array yourself, which slows it down even more.
I haven't use the Direct3D part yet, I guess it has been done more carefully than DirectDraw as DirectDraw is just "so that it is there" while Direct3D is the future.
Or whatever. DirectInput works nicely.
All the buzzt CornedBee
"Writing specifications is like writing a novel. Writing code is like writing poetry."
- Anonymous, published by Raymond Chen
Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.