Jump to content
  • Advertisement

Archived

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

Tron3k

HAL device works in D3D7, not D3D8

This topic is 6009 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Here''s the problem: In Direct3D7, I can use the IID_IDirect3DHALDevice and it''s really fast (60 FPS). However, when I tried DirectX8, I can''t use D3DDEVTYPE_HAL! I''m stuck with the "reference rasterizer", where I get 2 FPS!! Here''s my line of code in Visual Basic: Set D3DDevice = D3D.CreateDevice(D3DADAPTER_DEFAULT, D3DDEVTYPE_REF, Form1.hWnd, D3DCREATE_HARDWARE_VERTEXPROCESSING, D3DWindow) That is the only thing that works. I have an ATI 3D Rage Pro. Maybe this card just doesn''t cut it for DX8? Or am I doing something else wrong?

Share this post


Link to post
Share on other sites
Advertisement
DirectX 8 introduces a new restriction:

To be usable with DirectX 8 interfaces, a graphics card *must* have at least DirectX 6 level drivers. This was to reduce the amount of emulation (aka unnecessary bloat) required within the D3D runtime to support cards which the majority of gamers weren''t using any more.


DirectX 8.1 introduces another restriction:

The OS must be at least Windows98. There are too many "issues" with the Windows95 kernel etc. Also Win95 doesn''t support multimon etc which required stub/patch code to make the SDK work.

--
Simon O''''Connor
Creative Asylum Ltd
www.creative-asylum.com

Share this post


Link to post
Share on other sites
umm, s1ca. you missed the majpr reason why it aint working.

D3DCREATE_HARDWARE_VERTEXPROCESSING shoudl be D3DCREATE_SOFTWARE_VERTEXPROCESSING since he is running a rage pro which does not support hardware vertex processing. tron3k READ the manual and understand your hardware.

Share this post


Link to post
Share on other sites
Actually, the hardware vertex processing does seem to work with the REF device for me. I tried the HAL with software vertex processing, but it still didn''t work. I guess the card is too old.

Share this post


Link to post
Share on other sites
you see that would be true if it were not for the fact that dx8 works fine on MY 4mb ati rage pro. also for the record it works on my 12mb voodoo2 as well (both on the same pc). those are both quite old cards, yet they work in dx8 fine. which makes me wonder what the heck YOU are doing to make it not work.

you MUST use software_vertex_processing. also make sure you are using depth buffer, screen formats, etc that your card supports. check the friggen error message. have you even bothered to check to see if your card is being displayed in dxcaps viewer? try dxdiag (maybe somethign disable d3d for the card)? hardware vertex processing works with the ref rastizer because its just that a REFERENCE rasterizer that emulates all of d3d in software. meant to let you see the differences between how yoru card draws it and how it is supposed to draw it. also lets you test features you card may not support in hardware. heck you can use pixel shaders if you want if you use the ref rasterizer.

and RTFM so you know what the heck is going on with dx8. also i am not too familar with VB, but i just noticed that you are setting D3DDevice equal to what CreateDevice is returning. you do realize that most if not all dx functions return error codes and when you create objects you pass the pointers (ByRef type things) in the function and it gets filled. so your D3DWindow would be your D3DDevice. of course i could be mistaken. if i where you i woudl seriously look over the code you are copying and make sure you are doing that correctly (since it may be correct, though it looks very wrong to me).

Share this post


Link to post
Share on other sites
quote:

umm, s1ca. you missed the majpr reason why it aint working.



ah yes! ... thats what I get for posting late at night (UK time) after an evening of drinking


--
Simon O''''Connor
Creative Asylum Ltd
www.creative-asylum.com

Share this post


Link to post
Share on other sites
The error I got when trying the HAL device is:

D3DERR_INVALIDCALL

This is described as: The method call is invalid. For example, a method''s parameter may have an invalid value.

I tried dxdiag but everything seems to be fine...

Share this post


Link to post
Share on other sites
well, one simple thing that no one (afaik) mentioned so far - try getting some new drivers.

I dont know what ATI are like now (had bad experiences with them and drivers before now), but try getting the latest drivers for your card - preferably newer than November-2000 (DX8 release date roughly).

Many cards (Voodoo3 in particular), had to have updated drivers before they''d run properly with D3D8... maybe this is your problem?

Jack;

Share this post


Link to post
Share on other sites
Here''s the whole code:

Dim DispMode As D3DDISPLAYMODE
Dim D3DWindow As D3DPRESENT_PARAMETERS

Set Dx = New DirectX8
Set D3D = Dx.Direct3DCreate

D3D.GetAdapterDisplayMode D3DADAPTER_DEFAULT, DispMode
D3DWindow.Windowed = 1
D3DWindow.SwapEffect = D3DSWAPEFFECT_COPY_VSYNC
D3DWindow.BackBufferFormat = DispMode.Format

Set D3DDevice = D3D.CreateDevice(D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, Form1.hWnd, D3DCREATE_SOFTWARE_VERTEXPROCESSING, D3DWindow)

Of course this code gives me that error when I run it. Also, ATI doesn''t seem to have any drivers that new. Their newest one is May 28th, 1999. Should I get it anyway? It''s a little bit newer than my current driver.

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!