Class: ShadowReceiver

ShadowReceiver(theReceiverObject) → {ShadowReceiver}

Support class for a GameObject having shadows cast on it. Has only one target object, but supports several casters

Found in Chapter 8, page 507 of the textbook

Example: 8.7 Shadow Shaders

Constructor

new ShadowReceiver(theReceiverObject) → {ShadowReceiver}

Parameters:
Name Type Description
theReceiverObject GameObject the GameObject that will have shadows cast onto it
Source:
Returns:
a new ShadowReceiver instance
Type
ShadowReceiver

Methods

addShadowCaster(lgtRenderable)

Using argument lgtRenderable as casting object for a new ShadowCaster to add to this ShadowReceiver's list
Parameters:
Name Type Description
lgtRenderable GameObject GameObject that contains at least a LightRenderable to cast shadow
Source:

draw(aCamera)

Draw the receiver GameObject of this ShadowReceicer with the shadow cast onto it
Parameters:
Name Type Description
aCamera Camera the Camera to draw to
Source:

update()

Update the receiving GameObject
Source: