Archived

This topic is now archived and is closed to further replies.

Guest Anonymous Poster

drawindexedprim error

Recommended Posts

Guest Anonymous Poster
I am receiving the following return value from DrawIndexedPrimitive (using DX7).

-2005532527

I did a switch and checked the cases that are documented for this method and got no matches. Really strange....I can't find any documentation that tells you what numeric values are the equivalent of the #define error msg...hmmmm. maybe I'll check the header file...

The weird thing is that everything works fine on my dev computer and I have the same SDK, .dlls, .libs, etc installed on the computer I am failing on.

Anyone have any ideas?

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
OK, I managed to figure it out...the error was actually a DDRAW error being returned by the device. It was INVALIDPIXELFORMAT. What a pain in the butt reverse engineering the HRESULT! All of that silly bit shifting :-) Must have taken me at least 10 minutes. Well maybe not that long...

Anyway, now I know it is my texture map surface. It is a 16 bit map and my guess is that my card (TNT2) wants a 555 format and I'm going 565 or vice versa. So, gotta go fix it now.....I guess I'll check the devicecaps pixelformat next time! Thanks folks.

Share this post


Link to post
Share on other sites