VTK  9.3.20240425
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
vtkLightKit Class Reference

a simple but quality lighting kit More...

#include <vtkLightKit.h>

Inheritance diagram for vtkLightKit:
[legend]
Collaboration diagram for vtkLightKit:
[legend]

Public Types

enum  LightKitType { TKeyLight , TFillLight , TBackLight , THeadLight }
 
enum  LightKitSubType {
  Warmth , Intensity , Elevation , Azimuth ,
  KFRatio , KBRatio , KHRatio
}
 
typedef vtkObject Superclass
 

Public Member Functions

virtual vtkTypeBool IsA (const char *type)
 Return 1 if this class is the same type of (or a subclass of) the named class.
 
vtkLightKitNewInstance () const
 
void PrintSelf (ostream &os, vtkIndent indent) override
 Methods invoked by print to print information about the object including superclasses.
 
virtual void SetFillLightWarmth (double)
 
virtual double GetFillLightWarmth ()
 
virtual void SetHeadLightWarmth (double)
 
virtual double GetHeadLightWarmth ()
 
virtual void SetBackLightWarmth (double)
 
virtual double GetBackLightWarmth ()
 
void SetKeyLightAngle (double elevation, double azimuth)
 Get/Set the position of the key, fill, and back lights using angular methods.
 
void SetKeyLightAngle (double angle[2])
 
void SetKeyLightElevation (double x)
 
void SetKeyLightAzimuth (double x)
 
virtual double * GetKeyLightAngle ()
 
virtual void GetKeyLightAngle (double data[2])
 
double GetKeyLightElevation ()
 
double GetKeyLightAzimuth ()
 
void SetFillLightAngle (double elevation, double azimuth)
 
void SetFillLightAngle (double angle[2])
 
void SetFillLightElevation (double x)
 
void SetFillLightAzimuth (double x)
 
virtual double * GetFillLightAngle ()
 
virtual void GetFillLightAngle (double data[2])
 
double GetFillLightElevation ()
 
double GetFillLightAzimuth ()
 
void SetBackLightAngle (double elevation, double azimuth)
 
void SetBackLightAngle (double angle[2])
 
void SetBackLightElevation (double x)
 
void SetBackLightAzimuth (double x)
 
virtual double * GetBackLightAngle ()
 
virtual void GetBackLightAngle (double data[2])
 
double GetBackLightElevation ()
 
double GetBackLightAzimuth ()
 
void DeepCopy (vtkLightKit *kit)
 
void Modified () override
 Update the modification time for this object.
 
void Update ()
 
virtual void SetKeyLightIntensity (double)
 Set/Get the intensity of the key light.
 
virtual double GetKeyLightIntensity ()
 Set/Get the intensity of the key light.
 
virtual void SetKeyToFillRatio (double)
 Set/Get the key-to-fill ratio.
 
virtual double GetKeyToFillRatio ()
 Set/Get the key-to-fill ratio.
 
virtual void SetKeyToHeadRatio (double)
 Set/Get the key-to-headlight ratio.
 
virtual double GetKeyToHeadRatio ()
 Set/Get the key-to-headlight ratio.
 
virtual void SetKeyToBackRatio (double)
 Set/Get the key-to-back light ratio.
 
virtual double GetKeyToBackRatio ()
 Set/Get the key-to-back light ratio.
 
virtual void SetKeyLightWarmth (double)
 Set the warmth of each the lights.
 
virtual double GetKeyLightWarmth ()
 Set the warmth of each the lights.
 
virtual double * GetKeyLightColor ()
 Returns the floating-point RGB values of each of the light's color.
 
virtual void GetKeyLightColor (double data[3])
 Returns the floating-point RGB values of each of the light's color.
 
virtual double * GetFillLightColor ()
 Returns the floating-point RGB values of each of the light's color.
 
virtual void GetFillLightColor (double data[3])
 Returns the floating-point RGB values of each of the light's color.
 
virtual double * GetHeadLightColor ()
 Returns the floating-point RGB values of each of the light's color.
 
virtual void GetHeadLightColor (double data[3])
 Returns the floating-point RGB values of each of the light's color.
 
virtual double * GetBackLightColor ()
 Returns the floating-point RGB values of each of the light's color.
 
virtual void GetBackLightColor (double data[3])
 Returns the floating-point RGB values of each of the light's color.
 
virtual void MaintainLuminanceOn ()
 If MaintainLuminance is set, the LightKit will attempt to maintain the apparent intensity of lights based on their perceptual brightnesses.
 
virtual void MaintainLuminanceOff ()
 If MaintainLuminance is set, the LightKit will attempt to maintain the apparent intensity of lights based on their perceptual brightnesses.
 
