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 / Black light produces weird result

Author
Message
Philip
23
Years of Service
User Offline
Joined: 15th Jun 2003
Location: United Kingdom
Posted: 10th Nov 2003 16:43
Now this is something I genuinely fail to understand.

Regular readers will recall I recently posted on the subject of shadows and shadow shading. After posting that thread, I encountered a thread in the Dark Basic forum in which someone spoke of using a light with the colour black to cast a fake shadow. So I thought I'd give it a go. See attached code.

The weird thing is that having created light 1 I see it actually BRIGHTENS the other half of the sphere (the half towards the gold box). Surely this is irrational? A black light should by definition make things darker, or at least, not any lighter.

Could this be a bug? Thoughts?

Philip

What do you mean, bears aren't supposed to wear hats and a tie?
heartbone
23
Years of Service
User Offline
Joined: 9th Nov 2002
Location:
Posted: 10th Nov 2003 16:50 Edited at: 10th Nov 2003 16:50
Actually black light would make it brighter if the sphere has a phosphorescent or florescent coating.

I think that DB objects exhibit florescence.

The more you see, the more you know.
The more you know, the more you see.
Philip
23
Years of Service
User Offline
Joined: 15th Jun 2003
Location: United Kingdom
Posted: 10th Nov 2003 16:57
Right. Ok. How do I make it *darker*???

Ta

Philip

What do you mean, bears aren't supposed to wear hats and a tie?
Scraggle
Moderator
23
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 10th Nov 2003 20:09
Kick me if I'm wrong but I believe that SET OBJECT AMBIENCE will do the trick.

My latest project has no name - feel free to suggest one. Think 'Lunar Lander' with multiplayer, guns and bombs!

AlecM
23
Years of Service
User Offline
Joined: 26th Aug 2002
Location: Concord, MA
Posted: 11th Nov 2003 03:48
A black light (as in a light at 0,0,0) Won't affect anything. Thats like saying you want to shine nothing on something. I have never tested this in DBP but in any render engine or other enviroment I have seen a light with no value does nothing. If you want a light to suck up other light try a negative light source. I don't think this is possible in DB though.

[P4 2.8C @ 3.03 with an 866mhz FSB:: MSI Neo-2LS running PAT:: 1gb Mushkin PC-3500 DDR High Perf level 2@ 2,2,2 :: ATI Radeon9800ProAIW :: 120Gb SeagateBarracuda 7,200RPM SATA HD :: Antec Plus1080AMG]
Xander
23
Years of Service
User Offline
Joined: 3rd Mar 2003
Location: In college...yeah!
Posted: 11th Nov 2003 05:49
YES! A negative light source is possible. An example comes with DB.

Set the light color to rgb(-255,-255,-255)

Xander - Bolt Software

Why do the antagonists always have to look so cool?
Philip
23
Years of Service
User Offline
Joined: 15th Jun 2003
Location: United Kingdom
Posted: 11th Nov 2003 15:43
Ok. Things have now gotten weirder.

In the attached code I've tried to make a spot light that shines the negative light rgb(-255, -255, -255) at the yellow box. Yet, despite that it is supposedly pointing at the yellow screen, it actually lights up the reverse side of the sphere, which is on the opposite side to the angle the spot is pointing.

Even stranger, if I turn the spot into a point light, it still lights up the closest side of the sphere, just like the code posted above.

Am I missing something fundamental here???

Cheers

Philip

What do you mean, bears aren't supposed to wear hats and a tie?
Philip
23
Years of Service
User Offline
Joined: 15th Jun 2003
Location: United Kingdom
Posted: 11th Nov 2003 15:44
PS: I thought I'd try shining a brown light on the yellow box - rgb(128, 042, 042) - but that had no effect at all.

What do you mean, bears aren't supposed to wear hats and a tie?

Login to post a reply

Server time is: 2026-07-26 17:33:24
Your offset time is: 2026-07-26 17:33:24