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 / How to change skybox diameter in Advanced Lighting?

Author
Message
hakimfullmetal
9
Years of Service
User Offline
Joined: 17th Feb 2015
Location:
Posted: 15th Feb 2017 09:19 Edited at: 15th Feb 2017 09:22
Hello everybody.
I was trying to increase the size of the skybox in Advanced Lighting.
I was trying to create a sky, so I called Sky_Create() , set the texture, and update it.
But it seems that the 'sky' is actually as skybox object, and has a radius of about ~10000.
Any object past that range will not be visible.

How to change the radius of the skybox?
I went through the commands, but there are no commands for skybox radius?
I also tried to change some parameters on skybox scaling in 'AL_Sky.dba' , but it just won't appear right...

OR

Is there any way to make an object to NOT respond to Advanced Lighting fog?
If there is such a way, I can just use my own box as the sky instead.

Thanks in advance
WickedX
15
Years of Service
User Offline
Joined: 8th Feb 2009
Location: A Mile High
Posted: 15th Feb 2017 20:10 Edited at: 15th Feb 2017 20:13
I prefer to make my skyboxs as small as possible, just large enough so as it doesn't show in enclosed areas and position it along with the camera. You can do this by disabling the skybox objects zwrite. Doing this will give you a much sharper skybox. If you're also using a matrix terrain you will need to set its priority to 1 using - Set Matrix Priority. This is my method for setting up a skybox, which also answers your fog question.

hakimfullmetal
9
Years of Service
User Offline
Joined: 17th Feb 2015
Location:
Posted: 15th Feb 2017 22:20
I see. DISABLE OBJECT ZWRITE and SET OBJECT FOG works with default DBPro.
But when we're using Advanced Lighting, it seems that the object is still affected by AL fog despite the commands...
Ortu
DBPro Master
16
Years of Service
User Offline
Joined: 21st Nov 2007
Location: Austin, TX
Posted: 15th Feb 2017 22:45
What is your camera range set to in advance lighting? This may be the issue with non visible objects rather than the sky.

Looks like you can set ignore on blur, shadow and reflection, but does not look like there is an ignore for fog built in
http://games.joshkirklin.com/sulium

A single player RPG featuring a branching, player driven storyline of meaningful choices and multiple endings alongside challenging active combat and intelligent AI.
WickedX
15
Years of Service
User Offline
Joined: 8th Feb 2009
Location: A Mile High
Posted: 15th Feb 2017 23:06 Edited at: 16th Feb 2017 00:45
Are the object showing after disabling zwrite. What shader does the skybox use. Maybe able to use a different technique without fog.
hakimfullmetal
9
Years of Service
User Offline
Joined: 17th Feb 2015
Location:
Posted: 16th Feb 2017 03:07
Wait, you guys are correct.
I'm a freaking idiot.
It turns out that previously I was setting all of the camera range to 70,000, but using the default DBPro SET CAMERA RANGE command.
That works, and I can see up to 70,000 range, but that does not change the skybox or other AL components that depends on AL camera range.
I just set the camera range using ADVLIGHTING_SETCAMERA , and the issue is fixed. The skybox radius responded to that command.

Thank you for reminding me of that
Ortu
DBPro Master
16
Years of Service
User Offline
Joined: 21st Nov 2007
Location: Austin, TX
Posted: 16th Feb 2017 03:56
http://games.joshkirklin.com/sulium

A single player RPG featuring a branching, player driven storyline of meaningful choices and multiple endings alongside challenging active combat and intelligent AI.

Login to post a reply

Server time is: 2024-03-29 15:30:39
Your offset time is: 2024-03-29 15:30:39