Author Topic: glow points as light sources  (Read 1810 times)

0 Members and 1 Guest are viewing this topic.

glow points as light sources
Is it possible to use a glow point as a light source? like say I wanted to illuminate a name plate by positioning a glow point right above the texture.

 

Offline Topgun

  • 210
Re: glow points as light sources
no.
what you do is add lighting in a 3d app or gimp or photo shop or whatever and bake the lighting to a glow map.

 

Offline Snail

  • SC 5
  • 214
  • Posts: ☂
Re: glow points as light sources
How hard would it be from a coding perspective to make glow points actually emit a source of light? And thrusters?

(I'm assuming someone's going to say "impossibly hard", but it was worth asking)

 
Re: glow points as light sources
it'd prolly be extremely hard unless the glow point file itself can reference to light intensity... if not PCS would need to be reworked to support it as well as fred/fs

 

Offline Snail

  • SC 5
  • 214
  • Posts: ☂
Re: glow points as light sources
I'd have thought it would be possible, so that it uses a similar system to the way weapons fire casts light. But I'm no coder so I have no idea how it would be done, I'm just throwing around ideas.

I should stick to FREDding...

 

Offline Droid803

  • Trusted poster of legit stuff
  • 213
  • /人 ◕ ‿‿ ◕ 人\ Do you want to be a Magical Girl?
    • Skype
    • Steam
Re: glow points as light sources
That would make texturing easier :P
(´・ω・`)
=============================================================

 
Re: glow points as light sources
Also I believe Opengl only allows 9? light sources and they are rather process consuming.
That's cool and ....disturbing at the same time o_o  - Vasudan Admiral

"Don't play games with me. You just killed someone I like, that is not a safe place to stand. I'm the Doctor. And you're in the biggest library in the universe. Look me up."

"Quick everyone out of the universe now!"

 

Offline Flipside

  • əp!sd!l£
  • 212
Re: glow points as light sources
It's more a question of processing time, each light source adds another layer of computation for texture rendering. OpenGL supports something like 8 active hardware lightsources at one time iirc, which is enough for things like weapons, explosions etc, which are short-lived effects, but would soon run out if glowpoints were light sources.

That's why programs like Unreal Tournament pre-render most of the lighting effects on the levels.

Edit: As Scooby also says :)

 

Offline Snail

  • SC 5
  • 214
  • Posts: ☂
Re: glow points as light sources
Ok... So would it be possible to overlay a lighter texture over an existing hull texture, thus creating the illusion of a light source without actually doing it? Wait... That's a glowmap. D'oh.

 

Offline Nuke

  • Ka-Boom!
  • 212
  • Mutants Worship Me
Re: glow points as light sources
what is needed is a system to toggle on and off light sources based on their visibility to the player. so only the most visible 8 sources are used with hardware lighting. then you combine that with a faster, lower quality lighting effects for things like weapons and whatnot, to fill in the background. so every time you get ready to do lighting computation, a list of sources is sorted by distance from the camera * size higher numbers taking the hardwre lights, and lower numbers either using the software lighting or no lighting at all. the idea is if you fill up the foreground, your eyes are distracted from the lack of lighting in the background.
« Last Edit: August 15, 2008, 08:53:32 am by Nuke »
I can no longer sit back and allow communist infiltration, communist indoctrination, communist subversion, and the international communist conspiracy to sap and impurify all of our precious bodily fluids.

Nuke's Scripting SVN

 

Offline Getter Robo G

  • 211
  • Elite Super Robot Pilot
Re: glow points as light sources
You can fake it with a glow map, have your area with a illuminated spot and put your light source around it at the right angle you want to pretend it's casting it... That's what I did with irfranview, but then again I have no skills... :)
"Don't think of it as being out-numbered, think of it as having a WIDE target selection!"

"I am the one and ONLY Star Dragon..."
Proof for the noobs:  Member Search

[I'm Just an idea guy, NOT: a modeler, texturer, or coder... Word of advice, "Watch out for the ducks!"]

Robotech II - Continuing...
FS2 Trek - Snails move faster than me...
Star Blazers: Journey to Iscandar...
FS GUNDAM - The Myth lives on... :)

  

Offline Bobboau

  • Just a MODern kinda guy
    Just MODerately cool
    And MODest too
  • 213
Re: glow points as light sources
jees, ok here's how FS handles lights, only the max number of supported hardware lights can be used  at a time the max number of lights is not MORE than 8. when  more than this number of lights needs to be drawn what it does is it switches to additive alpha after a pass with the first test and does consecutive sets after that untill all lights are drawn.

strictly speaking adding lights is not too hard and it could be done with justs a few lines of code, but a better way of doing this is to have all the static lights precalculated on a texture (which allows as great of lighting calculation precision as you could ever ask for) and apply this on the first lighting pass. this is what glow maps are.
Bobboau, bringing you products that work... in theory
learn to use PCS
creator of the ProXimus Procedural Texture and Effect Generator
My latest build of PCS2, get it while it's hot!
PCS 2.0.3


DEUTERONOMY 22:11
Thou shalt not wear a garment of diverse sorts, [as] of woollen and linen together