Jump to content
  • Advertisement
Sign in to follow this  
Cypher19

Fooling D3D to think that the REF is actually HAL?

This topic is 5471 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

Does anyone know of a way to fool Direct3D into using the reference drivers instead of the HAL drivers without changing a program?

Share this post


Link to post
Share on other sites
Advertisement
Quote:
Original post by Coder
Quote:
Original post by darookie
Replace your gfx card with an S3 Trio [wink]

Actually, an S3 virge would do better here. [grin]


Or a Matrox Millenium, yum, no texturing, no alpha.

ISTR a period when S3 devrel used to recommend falling back to software rasterization in cases where we detected a ViRGE :o)


On a serious note though, regarding the original question:

1) Perhaps you could give us some more background about why you want to forcibly use a REF device and can't change the code. It's not exactly something many people want to do, so isn't something MS put a specific feature in to the API or SDK for.


2) Any app which uses anything like real world models, such as a game or anything else specifically designed for hardware will be painfully slow (less than 1 frame per second!) due to REF being a debugging and development tool rather than a usable software rasterizer.


3) How to do it? I think the only way would be to make a wrapper DLL for D3D9.DLL to live in the same folder as the app you want to use REF with. It wouldsimply forwards on all calls to the true DLL, but intercept the CreateDevice() call and fiddle with the device type parameter.

The "Detours" library, DLL Detective, or even Nicolas Capens' swShader might be worth looking at for examples of doing this.

Share this post


Link to post
Share on other sites
The main reason I want to use it is because I only have a GeForce4 ti4400, so I'd like to experience PS2.0 graphics in some form. The fact that it's slow is no biggie, I was planning on using FRAPS to record each frame of the video (v 1.9D does this wonderfully so that there are zero breaks from frame to frame) anyways. Also, a lot of programs don't include switching to the REF device when they error trap for shader2.0 support. A few do do that, like RTHDRIBL and the demos in the DX9 SDK, but things like 3DMark, or some nifty tech demos don't.

Share this post


Link to post
Share on other sites
You can just use software shaders to get the effect you want.

Just use:
ps_2_sw for software pixel shaders and vs_2_sw for software vertex shaders.

This will do everything you want to do.

Good luck.

Share this post


Link to post
Share on other sites
Quote:
Original post by Cypher19
The main reason I want to use it is because I only have a GeForce4 ti4400, so I'd like to experience PS2.0 graphics in some form.


Wouldn't it be easier to just visit a website and look at screenshots there. It will take several minutes to render a typical game scene using the ref device.

Share this post


Link to post
Share on other sites
Quote:
Original post by Coder
Quote:
Original post by darookie
Replace your gfx card with an S3 Trio [wink]

Actually, an S3 virge would do better here. [grin]


Hey, don't diss the Virge! [smile] I still have one of those, and I used to use it for my dual-monitor setup (until I got a 9800xt).

Quote:
It will take several minutes to render a typical game scene using the ref device.
The reference rasterizer is slow, but it's not *that* slow (unless your typical game scene is a radiosity simulator [wink]). I usually get from 1-4 fps, even with the high-end SDK samples.

Share this post


Link to post
Share on other sites
Quote:
Wouldn't it be easier to just visit a website and look at screenshots there.


I have yet to see a website that provides virtually lossless compressed or uncompressed video at 640x480 of the tests. If you have one, link me up in a heartbeat!

Powerwav: But what if some other issue comes up? Like, a check is done on the hardware caps as opposed to error trapping the effect generation?

Share this post


Link to post
Share on other sites
Everything that is done in hardware is done(emulated) in software. You can do everything that is avalible in pixel and vertex shader 2.0 by using software mode. You don't need to do hardware checks because it is irrelavant everything is available to you using the effect and setting it to the software version.

Hope this helps you out.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

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

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!