Please login or register.

Login with username, password and session length
Advanced search  

News:

IRC channel - server: waelisch.de  channel: #wme (read more)

Author Topic: Dynamic Shadows  (Read 5429 times)

0 Members and 1 Guest are viewing this topic.

Rave-n

  • Lurker
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 6
    • View Profile
Dynamic Shadows
« on: September 16, 2007, 07:52:24 AM »

Hi all,

  is it possible do you think to update actor.SetLightPosition as the actor moves with relation to a light source position sourced directly from the 3d geometry using a method like GetNode or something. This would enable dynamic shadows on the actor which would look GREAT!

Cheers.
Logged

Derrek3D

  • Occasional poster
  • **
  • Karma: 0
  • Offline Offline
  • Posts: 82
    • View Profile
Re: Dynamic Shadows
« Reply #1 on: September 16, 2007, 09:51:30 AM »

Take a look at the third post in the following thread http://forum.dead-code.org/index.php?topic=1801.0. ErV gives the general idea of how to use dynamic shadows using the 3D lights from the scene geometry.

Please note that he is using his own plugin for extracting the 3D lights from the scene geometry but that functionality has since been made available to the scripting engine and you can use a loop from 0 to Scene.NumLights-1 to extract all lights using Scene.GetLightName() and there is no need for a specialized plugin anymore.
Logged

Rave-n

  • Lurker
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 6
    • View Profile
Re: Dynamic Shadows
« Reply #2 on: September 17, 2007, 07:44:42 AM »

Is there an updated version of the help file because there's no mention of those methods in the help file?
EDIT:
Ahh, would help if I were using the lates beta I see... not 1.7...  :P
« Last Edit: September 17, 2007, 07:55:19 AM by Rave-n »
Logged

Rave-n

  • Lurker
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 6
    • View Profile
Re: Dynamic Shadows
« Reply #3 on: September 17, 2007, 08:37:35 AM »

Okay - So I can get the name of the light, but there's no info attached to it, and I can't use Scene.GetNode(LightName) that just return NULL...
How are you meant to extract the info out of the node once you have the name?
Logged

Derrek3D

  • Occasional poster
  • **
  • Karma: 0
  • Offline Offline
  • Posts: 82
    • View Profile
Re: Dynamic Shadows
« Reply #4 on: September 17, 2007, 12:27:13 PM »

It would seem that the functionality you require is indeed missing, or at least I can't find it. It should have been something like Scene.GetLightPosition(LightName) but there is no such thing that I can find. Maybe someone else will be able to help more.
Logged

Derrek3D

  • Occasional poster
  • **
  • Karma: 0
  • Offline Offline
  • Posts: 82
    • View Profile
Re: Dynamic Shadows
« Reply #5 on: September 20, 2007, 03:48:44 PM »

Can someone please confirm that there really isn't any way today to extract the position of a 3D light from the scene geometry? If that's the case, can this thread be moved to the Feature requests?

I tried dynamic shadows using a hard-coded 3D light position and it worked beautifully! So I thought it could be even greater if I could take the light position directly from the scene itself without having to make it hard-coded in each and every one of the scenes.
Logged

Mnemonic

  • WME developer
  • Administrator
  • Addicted to WME forum
  • *
  • Karma: 41
  • Offline Offline
  • Gender: Male
  • Posts: 5683
    • View Profile
    • Dead:Code Site
Re: Dynamic Shadows
« Reply #6 on: September 20, 2007, 04:58:48 PM »

I can confirm it's not possible at the time being. Moving the thread.
Logged
Yes, I do have a twitter account
Please don't send me technical questions in private messages, use the forum. ::wave
 

Page created in 0.106 seconds with 23 queries.