Sign in to follow this  
Erzengeldeslichtes

DX9.0c No Light?

Recommended Posts

I didn't see anything in the docs about removing the FFP like DXNext is supposed to, and I'm using the FFP since I have no clue how to use shaders, but when I just recompiled my (mostly) working engine in the latest update, suddenly no light. It had light in my last build on 9.0b, then I uninstalled b and installed c. I changed nothing, but now my directional light and ambient light (TBS doesn't need much more than that) aren't working. I've triple checked the colors, materials, made sure it's on, but bleh. Is there something I missed in the documentation that I need to make it work? Do I actually need to implement a few of these examples from "The Cg Tutorial" book I have? Thanks for any information.

Share this post


Link to post
Share on other sites
Trip99    577
Are you using fx files? There is a bug in 9.0c with the fixed function matrices. From DirectXDev list (by Craig Peeper):

Quote:


There is a bug in the Summer Update 2004 in regards to fixed function matrices. The transpose of a matrix is set instead of the matrix.

The bug affects the following states being set inside a technique:
TextureTransform
WorldTransform
ViewTransform
ProjectionTransform

You can workaround this in the effect file by doing a transpose on the line to set or in your app.
i.e.
TextureTransform[0] = (transpose(TestMatrix));

This will be fixed in an future update.

Share this post


Link to post
Share on other sites
Nope, I'm doing IDirect3DDevice9::SetTransform(TransformType, &Matrix)...

As far as I can tell my models are displaying fine, because the sillohette looks right (I'm only displaying a model on a blue screen right now, for testing), it's just the model is all black.

Share this post


Link to post
Share on other sites
Trip99    577
I wonder then if it is a bug in your code that has only come to light(!) with the installation of the new SDK. e.g. the new SDK may have different defaults for some parameter that you are not setting. Difficult to say more without code to look at.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this