Can you please look at my code??

Started by
8 comments, last by RonanHayes 21 years, 1 month ago
Hey all Ok I got that job done for my boss and well I''ve been playing about with directX somewhat I took one of those gameinstitute courses and well have been trying to implement somethings. What I want to do is a full D3D initialisation followed by the loading of my BSP tree, now I know that my initialisation works on its own and I know that my BSP code works on its own, its when I stick the 2 together I get the problems.I have commented out some of the stuff that are not neccessary to get this thing testing such as title screen updating the viewport (just to get it onto the screen would do for now) input etc. Anyway if you could all take a look and let me know if Im missing anything that is incredibly obvious. Cheers Ronan
Advertisement
Heck a link would help

http://www.welcome.ie/ronan/heat.zip

Any help or advice about optomising the code would be fantastic, espcially if I could see code
Ok Peter Kovach just e-mailed with his debug report, he uncommented some stuff and well he got the following


I am getting, in debug mode (you won't see this running in
normal execution):


  Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.Direct3D8: (ERROR) :*** Exception ind:\builds\nt32_chk\multimedia\directx\dxg\d3d8\fe\vshader.cpp Line: 600Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.  


over and over, each render loop. (I assume this comes from line 1177 of
main.cpp)




Edit: Jim - Ack, use source tags


[edited by - Jim Adams on March 18, 2003 6:38:33 PM]
Aren't you the guy that coded a 3D engine for his boss in a month?

You don't need to include the entire 15 page debug report. It's all the same error message getting called each frame in the render loop (specifically the DrawLeaf () function).

I don't see it in your code and I don't have a compiler handy here at work, but it looks like you are calling SetVertexShader () with an invalid handle (or maybe not at all). Then, whenever your DrawIndexedPrimitiveUP() function gets called it tries to use the bad vertex shader handle, thus the error message :

Direct3D8: (ERROR) :Invalid vertex shader handle (0x0)

Direct3D8: (ERROR) :DrawIndexedPrimitiveUP failed.


Look here for more information about using vertex shaders.


[edited by - bpopp on March 18, 2003 2:59:37 PM]
The code you see is based on the gamedev course and took me about 5 hours to get together, I couldnt figure out the problem I''ll look into the erro and see, Sorry about posting the entire Debug thing, last time I posted I was told to post the full debug, go figure.

Anyway I did could a full oct-tree programme for my boss in about 4 weeks, this is a BSP version that I''ve been messing with and well Im just trying to get the frickin thing to work.....

Cheers for the help.

Any additional help on how to rectify the shader problem would be much appreciated, anyway Im of to MSDN to see what I can dig up

Cheers

Ronan
Yeah, it looks like that is your problem. You''re not setting your vertex shader. Somewhere in your initialization you need something like this:

if(FAILED(pDirect3DDevice->SetVertexShader(D3DFVF_CUSTOMVERTEX)))
{
// error code here..
}

And this would go in your header file: (if it''s not already there.. I didn''t see it.):

#define D3DFVF_CUSTOMVERTEX ( D3DFVF_XYZ | D3DFVF_DIFFUSE | D3DFVF_TEX1 )

Your basically telling the Direct3d vertex renderer what is in the vertex stream structure setup by SetStreamSource().
If you''re using DX9, then use SetFVF instead. Also call SetVertexShader(NULL) to clear the shader handle.
Having taken a quick look at the code you also want to consider calling InitPolygons() *after* you have initialised Direct3D... as some D3DX texture loading routines require a valid pointer to your Direct3D device object.

Regards,
Sharky


---
#define _WEBSITE
Sharky''s Coding Corner
#endif
---
This is great cheers for all the help.

Any thing else that I need touching up on?
One more thing , so Peter Kovach is inside here watching us huh ? Cool guy - good writter ...
Thank you all :)

This topic is closed to new replies.

Advertisement