Lighting bug?

I've been trying to get PointLights to work and haven't had ANY luck. I went ahead and copied a sample that I found from these forums, and noticed that it didn't work either. Is anyone else having this issue? I'm on a MacBook Pro (Intel based), running the latest LWJGL 1.0beta (for the Intel Mac compiled libraries).

Open a call hierachy for the PointLight constructor and you can see a lot of tests using it. Eg. TestSimpleGame. A good one with a LightNode (very useful) is TestBezierMesh.

(and they work fine here).

Yep the TestBezierMesh works just fine. Must have been both my code and the one I found in the forum.  :stuck_out_tongue:

I keep having problems running into NullPointerExceptions on updates. I guess I'm having a hard time understanding what node to access and when.  :expressionless:

Also, does the flagrush tutorial #9 actually render any shadows for you? I can't seem to get those to work either.  :frowning:

Yes (the bike itself has a shadow).

I'm not seeing it. :frowning:

Do you see the shawdow tweaker Swing window? (run flagrush in windowed mode). Maybe you can get it to work with different settings.

I've fiddled with the settings quite a bit… no shadows. :frowning:

Are you also on a MacBookPro?

Also, I ran TestShadowPass, and there are shadows on the player node (although the pilon shadows keep disappearing off and on).

No I'm not. Renanse made the shadow code, and he has a Mac (not intel though afaik).

Ok… I just tested it on my windows partition (using BootCamp on the machine). Shadows worked perfect. So I'm guessing it must be a Mac thing.  :expressionless:

one problem we've seen with shadows is that you need to have the stencil buffer available to do them.  On some OSes/cards, you get a stencil buffer with the default jme code.  On others you don't.  So what you have to do is tell jme to guarentee that.  Lesson9 was not doing that.  I've checked in a change for that locally which should go into cvs soon.

In BaseSimpleGame derivitives you can do it in your class constructor like so:

stencilBits = 8;

In other game types, remember it must be set before the renderer is created.

PS: I just verified that Lesson9 was running without shadows on my powerbook.  Updating with the code I placed in cvs though brought them back.

That said, I'm pretty unhappy with the constant log messages generated in shadows and will be moving on fixing those now.

Great! I just got the updated CVS and works great!