Archived

This topic is now archived and is closed to further replies.

I propose a simple DX theory!

This topic is 5011 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Regarding lighting passing through objects and how to stop it. I posted a topic asking how to stop lighting passing through things but without doing stencil shadows etc Somebody responded saying that at the present time, lighting is hard to control in DX. I though of a general idea and that is: 1: Like stencil buffering, a ray can be traced from the light to the object in question and have a value regarding whether it has already passed through anything. 2: Even after calculating this the light would still show. Would it now be possible with the modern computers of today, to modify the properties of the material and texture through blending so that it appears as though the light isnt affecting it. ie making the colour darker so that when its lit it will be the normal colour again. 3: I know for now this would be computationaly expensive. 4: All that it would require would be undoing what the lighting functions in DX do. What do you think? ACE PS Just an idea, slag off at will.

Share this post


Link to post
Share on other sites
Seeing as all that would achieve would be a method of shadowing that would run rather slowly and not look as good as either stencil shadowing or shadow mapping seeing as you''d have to do it pervertex I don''t really see the point. What''s wrong with just using stencil shadowing?

Share this post


Link to post
Share on other sites
quote:
Original post by ace_lovegrove

a ray can be traced from the light to the object in question and have a value regarding whether it has already passed through anything.



This is extremely processor-intensive operation (ray tracing, that is). Remember that you''d need to trace very many rays to cover objects generally.

Stencil shadows are widely supported in hardware nowadays. I suggest you use them in shadowing. There is also the option of using shadow maps, but the number of cards that support it on-chip is slightly smaller.

-Nik

Share this post


Link to post
Share on other sites