virtual vtkTypeBool GetMaintainLuminance ()
 If MaintainLuminance is set, the LightKit will attempt to maintain the apparent intensity of lights based on their perceptual brightnesses.
 
virtual void SetMaintainLuminance (vtkTypeBool)
 If MaintainLuminance is set, the LightKit will attempt to maintain the apparent intensity of lights based on their perceptual brightnesses.
 
void AddLightsToRenderer (vtkRenderer *renderer)
 Add lights to, or remove lights from, a renderer.
 
void RemoveLightsFromRenderer (vtkRenderer *renderer)
 Add lights to, or remove lights from, a renderer.
 
- Public Member Functions inherited from vtkObject
 vtkBaseTypeMacro (vtkObject, vtkObjectBase)
 
virtual void DebugOn ()
 Turn debugging output on.
 
virtual void DebugOff ()
 Turn debugging output off.
 
bool GetDebug ()
 Get the value of the debug flag.
 
void SetDebug (bool debugFlag)
 Set the value of the debug flag.
 
virtual void Modified ()
 Update the modification time for this object.
 
virtual vtkMTimeType GetMTime ()
 Return this object's modified time.
 
void PrintSelf (ostream &os, vtkIndent indent) override
 Methods invoked by print to print information about the object including superclasses.
 
void RemoveObserver (unsigned long tag)
 
void RemoveObservers (unsigned long event)
 
void RemoveObservers (const char *event)
 
void RemoveAllObservers ()
 
vtkTypeBool HasObserver (unsigned long event)
 
vtkTypeBool HasObserver (const char *event)
 
vtkTypeBool InvokeEvent (unsigned long event)
 
vtkTypeBool InvokeEvent (const char *event)
 
std::string GetObjectDescription () const override
 The object description printed in messages and PrintSelf output.
 
unsigned long AddObserver (unsigned long event, vtkCommand *, float priority=0.0f)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object.
 
unsigned long AddObserver (const char *event, vtkCommand *, float priority=0.0f)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object.
 
vtkCommandGetCommand (unsigned long tag)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object.
 
void RemoveObserver (vtkCommand *)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object.
 
void RemoveObservers (unsigned long event, vtkCommand *)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object.
 
void RemoveObservers (const char *event, vtkCommand *)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object.
 
vtkTypeBool HasObserver (unsigned long event, vtkCommand *)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object.
 
vtkTypeBool HasObserver (const char *event, vtkCommand *)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object.
 
template<class U , class T >
unsigned long AddObserver (unsigned long event, U observer, void(T::*callback)(), float priority=0.0f)
 Overloads to AddObserver that allow developers to add class member functions as callbacks for events.
 
template<class U , class T >
unsigned long AddObserver (unsigned long event, U observer, void(T::*callback)(vtkObject *, unsigned long, void *), float priority=0.0f)
 Overloads to AddObserver that allow developers to add class member functions as callbacks for events.
 
template<class U , class T >
unsigned long AddObserver (unsigned long event, U observer, bool(T::*callback)(vtkObject *, unsigned long, void *), float priority=0.0f)
 Allow user to set the AbortFlagOn() with the return value of the callback method.
 
vtkTypeBool InvokeEvent (unsigned long event, void *callData)
 This method invokes an event and return whether the event was aborted or not.
 
vtkTypeBool InvokeEvent (const char *event, void *callData)
 This method invokes an event and return whether the event was aborted or not.
 
virtual void SetObjectName (const std::string &objectName)
 Set/get the name of this object for reporting purposes.
 
virtual std::string GetObjectName () const
 Set/get the name of this object for reporting purposes.
 
- Public Member Functions inherited from vtkObjectBase
const char * GetClassName () const
 Return the class name as a string.
 
virtual std::string GetObjectDescription () const
 The object description printed in messages and PrintSelf output.
 
virtual vtkTypeBool IsA (const char *name)
 Return 1 if this class is the same type of (or a subclass of) the named class.
 
virtual vtkIdType GetNumberOfGenerationsFromBase (const char *name)
 Given the name of a base class of this class type, return the distance of inheritance between this class type and the named class (how many generations of inheritance are there between this class and the named class).
 
virtual void Delete ()
 Delete a VTK object.
 
virtual void FastDelete ()
 Delete a reference to this object.
 
void InitializeObjectBase ()
 
void Print (ostream &os)
 Print an object to an ostream.
 
void Register (vtkObjectBase *o)
 Increase the reference count (mark as used by another object).
 
virtual void UnRegister (vtkObjectBase *o)
 Decrease the reference count (release by another object).
 
int GetReferenceCount ()
 Return the current reference count of this object.
 
void SetReferenceCount (int)
 Sets the reference count.
 
bool GetIsInMemkind () const
 A local state flag that remembers whether this object lives in the normal or extended memory space.
 
virtual void PrintHeader (ostream &os, vtkIndent indent)
 Methods invoked by print to print information about the object including superclasses.
 
virtual void PrintTrailer (ostream &os, vtkIndent indent)
 Methods invoked by print to print information about the object including superclasses.
 
virtual bool UsesGarbageCollector () const
 Indicate whether the class uses vtkGarbageCollector or not.
 

Static Public Member Functions

static vtkLightKitNew ()
 
static vtkTypeBool IsTypeOf (const char *type)
 
static vtkLightKitSafeDownCast (vtkObjectBase *o)
 
static const char * GetStringFromType (int type)
 Helper method to go from a enum type to a string type.
 
static const char * GetStringFromSubType (int type)
 Helper method to go from a enum subtype to a string subtype.
 
static const char * GetShortStringFromSubType (int subtype)
 Helper method to go from a enum subtype to a string subtype The difference from GetStringFromSubType is that it returns a shorter strings (useful for GUI with minimum space)
 
static LightKitSubType GetSubType (LightKitType type, int i)
 Return the possible subtype from a given type.
 
- Static Public Member Functions inherited from vtkObject
static vtkObjectNew ()
 Create an object with Debug turned off, modified time initialized to zero, and reference counting on.
 
static void BreakOnError ()
 This method is called when vtkErrorMacro executes.
 
static void SetGlobalWarningDisplay (vtkTypeBool val)
 This is a global flag that controls whether any debug, warning or error messages are displayed.
 
static void GlobalWarningDisplayOn ()
 This is a global flag that controls whether any debug, warning or error messages are displayed.
 
static void GlobalWarningDisplayOff ()
 This is a global flag that controls whether any debug, warning or error messages are displayed.
 
static vtkTypeBool GetGlobalWarningDisplay ()
 This is a global flag that controls whether any debug, warning or error messages are displayed.
 
- Static Public Member Functions inherited from vtkObjectBase
static vtkTypeBool IsTypeOf (const char *name)
 Return 1 if this class type is the same type of (or a subclass of) the named class.
 
static vtkIdType GetNumberOfGenerationsFromBaseType (const char *name)
 Given a the name of a base class of this class type, return the distance of inheritance between this class type and the named class (how many generations of inheritance are there between this class and the named class).
 
static vtkObjectBaseNew ()
 Create an object with Debug turned off, modified time initialized to zero, and reference counting on.
 
static void SetMemkindDirectory (const char *directoryname)
 The name of a directory, ideally mounted -o dax, to memory map an extended memory space within.
 
static bool GetUsingMemkind ()
 A global state flag that controls whether vtkObjects are constructed in the usual way (the default) or within the extended memory space.
 

Protected Member Functions

virtual vtkObjectBaseNewInstanceInternal () const
 
 vtkLightKit ()
 
 ~vtkLightKit () override
 
void WarmthToRGBI (double w, double rgb[3], double &i)
 
void WarmthToRGB (double w, double rgb[3])
 
void InitializeWarmthFunctions ()
 
double WarmthToIntensity (double w)
 
- Protected Member Functions inherited from vtkObject
 vtkObject ()
 
 ~vtkObject () override
 
void RegisterInternal (vtkObjectBase *, vtkTypeBool check) override
 
void UnRegisterInternal (vtkObjectBase *, vtkTypeBool check) override
 
void InternalGrabFocus (vtkCommand *mouseEvents, vtkCommand *keypressEvents=nullptr)
 These methods allow a command to exclusively grab all events.
 
void InternalReleaseFocus ()
 These methods allow a command to exclusively grab all events.
 
- Protected Member Functions inherited from vtkObjectBase
 vtkObjectBase ()
 
virtual ~vtkObjectBase ()
 
virtual void RegisterInternal (vtkObjectBase *, vtkTypeBool check)
 
virtual void UnRegisterInternal (vtkObjectBase *, vtkTypeBool check)
 
virtual void ReportReferences (vtkGarbageCollector *)
 
virtual void ObjectFinalize ()
 
 vtkObjectBase (const vtkObjectBase &)
 
void operator= (const vtkObjectBase &)
 

Protected Attributes

double KeyLightIntensity
 
double KeyToFillRatio
 
double KeyToHeadRatio
 
double KeyToBackRatio
 
vtkLightKeyLight
 
double KeyLightWarmth
 
double KeyLightAngle [2]
 
double KeyLightColor [3]
 
vtkLightFillLight
 
double FillLightWarmth
 
double FillLightAngle [2]
 
double FillLightColor [3]
 
double BackLightWarmth
 
double BackLightColor [3]
 
vtkLightBackLight0
 
vtkLightBackLight1
 
double BackLightAngle [2]
 
