Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark GDK / Additional Lightmap Stage for Defered Shading

Red Eye
Years of Service
User Offline
Joined: 15th Oct 2008
Posted: 15th Nov 2012 14:41 Edited at: 15th Nov 2012 15:03
Hey there fellow game developers,

So I got Deferred Shading to work with .DBO level files. But got one problem. I tried to add a Lightmap stage to the original .fx file ( which is attached to this post ) but failed.

So here is how I did it:

First I added this:


Next I went to the float4 PS function , and added here a new parameter, Tex1:texcoord1 .

I used this parameter in the same function. Here is the full edited float4 PS function:


After done and saved, I textured my object limb with a lightmap texture on Stage 5, like this:


The deferred shading kept working , altough the brithness of the entire object seemed to be very high, and no lightmap whatsoever was applied.

Is there something I am doing wrong in the HLSL shader?



EDIT: I figured texcoord1 (in the parameter of the PS function should be texcoord5 as the 5th stage is being used. But does not work.


Login to view attachments

Login to post a reply

Server time is: 2024-04-13 04:22:15
Your offset time is: 2024-04-13 04:22:15