Delgine 3D Tools & Content DeleD Community Edition
Forums
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Texture lights.

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    DeleD Community Edition Forum Index -> DeleD Feature Requests
View previous topic :: View next topic  
Author Message
Timpuktu
Member


Joined: 09 Aug 2004
Posts: 86
Location: Finland, Helsinki

PostPosted: Mon Nov 20, 2006 3:02 pm    Post subject: Texture lights. Reply with quote

It would be great that if you could setup textures to emit light. So you would not need to add light for each texture which sould emit light.

In Quake Engine there is file called lights.rad that has information of texture lights. (or atleast in HL1 has it, when you use Zoners Compiler Tools).

Example:
wall_light01 255 255 255 200

First part is texture name, next three values is light color and last value is amount of light it emits.

My idea is that you could setup textures that emits light in material editor, like givin color value and amount of light it sould emit.

- Timpuktu
_________________
Life is a waste of time, time is a waste of life. Get wasted all the time and you have the time of your life.
Back to top
View user's profile Send private message MSN Messenger
Paul-Jan
Site Admin


Joined: 08 Aug 2004
Posts: 3066
Location: Lage Zwaluwe

PostPosted: Wed Nov 22, 2006 7:43 pm    Post subject: Reply with quote

Interesting thought!

However, would that imply that _all_ of the object wrapped in that texture emits light? That would be a major step beyond area lights (multisampling for soft shadows... something DeleD doesn't have yet), so I don't think that's the way the old quake engines did things (would rocket rendering times sky high). More probably the brush wrapped in the texture is used as the position for an 'automatic' light source.

I'll read into this. There are also techniques that use 'light maps', where each textel determines how much light (and what color) is emitted from that position.
Back to top
View user's profile Send private message Visit poster's website
Daaark
DeleD PRO user


Joined: 01 Sep 2004
Posts: 2696
Location: Ottawa, Canada

PostPosted: Wed Nov 22, 2006 8:54 pm    Post subject: Reply with quote

?

Yeah that woudl be a great feature. In Embrace, I used to just set my flurescant light textyres to emite light instead of having a point light under the lights, it gave a lot better results.

It's also good when you have a light on the wall. The light can just shine down insteadf in a big globe.
_________________
Back to top
View user's profile Send private message Send e-mail Visit poster's website MSN Messenger
trucker2000
DeleD PRO user


Joined: 11 May 2005
Posts: 1839
Location: Sacramento, California

PostPosted: Wed Nov 22, 2006 11:18 pm    Post subject: Reply with quote

I would love to see this feature. Smile
In any light, there will be more than one texture.
IE:
1. lamp texture
2. bulb texture

A setting in the inspector could set the particular texture on the object to emit light. Smile
_________________
Some day I will grow up and be a real modeler.
"Never give up! Never surrender!!"
Sys specs:
asus
8 gigs ram
Invidia gtx560 video card
Windows 8 (worst op sys Ever)
Back to top
View user's profile Send private message Visit poster's website
afecelis
DeleD PRO user


Joined: 08 Aug 2004
Posts: 427
Location: Colombia

PostPosted: Thu Nov 23, 2006 5:15 am    Post subject: Reply with quote

I'd like this feature, or internal area lights that could be sized/scaled as squares/rectangles. Wink
Back to top
View user's profile Send private message Send e-mail Visit poster's website
jwatte
DeleD PRO user


Joined: 26 Apr 2006
Posts: 513

PostPosted: Sun Nov 26, 2006 12:17 am    Post subject: Reply with quote

Once you do a radiosity solution, light-emitting faces comes pretty much for free. Before then, well, the math is the same as for radiosity, so that's what you'd be implementing :-)

One thing you can do to accelerate light mapping is to use the hardware. Divide all geometry coarsely into cells, and render all cells between the source and the destination into each destination triangle, from each source light source or triangle. If you have real cells/portals, this can be made faster through culling, too -- else, make sure you don't set light ranges too far.

If you want to be really fancy, you set a rendertarget per pixel in the light map, and render the geometry in question into that pixel in accumulation mode. Or, more likely, keep a larger render target, render everything, and when you're done, downsample to the target pixel. Floating point frame buffers with accumulation makes this a lot easier, too.
Back to top
View user's profile Send private message
Paul-Jan
Site Admin


Joined: 08 Aug 2004
Posts: 3066
Location: Lage Zwaluwe

PostPosted: Sun Nov 26, 2006 12:02 pm    Post subject: Reply with quote

Quote:
Once you do a radiosity solution, light-emitting faces comes pretty much for free. Before then, well, the math is the same as for radiosity, so that's what you'd be implementing


Ah, sweet, you are completely right of course. Thanks for the pointer!

Your points about hardware accelerated light mapping are also interesting. Any clue on how well this would scale onto older hardware? I've always shied away from hardware acceleration in this department because I was under the impression that a solid software rendered fallback would be needed anyway (so I'd rather postpone hardware acceleration until the software renderer reaches some sort of 'final' state), but perhaps my beliefs are outdated!
Back to top
View user's profile Send private message Visit poster's website
jwatte
DeleD PRO user


Joined: 26 Apr 2006
Posts: 513

PostPosted: Mon Nov 27, 2006 7:32 pm    Post subject: Reply with quote

I think that anything with hardware transform and lighting (back to original Radeon and GeForce) would do OK with hardware assisted light map calculation. However, I've only actually read code that did this, I've never tried it myself, so don't take what I say as gospel :-)

Btw: As you know, I think the light mapping in DeleD is not its most important feature. I've recently started generating lighting maps in 3dsmax, and it has some awesome abilities (photon mapping, radiosity, sky lights, etc) but it's also quite slow. It does support networked render clusters, though :-) Hence, however, the separate question about the Collada exporter.
Back to top
View user's profile Send private message
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    DeleD Community Edition Forum Index -> DeleD Feature Requests All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum