Gamestudio Links
Zorro Links
Newest Posts
Zorro 2.70
by jcl. 09/29/25 09:24
optimize global parameters SOLVED
by dBc. 09/27/25 17:07
ZorroGPT
by TipmyPip. 09/27/25 10:05
assetHistory one candle shift
by jcl. 09/21/25 11:36
Plugins update
by Grant. 09/17/25 16:28
AUM Magazine
Latest Screens
Rocker`s Revenge
Stug 3 Stormartillery
Iljuschin 2
Galactic Strike X
Who's Online Now
1 registered members (AndrewAMD), 14,661 guests, and 5 spiders.
Key: Admin, Global Mod, Mod
Newest Members
krishna, DrissB, James168, Ed_Love, xtns
19168 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Light Position to shader #154230
09/14/07 21:54
09/14/07 21:54
Joined: Jun 2004
Posts: 21
SLOVAKIA
AndyGFX Offline OP
Newbie
AndyGFX  Offline OP
Newbie

Joined: Jun 2004
Posts: 21
SLOVAKIA
Howto send light position from level to shader via script? I found howto assing texture but nothing about lights (little sample pls. )

Re: Light Position to shader [Re: AndyGFX] #154231
09/15/07 05:26
09/15/07 05:26
Joined: Oct 2003
Posts: 4,131
M
Matt_Aufderheide Offline
Expert
Matt_Aufderheide  Offline
Expert
M

Joined: Oct 2003
Posts: 4,131
float4 vecLightPos[8]
float4 vecLightColor[8]

these float arrays are passed into the material automatically, just declare them and use...


Sphere Engine--the premier A6 graphics plugin.
Re: Light Position to shader [Re: Matt_Aufderheide] #154232
09/15/07 20:52
09/15/07 20:52
Joined: Jun 2004
Posts: 21
SLOVAKIA
AndyGFX Offline OP
Newbie
AndyGFX  Offline OP
Newbie

Joined: Jun 2004
Posts: 21
SLOVAKIA
If i good understand, is possible passed first 8 lights from scene to shader? Or if i set this vector in script (vecLightPos,vecLightColor) then is included automaticaly to the shader?

Sorry but in manual missing more information about this.

Re: Light Position to shader [Re: AndyGFX] #154233
09/16/07 18:55
09/16/07 18:55
Joined: Jan 2003
Posts: 4,615
Cambridge
Joey Offline
Expert
Joey  Offline
Expert

Joined: Jan 2003
Posts: 4,615
Cambridge
that's correct.


Moderated by  Blink, Hummel, Superku 

Gamestudio download | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1