#include <hps.h>
Public Member Functions | |
DistantLightKey () | |
DistantLightKey (Key const &in_that) | |
DistantLightKey (DistantLightKey const &in_that) | |
DistantLightKey & | operator= (DistantLightKey const &in_that) |
DistantLightKey (DistantLightKey &&in_that) | |
DistantLightKey & | operator= (DistantLightKey &&in_that) |
HPS::Type | ObjectType () const |
void | Consume (DistantLightKit &in_kit) |
void | Set (DistantLightKit const &in_kit) |
void | Show (DistantLightKit &out_kit) const |
DistantLightKey & | SetDirection (HPS::Vector const &in_vector) |
DistantLightKey & | SetColor (RGBAColor const &in_rgba_color) |
DistantLightKey & | SetColorByIndex (float in_index) |
DistantLightKey & | SetCameraRelative (bool in_state) |
DistantLightKey & | UnsetColor () |
bool | ShowDirection (HPS::Vector &out_vector) const |
bool | ShowColor (Material::Type &out_type, RGBAColor &out_rgba_color, float &out_index) const |
bool | ShowCameraRelative (bool &out_state) const |
![]() | |
GeometryKey () | |
GeometryKey (Key const &in_that) | |
GeometryKey (GeometryKey const &in_that) | |
GeometryKey & | operator= (GeometryKey const &in_that) |
GeometryKey (GeometryKey &&in_that) | |
GeometryKey & | operator= (GeometryKey &&in_that) |
size_t | ShowReferrers (SegmentKeyArray &out_segments) const |
size_t | ShowReferrers (ReferenceKeyArray &out_references) const |
GeometryKey & | SetPriority (int in_priority) |
GeometryKey & | UnsetPriority () |
bool | ShowPriority (int &out_priority) const |
GeometryKey & | SetUserData (intptr_t in_index, size_t in_bytes, byte const in_data[]) |
GeometryKey & | SetUserData (intptr_t in_index, ByteArray const &in_data) |
GeometryKey & | SetUserData (IntPtrTArray const &in_indices, ByteArrayArray const &in_data) |
GeometryKey & | UnsetUserData (intptr_t in_index) |
GeometryKey & | UnsetUserData (size_t in_count, intptr_t const in_indices[]) |
GeometryKey & | UnsetUserData (IntPtrTArray const &in_indices) |
GeometryKey & | UnsetAllUserData () |
size_t | ShowUserDataCount () const |
bool | ShowUserDataIndices (IntPtrTArray &out_indices) const |
bool | ShowUserData (intptr_t in_index, ByteArray &out_data) const |
bool | ShowUserData (IntPtrTArray &out_indices, ByteArrayArray &out_data) const |
bool | ShowBoundings (BoundingKit &out_kit) const |
![]() | |
Key () | |
Key (Key const &in_that) | |
Key (Control const &in_control) | |
Key (Key &&in_that) | |
Key & | operator= (Key &&in_that) |
virtual | ~Key () |
bool | HasOwner () const |
SegmentKey | Up () const |
SegmentKey | Owner () const |
void | Delete () |
void | MoveTo (SegmentKey const &in_new_owner) |
Key | CopyTo (SegmentKey const &in_destination) const |
Key & | operator= (Key const &in_that) |
virtual void | Assign (Key const &in_that) |
bool | Equals (Key const &in_that) const |
bool | operator!= (Key const &in_that) const |
bool | operator== (Key const &in_that) const |
size_t | GetHash () const |
![]() | |
Object (Object const &that) | |
Object & | operator= (Object const &other_object) |
Object (Object &&in_that) | |
Object & | operator= (Object &&in_that) |
HPS::Type | Type () const |
virtual bool | Empty () const |
virtual void | Reset () |
bool | HasType (HPS::Type in_mask) const |
intptr_t | GetClassID () const |
intptr_t | GetInstanceID () const |
Additional Inherited Members | |
![]() | |
template<typename T > | |
static intptr_t | ClassID () |
The DistantLightKey class is a smart pointer to a database object. It is a handle to a distant light inserted via SegmentKey::InsertDistantLight.
HPS::DistantLightKey::DistantLightKey | ( | ) |
The default constructor creates an uninitialized DistantLightKey object. The Type() function will return Type::None.
|
explicit |
This constructor creates a DistantLightKey object that shares the underlying smart-pointer of the source Key. The copy will only be successful if the source key is really an upcast of a DistantLight key. Otherwise the copy will fail and the resulting DistantLightKey will be invalid.
in_key | The source Key to copy. |
HPS::DistantLightKey::DistantLightKey | ( | DistantLightKey const & | in_that | ) |
The copy constructor creates a DistantLightKey object that shares the underlying smart-pointer of the source DistantLightKey.
in_that | The source DistantLightKey to copy. |
HPS::DistantLightKey::DistantLightKey | ( | DistantLightKey && | in_that | ) |
The move constructor creates a DistantLightKey by transferring the underlying impl of the rvalue reference to this DistantLightKey thereby avoiding a copy and allocation.
in_that | An rvalue reference to a DistantLightKey to take the impl from. |
void HPS::DistantLightKey::Consume | ( | DistantLightKit & | in_kit | ) |
Completely replaces all settings on this DistantLightKey with those set on the specified kit and resets the kit.
in_kit | The kit from which to get the settings to replace on this DistantLightKey. |
|
inlinevirtual |
This function returns the type the object, as declared. This does not necessarily give the true type of the underlying object.
Reimplemented from HPS::GeometryKey.
DistantLightKey& HPS::DistantLightKey::operator= | ( | DistantLightKey const & | in_that | ) |
Associate this DistantLightKey with the same underlying impl as the source DistantLightKey.
in_that | The source DistantLightKey for the assignment. |
DistantLightKey& HPS::DistantLightKey::operator= | ( | DistantLightKey && | in_that | ) |
The move assignment operator transfers the underlying impl of the rvalue reference to this DistantLightKey thereby avoiding a copy.
in_that | An rvalue reference to a DistantLightKey to take the impl from. |
void HPS::DistantLightKey::Set | ( | DistantLightKit const & | in_kit | ) |
Replace those settings on this DistantLightKey with those set on the specified kit.
in_kit | The kit from which to get the settings to replace on this DistantLightKey. |
DistantLightKey& HPS::DistantLightKey::SetCameraRelative | ( | bool | in_state | ) |
Sets the camera-relative setting for this DistantLightKey.
in_state | Whether the direction of this DistantLightKey is treated as being in object space or camera-relative space. |
DistantLightKey& HPS::DistantLightKey::SetColor | ( | RGBAColor const & | in_rgba_color | ) |
Sets the RGBA color to use for this DistantLightKey.
in_rgba_color | The RGBA color to use for this DistantLightKey. |
DistantLightKey& HPS::DistantLightKey::SetColorByIndex | ( | float | in_index | ) |
Sets the color index to use for this DistantLightKey.
in_index | The color index to use for this DistantLightKey. |
DistantLightKey& HPS::DistantLightKey::SetDirection | ( | HPS::Vector const & | in_vector | ) |
Sets the direction in which this DistantLightKey lies. The rays emitted by this light will travel in the opposite direction of this vector.
in_vector | The direction in which this DistantLightKey lies. The vector will either be treated as being in object space or in camera-relative units depending on the setting passed SetCameraRelative. |
void HPS::DistantLightKey::Show | ( | DistantLightKit & | out_kit | ) | const |
Copy the contents of this DistantLightKey into the specified kit.
out_kit | The kit to populate with the contents of this DistantLightKey. |
bool HPS::DistantLightKey::ShowCameraRelative | ( | bool & | out_state | ) | const |
Shows the camera-relative setting for this DistantLightKey.
out_state | Whether the direction of this DistantLightKey is treated as being in object space or camera-relative space. |
bool HPS::DistantLightKey::ShowColor | ( | Material::Type & | out_type, |
RGBAColor & | out_rgba_color, | ||
float & | out_index | ||
) | const |
Shows the color for this DistantLightKey.
out_type | The type of color for the distant light. |
out_rgba_color | The RGBA color for the distant light. This is only valid if out_type is Material::Type::ExplicitRGBAColor. |
out_index | The material index for the distant light. This is only valid if out_type is Material::Type::MaterialIndex. |
bool HPS::DistantLightKey::ShowDirection | ( | HPS::Vector & | out_vector | ) | const |
Shows the direction in which this DistantLightKey lies.
out_vector | The direction in which this DistantLightKey lies. |
DistantLightKey& HPS::DistantLightKey::UnsetColor | ( | ) |
Removes the color (RGBA or material index) set on this DistantLightKey.