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.

DarkBASIC Professional Discussion / Problem with shadow color

Author
Message
Jordi
15
Years of Service
User Offline
Joined: 20th Feb 2011
Location:
Posted: 20th Feb 2011 14:16
Hello people,

I have problem with shadow color using the shadow shading function.

The color of shadow is the same of the fog color. I try to use the function set global shadow color but the color don't change if I use fog.

How I can fix this problem ?

I use dbpro with the last update.

Thanks for help me

NURENDSOFT: Videogames for all.
Mr Bigger
21
Years of Service
User Offline
Joined: 31st Jan 2005
Location: was here!
Posted: 21st Feb 2011 00:58 Edited at: 21st Feb 2011 01:03
Hi Jordi,
You could try increasing the minimum fog range as it may be over powering the shadow color.

I would also suggest that the object your casting the shadow and fog onto be sufficiently high poly.

AMD 2600+/1GB ram/GeForce 6600oc 256MB/W2KPro/DBPro 6.6.b
Jordi
15
Years of Service
User Offline
Joined: 20th Feb 2011
Location:
Posted: 21st Feb 2011 10:14
Hi Mr Bigger,

Thanks for your answer.

How I increase the minimum fog range ? Using the "fog distance" function ?

The object have more then 5.000 polys.

Another question, I use 1 camera to make the water effect. Is possible that this camera can affect the shadow color ? I can configure the fog for other cameras ?

NURENDSOFT: Videogames for all.
Green Gandalf
VIP Member
21
Years of Service
User Offline
Joined: 3rd Jan 2005
Playing: Malevolence:Sword of Ahkranox, Skyrim, Civ6.
Posted: 21st Feb 2011 14:44
I can't get fog and shadows to work correctly together either - and changing the fog range doesn't solve the problem.
Mr Bigger
21
Years of Service
User Offline
Joined: 31st Jan 2005
Location: was here!
Posted: 21st Feb 2011 22:53
Quote: "How I increase the minimum fog range ? Using the "fog distance" function ?
"

Yes. The format would be Fog Distance min./max.

I am not sure about the effect of adding cameras, i suspect it would be a problem as no commands exist to set the fog and shadows with any particular camera. Custom shaders would do it i suppose.

Here is a simple example of fog and shadow working together.


This should have a blue shadow with red fog in the distance.

This is just to establish that the basics are similarly functional on both of our computers.

AMD 2600+/1GB ram/GeForce 6600oc 256MB/W2KPro/DBPro 6.6.b
Green Gandalf
VIP Member
21
Years of Service
User Offline
Joined: 3rd Jan 2005
Playing: Malevolence:Sword of Ahkranox, Skyrim, Civ6.
Posted: 21st Feb 2011 23:07 Edited at: 21st Feb 2011 23:07
Quote: "This should have a blue shadow with red fog in the distance."


Maybe, but this is what I get. What do you get? I'm using U7.7RC6 on Vista 64bit.

Mr Bigger
21
Years of Service
User Offline
Joined: 31st Jan 2005
Location: was here!
Posted: 21st Feb 2011 23:39
I am using version 6.2 on w2k. Screenshot below.

Looks like a possible bug in your version.

AMD 2600+/1GB ram/GeForce 6600oc 256MB/W2KPro/DBPro 6.6.b
Green Gandalf
VIP Member
21
Years of Service
User Offline
Joined: 3rd Jan 2005
Playing: Malevolence:Sword of Ahkranox, Skyrim, Civ6.
Posted: 22nd Feb 2011 00:38
Interesting. I wonder when it was introduced. I'll investigate. Could be a system problem. I'll check my XP laptop as well.
Green Gandalf
VIP Member
21
Years of Service
User Offline
Joined: 3rd Jan 2005
Playing: Malevolence:Sword of Ahkranox, Skyrim, Civ6.
Posted: 22nd Feb 2011 00:45
Looks like the bug was introduced some time after U7.5beta16. I'll report it. Thanks.
Jordi
15
Years of Service
User Offline
Joined: 20th Feb 2011
Location:
Posted: 22nd Feb 2011 13:07
Thanks for the example Mr Bigger. Is very useful.

I have the bug too.

The only way to correct the bug is wait to new update, yes?

NURENDSOFT: Videogames for all.
Mr Bigger
21
Years of Service
User Offline
Joined: 31st Jan 2005
Location: was here!
Posted: 23rd Feb 2011 00:57
Quote: "The only way to correct the bug is wait to new update, yes?"


You could wait for the fix or revert to a version before the bug.

I usually keep two versions and use the one that has the least amount of bugs depending on the commands that i use in my current project.

AMD 2600+/1GB ram/GeForce 6600oc 256MB/W2KPro/DBPro 6.6.b
Jordi
15
Years of Service
User Offline
Joined: 20th Feb 2011
Location:
Posted: 23rd Feb 2011 11:16
Ok Thanks again.

One last question about the shadows shading, is possible ignore some objects that receive the shadow ?

The shadow effect is ok in the stage but in the object, in this case the player model, this effect is not well.

NURENDSOFT: Videogames for all.
Mr Bigger
21
Years of Service
User Offline
Joined: 31st Jan 2005
Location: was here!
Posted: 23rd Feb 2011 18:01
Quote: "possible ignore some objects that receive the shadow ?"


Thats a good question but i can't think of any way.

Using a high poly animated character to cast a shadow will not work very well. I would use a low poly dummy object to cast the shadow. Animate it with the same bones as the main object in the same position and hide all of the limbs.

AMD 2600+/1GB ram/GeForce 6600oc 256MB/W2KPro/DBPro 6.6.b
Jordi
15
Years of Service
User Offline
Joined: 20th Feb 2011
Location:
Posted: 24th Feb 2011 10:49
OK

Good idea, because in my project I use some models with shadow and the frame rate are very low when all the shadows are active

thanks Mr Bigger

NURENDSOFT: Videogames for all.

Login to post a reply

Server time is: 2026-07-17 14:00:07
Your offset time is: 2026-07-17 14:00:07