vtkLightHeadLight
 
double HeadLightWarmth
 
double HeadLightColor [3]
 
vtkTypeBool MaintainLuminance
 
vtkPiecewiseFunctionWarmthFunction [4]
 
- Protected Attributes inherited from vtkObject
bool Debug
 
vtkTimeStamp MTime
 
vtkSubjectHelper * SubjectHelper
 
std::string ObjectName
 
- Protected Attributes inherited from vtkObjectBase
std::atomic< int32_t > ReferenceCount
 
vtkWeakPointerBase ** WeakPointers
 

Additional Inherited Members

- Static Protected Member Functions inherited from vtkObjectBase
static vtkMallocingFunction GetCurrentMallocFunction ()
 
static vtkReallocingFunction GetCurrentReallocFunction ()
 
static vtkFreeingFunction GetCurrentFreeFunction ()
 
static vtkFreeingFunction GetAlternateFreeFunction ()
 

Detailed Description

a simple but quality lighting kit

vtkLightKit is designed to make general purpose lighting of vtk scenes simple, flexible, and attractive (or at least not horribly ugly without significant effort). Use a LightKit when you want more control over your lighting than you can get with the default vtk light, which is a headlight located at the camera. (HeadLights are very simple to use, but they don't show the shape of objects very well, don't give a good sense of "up" and "down", and don't evenly light the object.)

A LightKit consists of three lights, a key light, a fill light, and a headlight. The main light is the key light. It is usually positioned so that it appears like an overhead light (like the sun, or a ceiling light). It is generally positioned to shine down on the scene from about a 45 degree angle vertically and at least a little offset side to side. The key light usually at least about twice as bright as the total of all other lights in the scene to provide good modeling of object features.

The other lights in the kit (the fill light, headlight, and a pair of back lights) are weaker sources that provide extra illumination to fill in the spots that the key light misses. The fill light is usually positioned across from or opposite from the key light (though still on the same side of the object as the camera) in order to simulate diffuse reflections from other objects in the scene. The headlight, always located at the position of the camera, reduces the contrast between areas lit by the key and fill light. The two back lights, one on the left of the object as seen from the observer and one on the right, fill on the high-contrast areas behind the object. To enforce the relationship between the different lights, the intensity of the fill, back and headlights are set as a ratio to the key light brightness. Thus, the brightness of all the lights in the scene can be changed by changing the key light intensity.

All lights are directional lights (infinitely far away with no falloff). Lights move with the camera.

For simplicity, the position of lights in the LightKit can only be specified using angles: the elevation (latitude) and azimuth (longitude) of each light with respect to the camera, expressed in degrees. (Lights always shine on the camera's lookat point.) For example, a light at (elevation=0, azimuth=0) is located at the camera (a headlight). A light at (elevation=90, azimuth=0) is above the lookat point, shining down. Negative azimuth values move the lights clockwise as seen above, positive values counter-clockwise. So, a light at (elevation=45, azimuth=-20) is above and in front of the object and shining slightly from the left side.

vtkLightKit limits the colors that can be assigned to any light to those of incandescent sources such as light bulbs and sunlight. It defines a special color spectrum called "warmth" from which light colors can be chosen, where 0 is cold blue, 0.5 is neutral white, and 1 is deep sunset red. Colors close to 0.5 are "cool whites" and "warm whites," respectively.

Since colors far from white on the warmth scale appear less bright, key-to-fill and key-to-headlight ratios are skewed by key, fill, and headlight colors. If the flag MaintainLuminance is set, vtkLightKit will attempt to compensate for these perceptual differences by increasing the brightness of more saturated colors.

A LightKit is not explicitly part of the vtk pipeline. Rather, it is a composite object that controls the behavior of lights using a unified user interface. Every time a parameter of vtkLightKit is adjusted, the properties of its lights are modified.

Credits:
vtkLightKit was originally written and contributed to vtk by Michael Halle (mhall.nosp@m.e@bw.nosp@m.h.har.nosp@m.vard.nosp@m..edu) at the Surgical Planning Lab, Brigham and Women's Hospital.
Tests:
vtkLightKit (Tests)

Definition at line 94 of file vtkLightKit.h.

Member Typedef Documentation

◆ Superclass

Definition at line 98 of file vtkLightKit.h.

Member Enumeration Documentation

◆ LightKitType

Enumerator
TKeyLight 
TFillLight 
TBackLight 
THeadLight 

Definition at line 101 of file vtkLightKit.h.

◆ LightKitSubType

Enumerator
Warmth 
Intensity 
Elevation 
Azimuth 
KFRatio 
KBRatio 
KHRatio 

Definition at line 109 of file vtkLightKit.h.

Constructor & Destructor Documentation

◆ vtkLightKit()

vtkLightKit::vtkLightKit ( )
protected

◆ ~vtkLightKit()

vtkLightKit::~vtkLightKit ( )
overrideprotected

Member Function Documentation

◆ New()

static vtkLightKit * vtkLightKit::New ( )
static

◆ IsTypeOf()

static vtkTypeBool vtkLightKit::IsTypeOf ( const char *  type)
static

◆ IsA()

virtual vtkTypeBool vtkLightKit::IsA ( const char *  name)
virtual

Return 1 if this class is the same type of (or a subclass of) the named class.

Returns 0 otherwise. This method works in combination with vtkTypeMacro found in vtkSetGet.h.

Reimplemented from vtkObjectBase.

◆ SafeDownCast()

static vtkLightKit * vtkLightKit::SafeDownCast ( vtkObjectBase o)
static

◆ NewInstanceInternal()

virtual vtkObjectBase * vtkLightKit::NewInstanceInternal ( ) const
protectedvirtual

◆ NewInstance()

vtkLightKit * vtkLightKit::NewInstance ( ) const

◆ PrintSelf()

void vtkLightKit::PrintSelf ( ostream &  os,
vtkIndent  indent 
)
overridevirtual

Methods invoked by print to print information about the object including superclasses.

Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes.

Reimplemented from vtkObjectBase.

◆ SetKeyLightIntensity()

virtual void vtkLightKit::SetKeyLightIntensity ( double  )
virtual

Set/Get the intensity of the key light.

The key light is the brightest light in the scene. The intensities of the other two lights are ratios of the key light's intensity.

◆ GetKeyLightIntensity()

virtual double vtkLightKit::GetKeyLightIntensity ( )
virtual

Set/Get the intensity of the key light.

The key light is the brightest light in the scene. The intensities of the other two lights are ratios of the key light's intensity.

◆ SetKeyToFillRatio()

virtual void vtkLightKit::SetKeyToFillRatio ( double  )
virtual

Set/Get the key-to-fill ratio.

This ratio controls how bright the fill light is compared to the key light: larger values correspond to a dimmer fill light. The purpose of the fill light is to light parts of the object not lit by the key light, while still maintaining contrast. This type of lighting may correspond to indirect illumination from the key light, bounced off a wall, floor, or other object. The fill light should never be brighter than the key light: a good range for the key-to-fill ratio is between 2 and 10.

◆ GetKeyToFillRatio()

virtual double vtkLightKit::GetKeyToFillRatio ( )
virtual

Set/Get the key-to-fill ratio.

This ratio controls how bright the fill light is compared to the key light: larger values correspond to a dimmer fill light. The purpose of the fill light is to light parts of the object not lit by the key light, while still maintaining contrast. This type of lighting may correspond to indirect illumination from the key light, bounced off a wall, floor, or other object. The fill light should never be brighter than the key light: a good range for the key-to-fill ratio is between 2 and 10.

◆ SetKeyToHeadRatio()

virtual void vtkLightKit::SetKeyToHeadRatio ( double  )
virtual

Set/Get the key-to-headlight ratio.

Similar to the key-to-fill ratio, this ratio controls how bright the headlight light is compared to the key light: larger values correspond to a dimmer headlight light. The headlight is special kind of fill light, lighting only the parts of the object that the camera can see. As such, a headlight tends to reduce the contrast of a scene. It can be used to fill in "shadows" of the object missed by the key and fill lights. The headlight should always be significantly dimmer than the key light: ratios of 2 to 15 are typical.

◆ GetKeyToHeadRatio()

virtual double vtkLightKit::GetKeyToHeadRatio ( )
virtual

Set/Get the key-to-headlight ratio.

Similar to the key-to-fill ratio, this ratio controls how bright the headlight light is compared to the key light: larger values correspond to a dimmer headlight light. The headlight is special kind of fill light, lighting only the parts of the object that the camera can see. As such, a headlight tends to reduce the contrast of a scene. It can be used to fill in "shadows" of the object missed by the key and fill lights. The headlight should always be significantly dimmer than the key light: ratios of 2 to 15 are typical.

◆ SetKeyToBackRatio()

virtual void vtkLightKit::SetKeyToBackRatio ( double  )
virtual

Set/Get the key-to-back light ratio.

This ratio controls how bright the back lights are compared to the key light: larger values correspond to dimmer back lights. The back lights fill in the remaining high-contrast regions behind the object. Values between 2 and 10 are good.

◆ GetKeyToBackRatio()

virtual double vtkLightKit::GetKeyToBackRatio ( )
virtual

Set/Get the key-to-back light ratio.

This ratio controls how bright the back lights are compared to the key light: larger values correspond to dimmer back lights. The back lights fill in the remaining high-contrast regions behind the object. Values between 2 and 10 are good.

◆ SetKeyLightWarmth()

virtual void vtkLightKit::SetKeyLightWarmth ( double  )
virtual

Set the warmth of each the lights.

Warmth is a parameter that varies from 0 to 1, where 0 is "cold" (looks icy or lit by a very blue sky), 1 is "warm" (the red of a very red sunset, or the embers of a campfire), and 0.5 is a neutral white. The warmth scale is non-linear. Warmth values close to 0.5 are subtly "warmer" or "cooler," much like a warmer tungsten incandescent bulb, a cooler halogen, or daylight (cooler still). Moving further away from 0.5, colors become more quickly varying towards blues and reds. With regards to aesthetics, extremes of warmth should be used sparingly.

◆ GetKeyLightWarmth()

virtual double vtkLightKit::GetKeyLightWarmth ( )
virtual

Set the warmth of each the lights.

Warmth is a parameter that varies from 0 to 1, where 0 is "cold" (looks icy or lit by a very blue sky), 1 is "warm" (the red of a very red sunset, or the embers of a campfire), and 0.5 is a neutral white. The warmth scale is non-linear. Warmth values close to 0.5 are subtly "warmer" or "cooler," much like a warmer tungsten incandescent bulb, a cooler halogen, or daylight (cooler still). Moving further away from 0.5, colors become more quickly varying towards blues and reds. With regards to aesthetics, extremes of warmth should be used sparingly.

◆ SetFillLightWarmth()

virtual void vtkLightKit::SetFillLightWarmth ( double  )
virtual

◆ GetFillLightWarmth()

virtual double vtkLightKit::GetFillLightWarmth ( )
virtual

◆ SetHeadLightWarmth()

virtual void vtkLightKit::SetHeadLightWarmth ( double  )
virtual

◆ GetHeadLightWarmth()

virtual double vtkLightKit::GetHeadLightWarmth ( )
virtual

◆ SetBackLightWarmth()

virtual void vtkLightKit::SetBackLightWarmth ( double  )
virtual

◆ GetBackLightWarmth()

virtual double vtkLightKit::GetBackLightWarmth ( )
virtual

◆ GetKeyLightColor() [1/2]

virtual double * vtkLightKit::GetKeyLightColor ( )
virtual

Returns the floating-point RGB values of each of the light's color.

◆ GetKeyLightColor() [2/2]

virtual void vtkLightKit::GetKeyLightColor ( double  data[3])
virtual

Returns the floating-point RGB values of each of the light's color.

◆ GetFillLightColor() [1/2]

virtual double * vtkLightKit::GetFillLightColor ( )
virtual

Returns the floating-point RGB values of each of the light's color.

◆ GetFillLightColor() [2/2]

virtual void vtkLightKit::GetFillLightColor ( double  data[3])
virtual

Returns the floating-point RGB values of each of the light's color.

◆ GetHeadLightColor() [1/2]

virtual double * vtkLightKit::GetHeadLightColor ( )
virtual

Returns the floating-point RGB values of each of the light's color.

◆ GetHeadLightColor() [2/2]

virtual void vtkLightKit::GetHeadLightColor ( double  data[3])
virtual

Returns the floating-point RGB values of each of the light's color.

◆ GetBackLightColor() [1/2]

virtual double * vtkLightKit::GetBackLightColor ( )
virtual

Returns the floating-point RGB values of each of the light's color.

◆ GetBackLightColor() [2/2]

virtual void vtkLightKit::GetBackLightColor ( double  data[3])
virtual

Returns the floating-point RGB values of each of the light's color.

◆ MaintainLuminanceOn()

virtual void vtkLightKit::MaintainLuminanceOn ( )
virtual

If MaintainLuminance is set, the LightKit will attempt to maintain the apparent intensity of lights based on their perceptual brightnesses.

By default, MaintainLuminance is off.

◆ MaintainLuminanceOff()

virtual void vtkLightKit::MaintainLuminanceOff ( )
virtual

If MaintainLuminance is set, the LightKit will attempt to maintain the apparent intensity of lights based on their perceptual brightnesses.

By default, MaintainLuminance is off.

◆ GetMaintainLuminance()

virtual vtkTypeBool vtkLightKit::GetMaintainLuminance ( )
virtual

If MaintainLuminance is set, the LightKit will attempt to maintain the apparent intensity of lights based on their perceptual brightnesses.

By default, MaintainLuminance is off.

◆ SetMaintainLuminance()

virtual void vtkLightKit::SetMaintainLuminance ( vtkTypeBool  )
virtual

If MaintainLuminance is set, the LightKit will attempt to maintain the apparent intensity of lights based on their perceptual brightnesses.

By default, MaintainLuminance is off.

◆ SetKeyLightAngle() [1/2]

void vtkLightKit::SetKeyLightAngle ( double  elevation,
double  azimuth 
)

Get/Set the position of the key, fill, and back lights using angular methods.

Elevation corresponds to latitude, azimuth to longitude. It is recommended that the key light always be on the viewer's side of the object and above the object, while the fill light generally lights the part of the object not lit by the fill light. The headlight, which is always located at the viewer, can then be used to reduce the contrast in the image. There are a pair of back lights. They are located at the same elevation and at opposing azimuths (ie, one to the left, and one to the right). They are generally set at the equator (elevation = 0), and at approximately 120 degrees (lighting from each side and behind).

◆ SetKeyLightAngle() [2/2]

void vtkLightKit::SetKeyLightAngle ( double  angle[2])
inline

Definition at line 235 of file vtkLightKit.h.

◆ SetKeyLightElevation()

void vtkLightKit::SetKeyLightElevation ( double  x)
inline

Definition at line 237 of file vtkLightKit.h.

◆ SetKeyLightAzimuth()

void vtkLightKit::SetKeyLightAzimuth ( double  x)
inline

Definition at line 239 of file vtkLightKit.h.

◆ GetKeyLightAngle() [1/2]

virtual double * vtkLightKit::GetKeyLightAngle ( )
virtual

◆ GetKeyLightAngle() [2/2]

virtual void vtkLightKit::GetKeyLightAngle ( double  data[2])
virtual

◆ GetKeyLightElevation()

double vtkLightKit::GetKeyLightElevation ( )
inline

Definition at line 242 of file vtkLightKit.h.

◆ GetKeyLightAzimuth()

double vtkLightKit::GetKeyLightAzimuth ( )
inline

Definition at line 249 of file vtkLightKit.h.

◆ SetFillLightAngle() [1/2]

void vtkLightKit::SetFillLightAngle ( double  elevation,
double  azimuth 
)

◆ SetFillLightAngle() [2/2]

void vtkLightKit::SetFillLightAngle ( double  angle[2])
inline

Definition at line 257 of file vtkLightKit.h.

◆ SetFillLightElevation()

void vtkLightKit::SetFillLightElevation ( double  x)
inline

Definition at line 259 of file vtkLightKit.h.

◆ SetFillLightAzimuth()

void vtkLightKit::SetFillLightAzimuth ( double  x)
inline

Definition at line 261 of file vtkLightKit.h.

◆ GetFillLightAngle() [1/2]

virtual double * vtkLightKit::GetFillLightAngle ( )
virtual

◆ GetFillLightAngle() [2/2]

virtual void vtkLightKit::GetFillLightAngle ( double  data[2])
virtual

◆ GetFillLightElevation()

double vtkLightKit::GetFillLightElevation ( )
inline

Definition at line 264 of file vtkLightKit.h.

◆ GetFillLightAzimuth()

double vtkLightKit::GetFillLightAzimuth ( )
inline

Definition at line 271 of file vtkLightKit.h.

◆ SetBackLightAngle() [1/2]

void vtkLightKit::SetBackLightAngle ( double  elevation,
double  azimuth 
)

◆ SetBackLightAngle() [2/2]

void vtkLightKit::SetBackLightAngle ( double  angle[2])
inline

Definition at line 279 of file vtkLightKit.h.

◆ SetBackLightElevation()

void vtkLightKit::SetBackLightElevation ( double  x)
inline

Definition at line 281 of file vtkLightKit.h.

◆ SetBackLightAzimuth()

void vtkLightKit::SetBackLightAzimuth ( double  x)
inline

Definition at line 283 of file vtkLightKit.h.

◆ GetBackLightAngle() [1/2]

virtual double * vtkLightKit::GetBackLightAngle ( )
virtual

◆ GetBackLightAngle() [2/2]

virtual void vtkLightKit::GetBackLightAngle ( double  data[2])
virtual

◆ GetBackLightElevation()

double vtkLightKit::GetBackLightElevation ( )
inline

Definition at line 286 of file vtkLightKit.h.

◆ GetBackLightAzimuth()

double vtkLightKit::GetBackLightAzimuth ( )
inline

Definition at line 293 of file vtkLightKit.h.

◆ AddLightsToRenderer()

void vtkLightKit::AddLightsToRenderer ( vtkRenderer renderer)

Add lights to, or remove lights from, a renderer.

Lights may be added to more than one renderer, if desired.

◆ RemoveLightsFromRenderer()

void vtkLightKit::RemoveLightsFromRenderer ( vtkRenderer renderer)

Add lights to, or remove lights from, a renderer.

Lights may be added to more than one renderer, if desired.

◆ DeepCopy()

void vtkLightKit::DeepCopy ( vtkLightKit kit)

◆ Modified()

void vtkLightKit::Modified ( )
overridevirtual

Update the modification time for this object.

Many filters rely on the modification time to determine if they need to recompute their data. The modification time is a unique monotonically increasing unsigned long integer.

Reimplemented from vtkObject.

◆ Update()

void vtkLightKit::Update ( )

◆ GetStringFromType()

static const char * vtkLightKit::GetStringFromType ( int  type)
static

Helper method to go from a enum type to a string type.

◆ GetStringFromSubType()

static const char * vtkLightKit::GetStringFromSubType ( int  type)
static

Helper method to go from a enum subtype to a string subtype.

◆ GetShortStringFromSubType()

static const char * vtkLightKit::GetShortStringFromSubType ( int  subtype)
static

Helper method to go from a enum subtype to a string subtype The difference from GetStringFromSubType is that it returns a shorter strings (useful for GUI with minimum space)

◆ GetSubType()

static LightKitSubType vtkLightKit::GetSubType ( LightKitType  type,
int  i 
)
static

Return the possible subtype from a given type.

You have to pass in a number i [0,3] no check is done.

◆ WarmthToRGBI()

void vtkLightKit::WarmthToRGBI ( double  w,
double  rgb[3],
double &  i 
)
protected

◆ WarmthToRGB()

void vtkLightKit::WarmthToRGB ( double  w,
double  rgb[3] 
)
protected

◆ InitializeWarmthFunctions()

void vtkLightKit::InitializeWarmthFunctions ( )
protected

◆ WarmthToIntensity()

double vtkLightKit::WarmthToIntensity ( double  w)
protected

Member Data Documentation

◆ KeyLightIntensity

double vtkLightKit::KeyLightIntensity
protected

Definition at line 346 of file vtkLightKit.h.

◆ KeyToFillRatio

double vtkLightKit::KeyToFillRatio
protected

Definition at line 347 of file vtkLightKit.h.

◆ KeyToHeadRatio

double vtkLightKit::KeyToHeadRatio
protected

Definition at line 348 of file vtkLightKit.h.

◆ KeyToBackRatio

double vtkLightKit::KeyToBackRatio
protected

Definition at line 349 of file vtkLightKit.h.

◆ KeyLight

vtkLight* vtkLightKit::KeyLight
protected

Definition at line 351 of file vtkLightKit.h.

◆ KeyLightWarmth

double vtkLightKit::KeyLightWarmth
protected

Definition at line 352 of file vtkLightKit.h.

◆ KeyLightAngle

double vtkLightKit::KeyLightAngle[2]
protected

Definition at line 353 of file vtkLightKit.h.

◆ KeyLightColor

double vtkLightKit::KeyLightColor[3]
protected

Definition at line 354 of file vtkLightKit.h.

◆ FillLight

vtkLight* vtkLightKit::FillLight
protected

Definition at line 356 of file vtkLightKit.h.

◆ FillLightWarmth

double vtkLightKit::FillLightWarmth
protected

Definition at line 357 of file vtkLightKit.h.

◆ FillLightAngle

double vtkLightKit::FillLightAngle[2]
protected

Definition at line 358 of file vtkLightKit.h.

◆ FillLightColor

double vtkLightKit::FillLightColor[3]
protected

Definition at line 359 of file vtkLightKit.h.

◆ BackLightWarmth

double vtkLightKit::BackLightWarmth
protected

Definition at line 361 of file vtkLightKit.h.

◆ BackLightColor

double vtkLightKit::BackLightColor[3]
protected

Definition at line 362 of file vtkLightKit.h.

◆ BackLight0

vtkLight* vtkLightKit::BackLight0
protected

Definition at line 364 of file vtkLightKit.h.

◆ BackLight1

vtkLight* vtkLightKit::BackLight1
protected

Definition at line 365 of file vtkLightKit.h.

◆ BackLightAngle

double vtkLightKit::BackLightAngle[2]
protected

Definition at line 367 of file vtkLightKit.h.

◆ HeadLight

vtkLight* vtkLightKit::HeadLight
protected

Definition at line 369 of file vtkLightKit.h.

◆ HeadLightWarmth

double vtkLightKit::HeadLightWarmth
protected

Definition at line 370 of file vtkLightKit.h.

◆ HeadLightColor

double vtkLightKit::HeadLightColor[3]
protected

Definition at line 371 of file vtkLightKit.h.

◆ MaintainLuminance

vtkTypeBool vtkLightKit::MaintainLuminance
protected

Definition at line 373 of file vtkLightKit.h.

◆ WarmthFunction

vtkPiecewiseFunction* vtkLightKit::WarmthFunction[4]
protected

Definition at line 375 of file vtkLightKit.h.


The documentation for this class was generated from the following file: