rwlogo

Rogue Wave Views
Foundation Package API Reference Guide

Product Documentation:

Rogue Wave Views
Documentation Home

 All Classes Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
List of all members | Public Member Functions
IlvPointLight Class Reference

Point Light. More...

#include <ilviews/bitmaps/filters/lights.h>

Inheritance diagram for IlvPointLight:
IlvLightSource IlvSpotLight

Public Member Functions

 IlvPointLight (IlFloat x=0.0, IlFloat y=0.0, IlFloat z=0.0, IlFloat r=1.0, IlFloat g=1.0, IlFloat b=1.0)
 Constructor. More...
 
void getLightVector (IlFloat x, IlFloat y, IlFloat z, IlFloat *result)
 Returns the vector from this instance to a given point in 3D space. More...
 
IlFloat getX () const
 Returns the x coordinate. More...
 
virtual void getXYZ (IlFloat &x, IlFloat &y, IlFloat &z) const
 Returns the position. More...
 
IlFloat getY () const
 Returns the y coordinate. More...
 
IlFloat getZ () const
 Returns the z coordinate. More...
 
void setX (IlFloat x)
 Sets the x coordinate. More...
 
virtual void setXYZ (IlFloat x, IlFloat y, IlFloat z)
 Sets the position. More...
 
void setY (IlFloat y)
 Sets the y coordinate. More...
 
void setZ (IlFloat z)
 Sets the z coordinate. More...
 
void update ()
 Called when the instance needs internal updating.
 
- Public Member Functions inherited from IlvLightSource
 IlvLightSource (IlFloat r=1.0, IlFloat g=1.0, IlFloat b=1.0)
 Constructor. More...
 
virtual ~IlvLightSource ()
 Destructor. More...
 
IlFloat getB () const
 Returns the blue component value. More...
 
IlFloat getG () const
 Returns the green component value. More...
 
IlFloat getR () const
 Returns the red component value. More...
 
void setB (IlFloat b)
 Sets the blue component value. More...
 
void setG (IlFloat g)
 Sets the green component value. More...
 
void setR (IlFloat r)
 Sets the red component value. More...
 

Detailed Description

Point Light.

Library: ilvbmpflt

This class allows you to model a positional light using three coordinates.

See Also
IlvDiffuseLightingFilter, IlvSpecularLightingFilter, IlvLightSource, IlvDistantLight, IlvSpotLight

Constructor & Destructor Documentation

IlvPointLight::IlvPointLight ( IlFloat  x = 0.0,
IlFloat  y = 0.0,
IlFloat  z = 0.0,
IlFloat  r = 1.0,
IlFloat  g = 1.0,
IlFloat  b = 1.0 
)

Constructor.

Initializes a new instance of the class IlvDistantLight.

The default position is <0,0,0>. The default light color is white.

Member Function Documentation

void IlvPointLight::getLightVector ( IlFloat  x,
IlFloat  y,
IlFloat  z,
IlFloat result 
)
virtual

Returns the vector from this instance to a given point in 3D space.

Parameters
xThe x position of the point.
yThe y position of the point.
zThe z position of the point.
resultAn array of 3 floating point values that will hold the vector.

Reimplemented from IlvLightSource.

Reimplemented in IlvSpotLight.

IlFloat IlvPointLight::getX ( ) const

Returns the x coordinate.

Returns
The x coordinate.
virtual void IlvPointLight::getXYZ ( IlFloat x,
IlFloat y,
IlFloat z 
) const
virtual

Returns the position.

Parameters
xThe x coordinate.
yThe y coordinate.
zThe z coordinate.
IlFloat IlvPointLight::getY ( ) const

Returns the y coordinate.

Returns
The y coordinate.
IlFloat IlvPointLight::getZ ( ) const

Returns the z coordinate.

Returns
The z coordinate.
void IlvPointLight::setX ( IlFloat  x)

Sets the x coordinate.

Parameters
xThe new x coordinate.
virtual void IlvPointLight::setXYZ ( IlFloat  x,
IlFloat  y,
IlFloat  z 
)
virtual

Sets the position.

Parameters
xThe x coordinate.
yThe y coordinate.
zThe z coordinate.
void IlvPointLight::setY ( IlFloat  y)

Sets the y coordinate.

Parameters
yThe new y coordinate.
void IlvPointLight::setZ ( IlFloat  z)

Sets the z coordinate.

Parameters
zThe new z coordinate.

© Copyright 2015, Rogue Wave Software, Inc. All Rights Reserved.
Rogue Wave is a registered trademark of Rogue Wave Software, Inc. in the United States and other countries. All other trademarks are the property of their respective owners.