Help needed urgently guys!
Help needed urgently guys!
I've been awake for over 24hours trying to get this ray cast function to work and im nearly there so can someone please help me i've attached the source code file. the screen shot shows what output im getting compared with what i should be getting if anyone out there can please help me it would mean a lot to me i dont know where its going wrong but it must one of the calculations that is casuing the horrible output
- Attachments
-
- raycasting_textured.png
- (290.42 KiB) Downloaded 97 times
-
- ENGINE.CPP
- (25.36 KiB) Downloaded 168 times
Re: Help needed urgently guys!
Can you post all of your code it is hard to tell the problem from only one file.
CraigSpaz
Re: Help needed urgently guys!
ok mate here it is
- Attachments
-
- RayCast Wk 2.zip
- (151.25 KiB) Downloaded 163 times
Re: Help needed urgently guys!
this file i just uploaded is a powerpoint presentation that i have been foloowing to solve this task it should help understand what i've been doing and where i have gone wrong
- Attachments
-
- RayCast.zip
- (8.01 MiB) Downloaded 154 times
Re: Help needed urgently guys!
I noticed a few things in your code the first thing is that in your DXHarness.cpp I can't find the file d3dx9.h. I think it should be d3d9.h. When running your code in debug mode then it says that your typcode and pNext variable could not be evaluated and so I think that the problem is somewhere in your texture code. You should take another look at it.
CraigSpaz
Re: Help needed urgently guys!
Hi CraigSpaz
both #include <d3d9.h>
#include <d3dX9.h> are in the DXHarness.cpp file you need to make that you have the sdk installed on your PC and included in the project
both #include <d3d9.h>
#include <d3dX9.h> are in the DXHarness.cpp file you need to make that you have the sdk installed on your PC and included in the project
Re: Help needed urgently guys!
to include the sdk library in the project you need to go on project properties. I recomend downloading the june 2010 sdk. once this is done go onto project properties (or RayCast properties after selecting the project tab on the toolbar) once a menu appears click on configuration properties drop down menu and click on the C/C++ drop down menu, after that click on general and there will be a menu of options, one called AdditionalIncludeDirectories. Click on this and browse for the sdk folder downloaded and that will get rid of #include <d3dX9.h> error
Re: Help needed urgently guys!
Did you copy the code from somewhere of did you write this yourself?
CraigSpaz
Re: Help needed urgently guys!
I only wrote the code that is commented with the steps in the void view::RayCast so steps 1 to 7 everything else was provided for me