SpotlightKit
- class HPS.SpotlightKit : public HPS.Kit
The HPS.SpotlightKit class is a user space object. It is the kit counterpart to a HPS.SpotlightKey. Calling HPS.SpotlightKit.GetDefault() will return a kit with values found in this table.
Public Functions
- void Consume (HPS.SpotlightKit in_kit)
Copies the source SpotlightKit into this SpotlightKit and resets the source kit.
- Param in_kit
The source SpotlightKit to consume.
- override void Dispose ()
- override bool Empty ()
Indicates whether this SpotlightKit has any values set on it.
- Return
true if no values are set on this SpotlightKit, false otherwise.
- bool Equals (HPS.SpotlightKit in_kit)
Check if the source SpotlightKit is equivalent to this SpotlightKit.
- Param in_kit
The source SpotlightKit to compare to this SpotlightKit.
- Return
true if the objects are equivalent, false otherwise.
- override bool Equals (Object obj)
- override int GetHashCode ()
- override HPS.Type ObjectType ()
This function returns the type the object, as declared (if the object is derived, this does not give the true type of the derived object).
- Return
The declared type of the object in question, which may differ from the true, underlying type.
- void Set (HPS.SpotlightKit in_kit)
Copies the source SpotlightKit into this SpotlightKit.
- Param in_kit
The source SpotlightKit to copy.
- HPS.SpotlightKit SetCameraRelative (bool in_state)
Sets the camera-relative setting for this SpotlightKit. This defines what the implied units of the target and position will be.
- See
- See
- Param in_state
Whether the coordinates of the position and target for this SpotlightKit are treated as being in object space or camera-relative space.
- Return
A reference to this SpotlightKit.
- HPS.SpotlightKit SetColor (HPS.RGBAColor in_rgba_color)
Sets the RGBA color to use for this SpotlightKit.
- Param in_rgba_color
The RGBA color to use for this SpotlightKit.
- Return
A reference to this SpotlightKit.
- HPS.SpotlightKit SetColorByIndex (float in_index)
Sets the color index to use for this SpotlightKit.
- Param in_index
The color index to use for this SpotlightKit.
- Return
A reference to this SpotlightKit.
- HPS.SpotlightKit SetConcentration (float in_concentration)
Sets the concentration for this SpotlightKit. The concentration defines the rate at which light intensity decreases with increasing angular distance from the light direction vector. This effect works in addition to the decrease that occurs between the inner and outer cones.
- Param in_concentration
The concentration for the SpotlightKit. This value must be non-negative. A value of 0.0f defines no intensity decrease (besides that between the inner and outer cone), and larger values will concentrate intensity closer to the light direction vector.
- Return
A reference to this SpotlightKit.
- HPS.SpotlightKit SetInnerCone (float in_size)
Sets the size of the inner cone for this SpotlightKit. The inner cone defines the conic region inside the conic region defined by the outer cone at which the spotlight intensity will decrease linearly to zero at the outer cone’s edge. As such, the size of the inner cone should be no larger than the outer cone.
- Param in_size
The size of the inner cone for this SpotlightKit. The interpretation of the value and its valid range depends on the units argument.
- Return
A reference to this SpotlightKit.
- HPS.SpotlightKit SetInnerCone (float in_size, HPS.Spotlight.InnerConeUnits in_units)
Sets the size of the inner cone for this SpotlightKit. The inner cone defines the conic region inside the conic region defined by the outer cone at which the spotlight intensity will decrease linearly to zero at the outer cone’s edge. As such, the size of the inner cone should be no larger than the outer cone.
- Param in_size
The size of the inner cone for this SpotlightKit. The interpretation of the value and its valid range depends on the units argument.
- Param in_units
The units for the size of the inner cone for this SpotlightKit. Defaults to Spotlight.InnerConeUnits.Percent.
- Return
A reference to this SpotlightKit.
- HPS.SpotlightKit SetOuterCone (float in_size)
Sets the size of the outer cone for this SpotlightKit. The outer cone defines the conic region inside of which surfaces will be illuminated by this spotlight. Any surface outside this conic region will not be illuminated by this spotlight.
- Param in_size
The size of the outer cone for this SpotlightKit. The interpretation of the value and its valid range depends on the units argument.
- Return
A reference to this SpotlightKit.
- HPS.SpotlightKit SetOuterCone (float in_size, HPS.Spotlight.OuterConeUnits in_units)
Sets the size of the outer cone for this SpotlightKit. The outer cone defines the conic region inside of which surfaces will be illuminated by this spotlight. Any surface outside this conic region will not be illuminated by this spotlight.
- Param in_size
The size of the outer cone for this SpotlightKit. The interpretation of the value and its valid range depends on the units argument.
- Param in_units
The units for the size of the outer cone for this SpotlightKit. Defaults to Spotlight.OuterConeUnits.Degrees.
- Return
A reference to this SpotlightKit.
- HPS.SpotlightKit SetPosition (HPS.Point in_position)
Sets the position of the light source for this SpotlightKit.
- Param in_position
The position of the light source for this SpotlightKit. The point will either be treated as being in object space or in camera-relative units depending on the setting passed to SetCameraRelative.
- Return
A reference to this SpotlightKit.
- HPS.SpotlightKit SetPriority (int in_priority)
Assigns a specific drawing priority value to the SpotlightKit. It affects the order in which the contents of this segment are drawn if and only if the rendering algorithm is set to Priority.
- See
SubwindowKit.SetPriority()
- See
- Param in_priority
The drawing priority, higher priority items are drawn on top of lower priority items.
- Return
A reference to this object.
- HPS.SpotlightKit SetTarget (HPS.Point in_target)
Sets the target coordinate towards which the light source points for this SpotlightKit.
- Param in_target
The target coordinate towards which the light source points for this SpotlightKit. The point will either be treated as being in object space or in camera-relative units depending on the setting passed to SetCameraRelative.
- Return
A reference to this SpotlightKit.
- HPS.SpotlightKit SetUserData (IntPtr in_index, byte[] in_data)
Sets user data on this kit.
- Param in_index
The index of the user data to set.
- Param in_data
The bytes of user data to set.
- Return
A reference to this kit.
- HPS.SpotlightKit SetUserData (IntPtr in_index, ulong in_bytes, byte[] in_data)
Sets user data on this kit.
- Param in_index
The index of the user data to set.
- Param in_bytes
The number of bytes of user data to set.
- Param in_data
The bytes of user data to set.
- Return
A reference to this kit.
- HPS.SpotlightKit SetUserData (IntPtr[] in_indices, byte[][] in_data)
Sets user data on this kit.
- Param in_indices
An array of user data indices to set.
- Param in_data
An array of bytes of user data to set.
- Return
A reference to this kit.
- void Show (out HPS.SpotlightKit out_kit)
Copies this SpotlightKit into the given SpotlightKit.
- Param out_kit
The SpotlightKit to populate with the contents of this SpotlightKit.
- bool ShowCameraRelative (out bool out_state)
Shows the camera-relative setting for this SpotlightKit.
- Param out_state
Whether the coordinates of the position and target for this SpotlightKit are treated as being in object space or camera-relative space.
- Return
true if a camera-relative setting was set, false otherwise.
- bool ShowColor (out HPS.Material.Type out_type, out HPS.RGBAColor out_rgba_color, out float out_index)
Shows the color for this SpotlightKit.
- Param out_type
The type of color for the spotlight.
- Param out_rgba_color
The RGBA color for the spotlight. This is only valid if out_type is Material.Type.RGBAColor.
- Param out_index
The material index for the spotlight. This is only valid if out_type is Material.Type.MaterialIndex.
- Return
true if a color was set, false otherwise.
- bool ShowConcentration (out float out_concentration)
Shows the concentration for this SpotlightKit.
- Param out_concentration
The concentration for this SpotlightKit.
- Return
true if a concentration was set, false otherwise.
- bool ShowInnerCone (out float out_size, out HPS.Spotlight.InnerConeUnits out_units)
Shows the inner cone for this SpotlightKit.
- Param out_size
The size of the inner cone for this SpotlightKit.
- Param out_units
The units for the size of the inner cone for this SpotlightKit.
- Return
true if an inner cone was set, false otherwise.
- bool ShowOuterCone (out float out_size, out HPS.Spotlight.OuterConeUnits out_units)
Shows the outer cone for this SpotlightKit.
- Param out_size
The size of the outer cone for this SpotlightKit.
- Param out_units
The units for the size of the outer cone for this SpotlightKit.
- Return
true if an outer cone was set, false otherwise.
- bool ShowPosition (out HPS.Point out_position)
Shows the position of the light source for this SpotlightKit.
- Param out_position
The position of the light source for this SpotlightKit.
- Return
true if a light source position was set, false otherwise.
- bool ShowPriority (out int out_priority)
Shows the drawing priority.
- Param out_priority
The drawing priority, higher priority items are drawn on top of lower priority items.
- Return
true if a drawing priority was specified, false otherwise.
- bool ShowTarget (out HPS.Point out_target)
Shows the target coordinate towards which the light source points for this SpotlightKit.
- Param out_target
The target coordinate towards which the light source points for this SpotlightKit.
- Return
true if a target was set, false otherwise.
- bool ShowUserData (IntPtr in_index, out byte[] out_data)
Shows the user data at a given index for this kit.
- Param in_index
The index of the user data to show.
- Param out_data
The user data at the given index.
- Return
true if there is user data at the given index, false otherwise.
- bool ShowUserData (out IntPtr[] out_indices, out byte[][] out_data)
Shows all user data for this kit.
- Param out_indices
An array of all user data indices set on this kit.
- Param out_data
An array of all user data set on this kit.
- Return
true if there is user data on this kit, false otherwise.
- ulong ShowUserDataCount ()
Get the number of user data indices set on this kit.
- bool ShowUserDataIndices (out IntPtr[] out_indices)
Shows the indices of all user data set on this kit.
- Param out_indices
The user data indices set on this kit.
- Return
The number of user data indices set on this kit.
- SpotlightKit ()
The default constructor creates an empty SpotlightKit object.
- SpotlightKit (HPS.SpotlightKit in_kit)
The copy constructor creates a new SpotlightKit object that contains the same settings as the source SpotlightKit.
- Param in_kit
The source SpotlightKit to copy.
- HPS.SpotlightKit UnsetAllUserData ()
Removes all user data from this kit.
- Return
A reference to this kit.
- HPS.SpotlightKit UnsetCameraRelative ()
Removes the camera-relative setting for this SpotlightKit.
- Return
A reference to this SpotlightKit.
- HPS.SpotlightKit UnsetColor ()
Removes the color (RGBA or material index) for this SpotlightKit.
- Return
A reference to this SpotlightKit.
- HPS.SpotlightKit UnsetConcentration ()
Removes the concentration for this SpotlightKit.
- Return
A reference to this SpotlightKit.
- HPS.SpotlightKit UnsetEverything ()
Removes all settings from the SpotlightKit.
- Return
A reference to this SpotlightKit.
- HPS.SpotlightKit UnsetInnerCone ()
Removes the inner-cone size specification for this SpotlightKit.
- Return
A reference to this SpotlightKit.
- HPS.SpotlightKit UnsetOuterCone ()
Removes the outer-cone size specification for this SpotlightKit.
- Return
A reference to this SpotlightKit.
- HPS.SpotlightKit UnsetPosition ()
Removes the light source position for this SpotlightKit.
- Return
A reference to this SpotlightKit.
- HPS.SpotlightKit UnsetPriority ()
Removes the drawing priority setting.
- Return
A reference to this SpotlightKit.
- HPS.SpotlightKit UnsetTarget ()
Removes the target coordinate towards which the light source points for this SpotlightKit.
- Return
A reference to this SpotlightKit.
- HPS.SpotlightKit UnsetUserData (IntPtr in_index)
Removes the user data at the given index from this kit.
- Param in_index
The index of the user data to remove.
- Return
A reference to this kit.
- HPS.SpotlightKit UnsetUserData (IntPtr[] in_indices)
Removes the user data at the given indices from this kit.
- Param in_indices
The indices of the user data to remove.
- Return
A reference to this kit.
Public Static Functions
- HPS.SpotlightKit GetDefault ()
Creates a SpotlightKit which contains the default settings. The returned object will not necessarily have values set for every option, but it will have settings for those options where it is reasonable to have a default.
- Return
A SpotlightKit with the default settings.
- bool operator!= (HPS.SpotlightKit a, HPS.SpotlightKit b)
- bool operator== (HPS.SpotlightKit a, HPS.SpotlightKit b)