CylinderKit

class HPS::CylinderKit : public HPS::Kit

The CylinderKit class is a user space object. It is a kit analog to a CylinderKey.

Public Functions

void Consume(CylinderKit &in_kit)

Copies the source CylinderKit into this CylinderKit and resets the source kit.

Parameters

in_kit – The source CylinderKit to consume.

CylinderKit()

The default constructor creates an empty CylinderKit object.

CylinderKit(CylinderKit &&in_that)

The move constructor creates a CylinderKit by transferring the underlying impl of the rvalue reference to this CylinderKit thereby avoiding a copy and allocation.

Parameters

in_that – An rvalue reference to a CylinderKit to take the impl from.

CylinderKit(CylinderKit const &in_kit)

The copy constructor creates a new CylinderKit object that contains the same settings as the source CylinderKit.

Parameters

in_kit – The source CylinderKit to copy.

virtual bool Empty() const

Indicates whether this CylinderKit has any values set on it.

Returns

true if no values are set on this CylinderKit, false otherwise.

bool Equals(CylinderKit const &in_kit) const

Check if the source CylinderKit is equivalent to this CylinderKit.

Parameters

in_kit – The source CylinderKit to compare to this CylinderKit.

Returns

true if the objects are equivalent, false otherwise.

size_t GetPointCount() const

Retrieves the number of points in this cylinder.

Returns

The number of points in this cylinder.

inline virtual HPS::Type ObjectType() const

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).

Returns

The declared type of the object in question, which may differ from the true, underlying type.

bool operator!=(CylinderKit const &in_kit) const

Check if the source CylinderKit is not equivalent to this CylinderKit.

Parameters

in_kit – The source CylinderKit to compare to this CylinderKit.

Returns

true if the objects are not equivalent, false otherwise.

CylinderKit &operator=(CylinderKit &&in_that)

The move assignment operator transfers the underlying impl of the rvalue reference to this CylinderKit thereby avoiding a copy.

Parameters

in_that – An rvalue reference to a CylinderKit to take the impl from.

Returns

A reference to this CylinderKit.

CylinderKit &operator=(CylinderKit const &in_kit)

Copies the source CylinderKit into this CylinderKit.

Parameters

in_kit – The source CylinderKit to copy.

Returns

A reference to this CylinderKit.

bool operator==(CylinderKit const &in_kit) const

Check if the source CylinderKit is equivalent to this CylinderKit.

Parameters

in_kit – The source CylinderKit to compare to this CylinderKit.

Returns

true if the objects are equivalent, false otherwise.

void Set(CylinderKit const &in_kit)

Copies the source CylinderKit into this CylinderKit.

Parameters

in_kit – The source CylinderKit to copy.

CylinderKit &SetBeginNormal(Vector const in_normal)

Sets the normal for this CylinderKit.

Parameters

in_normal – The begin normal for this CylinderKit.

Returns

A reference to this CylinderKit.

CylinderKit &SetCaps(Cylinder::Capping in_capping)

Sets the capping for this CylinderKit.

Parameters

in_capping – The capping for this CylinderKit.

Returns

A reference to this CylinderKit.

CylinderKit &SetEndNormal(Vector const in_normal)

Sets the normal for this CylinderKit.

Parameters

in_normal – The end normal for this CylinderKit.

Returns

A reference to this CylinderKit.

CylinderKit &SetPoints(PointArray const &in_points)

Sets the points for this CylinderKit.

Parameters

in_points – The points for this CylinderKit.

Returns

A reference to this CylinderKit.

CylinderKit &SetPoints(size_t in_count, Point const in_points[])

Sets the points for this CylinderKit.

Parameters
  • in_count – Size of the following array.

  • in_points – The points for this CylinderKit.

Returns

A reference to this CylinderKit.

CylinderKit &SetPriority(int in_priority)

Assigns a specific drawing priority value to the CylinderKit. 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

SubwindowKit::SetRenderingAlgorithm()

Parameters

in_priority – The drawing priority, higher priority items are drawn on top of lower priority items.

Returns

A reference to this object.

CylinderKit &SetRadii(FloatArray const &in_radii)

Sets the radii for this CylinderKit. If the size of the radii array is smaller than the point array, the radii array will be walked repeatedly to determine the radius for all points.

Parameters

in_radii – The radii for this CylinderKit.

Returns

A reference to this CylinderKit.

CylinderKit &SetRadii(size_t in_count, float const in_radii[])

Sets the radii for this CylinderKit. If the size of the radii array is smaller than the point array, the radii array will be walked repeatedly to determine the radius for all points.

Parameters
  • in_count – Size of the following array.

  • in_radii – The radii for this CylinderKit.

Returns

A reference to this CylinderKit.

CylinderKit &SetUserData(intptr_t in_index, ByteArray const &in_data)

Sets user data on this kit.

Parameters
  • in_index – The index of the user data to set.

  • in_data – The bytes of user data to set.

Returns

A reference to this kit.

CylinderKit &SetUserData(intptr_t in_index, size_t in_bytes, byte const in_data[])

Sets user data on this kit.

Parameters
  • in_index – The index of the user data to set.

  • in_bytes – The number of bytes of user data to set.

  • in_data – The bytes of user data to set.

Returns

A reference to this kit.

CylinderKit &SetUserData(IntPtrTArray const &in_indices, ByteArrayArray const &in_data)

Sets user data on this kit.

Parameters
  • in_indices – An array of user data indices to set.

  • in_data – An array of bytes of user data to set.

Returns

A reference to this kit.

CylinderKit &SetVertexIndexColorsByList(size_t in_count, size_t const in_vertices[], float const in_indices[], Cylinder::Component in_apply_to = Cylinder::Component::Faces)

Sets vertex material indices on a selection of arbitrary vertices which apply to the specified cylinder component.

Parameters
  • in_count – Size of the following arrays.

  • in_vertices – The indices of the vertices on which to set the colors.

  • in_indices – The material indices to set on the vertices.

  • in_apply_to – The cylinder component the colors should apply to. Defaults to Cylinder::Component::Faces.

Returns

A reference to this CylinderKit.

CylinderKit &SetVertexIndexColorsByList(size_t in_count, size_t const in_vertices[], float in_index, Cylinder::Component in_apply_to = Cylinder::Component::Faces)

Sets a single material index on a selection of arbitrary vertices which apply to the specified cylinder component.

Parameters
  • in_count – Size of the following array.

  • in_vertices – The indices of the vertices on which to set the color.

  • in_index – The material index to set on the vertices.

  • in_apply_to – The cylinder component the colors should apply to. Defaults to Cylinder::Component::Faces.

Returns

A reference to this CylinderKit.

CylinderKit &SetVertexIndexColorsByList(SizeTArray const &in_vertices, float in_index, Cylinder::Component in_apply_to = Cylinder::Component::Faces)

Sets a single material index on a selection of arbitrary vertices which apply to the specified cylinder component.

Parameters
  • in_vertices – The indices of the vertices on which to set the color.

  • in_index – The material index to set on the vertices.

  • in_apply_to – The cylinder component the colors should apply to. Defaults to Cylinder::Component::Faces.

Returns

A reference to this CylinderKit.

CylinderKit &SetVertexIndexColorsByList(SizeTArray const &in_vertices, FloatArray const &in_indices, Cylinder::Component in_apply_to = Cylinder::Component::Faces)

Sets vertex material indices on a selection of arbitrary vertices which apply to the specified cylinder component. If the sizes of the vertex index and material index arrays are different, the smaller size will be used.

Parameters
  • in_vertices – The indices of the vertices on which to set the colors.

  • in_indices – The material indices to set on the vertices.

  • in_apply_to – The cylinder component the colors should apply to. Defaults to Cylinder::Component::Faces.

Returns

A reference to this CylinderKit.

CylinderKit &SetVertexIndexColorsByRange(size_t in_start, FloatArray const &in_indices, Cylinder::Component in_apply_to = Cylinder::Component::Faces)

Sets vertex material indices on a range of vertices starting at the specified offset which apply to the specified cylinder component.

Parameters
  • in_start – The offset into the vertices for this CylinderKit at which to start setting colors.

  • in_indices – The material indices to set on the vertices for this CylinderKit.

  • in_apply_to – The cylinder component the colors should apply to. Defaults to Cylinder::Component::Faces.

Returns

A reference to this CylinderKit.

CylinderKit &SetVertexIndexColorsByRange(size_t in_start, size_t in_count, float const in_indices[], Cylinder::Component in_apply_to = Cylinder::Component::Faces)

Sets vertex material indices on a range of vertices starting at the specified offset which apply to the specified cylinder component.

Parameters
  • in_start – The offset into the vertices for this CylinderKit at which to start setting colors.

  • in_count – Size of the following array.

  • in_indices – The material indices to set on the vertices for this CylinderKit.

  • in_apply_to – The cylinder component the colors should apply to. Defaults to Cylinder::Component::Faces.

Returns

A reference to this CylinderKit.

CylinderKit &SetVertexIndexColorsByRange(size_t in_start, size_t in_count, float in_index, Cylinder::Component in_apply_to = Cylinder::Component::Faces)

Sets a single material index on a range of vertices starting at the specified offset which apply to the specified cylinder component.

Parameters
  • in_start – The offset into the vertices for this CylinderKit at which to start setting the color.

  • in_count – The number of vertices on which to set the color.

  • in_index – The material index to set on the vertices for this CylinderKit.

  • in_apply_to – The cylinder component the colors should apply to. Defaults to Cylinder::Component::Faces.

Returns

A reference to this CylinderKit.

CylinderKit &SetVertexRGBColorsByList(size_t in_count, size_t const in_vertices[], RGBColor const &in_rgb_color, Cylinder::Component in_apply_to = Cylinder::Component::Faces)

Sets a single RGB color on a selection of arbitrary vertices which apply to the specified cylinder component.

Parameters
  • in_count – Size of the following array.

  • in_vertices – The indices of the vertices on which to set the color.

  • in_rgb_color – The RGB color to set on the vertices.

  • in_apply_to – The cylinder component the colors should apply to. Defaults to Cylinder::Component::Faces.

Returns

A reference to this CylinderKit.

CylinderKit &SetVertexRGBColorsByList(size_t in_count, size_t const in_vertices[], RGBColor const in_rgb_colors[], Cylinder::Component in_apply_to = Cylinder::Component::Faces)

Sets vertex RGB colors on a selection of arbitrary vertices which apply to the specified cylinder component.

Parameters
  • in_count – Size of the following arrays.

  • in_vertices – The indices of the vertices on which to set the colors.

  • in_rgb_colors – The RGB colors to set on the vertices.

  • in_apply_to – The cylinder component the colors should apply to. Defaults to Cylinder::Component::Faces.

Returns

A reference to this CylinderKit.

CylinderKit &SetVertexRGBColorsByList(SizeTArray const &in_vertices, RGBColor const &in_rgb_color, Cylinder::Component in_apply_to = Cylinder::Component::Faces)

Sets a single RGB color on a selection of arbitrary vertices which apply to the specified cylinder component.

Parameters
  • in_vertices – The indices of the vertices on which to set the color.

  • in_rgb_color – The RGB color to set on the vertices.

  • in_apply_to – The cylinder component the colors should apply to. Defaults to Cylinder::Component::Faces.

Returns

A reference to this CylinderKit.

CylinderKit &SetVertexRGBColorsByList(SizeTArray const &in_vertices, RGBColorArray const &in_rgb_colors, Cylinder::Component in_apply_to = Cylinder::Component::Faces)

Sets vertex RGB colors on a selection of arbitrary vertices which apply to the specified cylinder component. If the sizes of the vertex index array and the color array different, the smaller size will be used.

Parameters
  • in_vertices – The indices of the vertices on which to set the colors.

  • in_rgb_colors – The RGB colors to set on the vertices.

  • in_apply_to – The cylinder component the colors should apply to. Defaults to Cylinder::Component::Faces.

Returns

A reference to this CylinderKit.

CylinderKit &SetVertexRGBColorsByRange(size_t in_start, RGBColorArray const &in_rgb_colors, Cylinder::Component in_apply_to = Cylinder::Component::Faces)

Sets vertex RGB colors on a range of vertices starting at the specified offset which apply to the specified cylinder component.

Parameters
  • in_start – The offset into the vertices for this CylinderKit at which to start setting colors.

  • in_rgb_colors – The RGB colors to set on the vertices for this CylinderKit.

  • in_apply_to – The cylinder component the colors should apply to. Defaults to Cylinder::Component::Faces.

Returns

A reference to this CylinderKit.

CylinderKit &SetVertexRGBColorsByRange(size_t in_start, size_t in_count, RGBColor const &in_rgb_color, Cylinder::Component in_apply_to = Cylinder::Component::Faces)

Sets a single RGB color on a range of vertices starting at the specified offset which apply to the specified cylinder component.

Parameters
  • in_start – The offset into the vertices for this CylinderKit at which to start setting the color.

  • in_count – The number of vertices on which to set the color.

  • in_rgb_color – The RGB color to set on the vertices for this CylinderKit.

  • in_apply_to – The cylinder component the colors should apply to. Defaults to Cylinder::Component::Faces.

Returns

A reference to this CylinderKit.

CylinderKit &SetVertexRGBColorsByRange(size_t in_start, size_t in_count, RGBColor const in_rgb_colors[], Cylinder::Component in_apply_to = Cylinder::Component::Faces)

Sets vertex RGB colors on a range of vertices starting at the specified offset which apply to the specified cylinder component.

Parameters
  • in_start – The offset into the vertices for this CylinderKit at which to start setting colors.

  • in_count – Size of the following array.

  • in_rgb_colors – The RGB colors to set on the vertices for this CylinderKit.

  • in_apply_to – The cylinder component the colors should apply to. Defaults to Cylinder::Component::Faces.

Returns

A reference to this CylinderKit.

void Show(CylinderKit &out_kit) const

Copies this CylinderKit into the given CylinderKit.

Parameters

out_kit – The CylinderKit to populate with the contents of this CylinderKit.

bool ShowBeginNormal(Vector &out_normal) const

Shows the begin normal for this CylinderKit.

Parameters

out_normal – The begin normal for this CylinderKit.

Returns

true if begin normal were set, false otherwise.

bool ShowCaps(Cylinder::Capping &out_caps) const

Show the capping for this CylinderKit.

Parameters

out_caps – The capping for this CylinderKit.

Returns

true if a capping was set, false otherwise.

bool ShowEndNormal(Vector &out_normal) const

Shows the end normal for this CylinderKit.

Parameters

out_normal – The end normal for this CylinderKit.

Returns

true if end normal were set, false otherwise.

bool ShowPoints(PointArray &out_points) const

Show the points for this CylinderKit.

Parameters

out_points – The points for this CylinderKit.

Returns

true if points were set, false otherwise.

bool ShowPointsByList(size_t in_count, size_t const in_indices[], PointArray &out_points) const

Show a subset of the points for this CylinderKit by list.

Parameters
  • in_count – The number of points to show.

  • in_indices – The list of point indices to show.

  • out_points – The requested points for this CylinderKit.

Returns

true if all requested points were set, false otherwise.

bool ShowPointsByList(SizeTArray const &in_indices, PointArray &out_points) const

Show a subset of the points for this CylinderKit by list.

Parameters
  • in_indices – The list of point indices to show.

  • out_points – The requested points for this CylinderKit.

Returns

true if all requested points were set, false otherwise.

bool ShowPointsByRange(size_t in_start_index, size_t in_count, PointArray &out_points) const

Show a subset of the points for this CylinderKit by range.

Parameters
  • in_start_index – The first point to show.

  • in_count – The number of points to show.

  • out_points – The requested points for this CylinderKit.

Returns

true if all requested points were set, false otherwise.

bool ShowPriority(int &out_priority) const

Shows the drawing priority.

Parameters

out_priority – The drawing priority, higher priority items are drawn on top of lower priority items.

Returns

true if the setting is valid, false otherwise.

bool ShowRadii(FloatArray &out_radii) const

Show the radii for this CylinderKit.

Parameters

out_radii – The radii for this CylinderKit.

Returns

true if radii were set, false otherwise.

bool ShowUserData(intptr_t in_index, ByteArray &out_data) const

Shows the user data at a given index for this kit.

Parameters
  • in_index – The index of the user data to show.

  • out_data – The user data at the given index.

Returns

true if there is user data at the given index, false otherwise.

bool ShowUserData(IntPtrTArray &out_indices, ByteArrayArray &out_data) const

Shows all user data for this kit.

Parameters
  • out_indices – An array of all user data indices set on this kit.

  • out_data – An array of all user data set on this kit.

Returns

true if there is user data on this kit, false otherwise.

size_t ShowUserDataCount() const

Get the number of user data indices set on this kit.

bool ShowUserDataIndices(IntPtrTArray &out_indices) const

Shows the indices of all user data set on this kit.

Parameters

out_indices – The user data indices set on this kit.

Returns

The number of user data indices set on this kit.

bool ShowVertexColors(Cylinder::Component in_apply_to, MaterialTypeArray &out_types, RGBColorArray &out_rgb_colors, FloatArray &out_indices) const

Shows all the vertex colors of the specified cylinder component.

Parameters
  • in_apply_to – The cylinder component the colors should apply to.

  • out_types – The types of vertex colors for each vertex. If a vertex does not have a vertex color set for the specified cylinder component, the entry in this array will be Material::Type::None.

  • out_rgb_colors – The RGB colors for each vertex. out_rgb_colors[i] is only valid if out_types[i] is Material::Type::RGBColor.

  • out_indices – The material indices for each vertex. The out_indices[i] is only valid if out_types[i] is Material::Type::MaterialIndex.

Returns

true if any vertex colors were shown, false otherwise.

bool ShowVertexColorsByList(SizeTArray const &in_vertices, Cylinder::Component in_apply_to, MaterialTypeArray &out_types, RGBColorArray &out_rgb_colors, FloatArray &out_indices) const

Shows the vertex colors on a selection of arbitrary vertices which apply to the specified cylinder component. The order of the values in the ouput arrays is the same as the input vertex index array, i.e., the values of out_types[i], out_rgb_colors[i], out_rgba_colors[i], and out_indices[i], correspond to the vertex at index in_vertices[i].

Parameters
  • in_vertices – The indices of the vertices on which to show the colors.

  • in_apply_to – The cylinder component the colors should apply to.

  • out_types – The types of vertex colors for each vertex at the specified index. If a vertex at a specified index does not have a vertex color set for the specified component, the entry in this array will be Material::Type::None.

  • out_rgb_colors – The RGB colors for each vertex at the specified index. out_rgb_colors[i] is only valid if out_types[i] is Material::Type::RGBColor.

  • out_indices – The material indices for each vertex at the specified index. The out_indices[i] is only valid if out_types[i] is Material::Type::MaterialIndex.

Returns

true if any specified vertex had a vertex color on the specified component set, false otherwise.

bool ShowVertexColorsByRange(size_t in_start, size_t in_count, Cylinder::Component in_apply_to, MaterialTypeArray &out_types, RGBColorArray &out_rgb_colors, FloatArray &out_indices) const

Shows the vertex colors on a range of vertices starting at the specified offset which apply to the specified cylinder component.

Parameters
  • in_start – The offset into the vertices for this CylinderKit at which to start showing colors.

  • in_count – The number of colors to show.

  • in_apply_to – The cylinder component the colors should apply to.

  • out_types – The types of vertex colors for each vertex in the specified range. If a vertex in the specified range does not have a vertex color set for the specified cylinder component, the entry in this array will be Material::Type::None.

  • out_rgb_colors – The RGB colors for each vertex in the specified range. out_rgb_colors[i] is only valid if out_types[i] is Material::Type::RGBColor.

  • out_indices – The material indices for each vertex in the specified range. The out_indices[i] is only valid if out_types[i] is Material::Type::MaterialIndex.

Returns

true if any vertex in the specified range had a vertex color on the specified component set, false otherwise.

CylinderKit &UnsetAllUserData()

Removes all user data from this kit.

Returns

A reference to this kit.

CylinderKit &UnsetBeginNormal()

Removes the begin normal for this CylinderKit.

Returns

A reference to this CylinderKit.

CylinderKit &UnsetCaps()

Removes the capping for this CylinderKit.

Returns

A reference to this CylinderKit.

CylinderKit &UnsetEndNormal()

Removes the end normal for this CylinderKit.

Returns

A reference to this CylinderKit.

CylinderKit &UnsetEverything()

Removes all settings from the CylinderKit.

Returns

A reference to this CylinderKit.

CylinderKit &UnsetPoints()

Removes the points for this CylinderKit.

Returns

A reference to this CylinderKit.

CylinderKit &UnsetPriority()

Removes a drawing priority setting.

Returns

A reference to this object.

CylinderKit &UnsetRadii()

Removes the radii for this CylinderKit.

Returns

A reference to this CylinderKit.

CylinderKit &UnsetUserData(intptr_t in_index)

Removes the user data at the given index from this kit.

Parameters

in_index – The index of the user data to remove.

Returns

A reference to this kit.

CylinderKit &UnsetUserData(IntPtrTArray const &in_indices)

Removes the user data at the given indices from this kit.

Parameters

in_indices – The indices of the user data to remove.

Returns

A reference to this kit.

CylinderKit &UnsetUserData(size_t in_count, intptr_t const in_indices[])

Removes the user data at the given indices from this kit.

Parameters
  • in_count – The size of the following array.

  • in_indices – The indices of the user data to remove.

Returns

A reference to this kit.

CylinderKit &UnsetVertexColors()

Removes all vertex colors (RGB colors or material indices) for all cylinder components.

Returns

A reference to this CylinderKit.

CylinderKit &UnsetVertexColors(Cylinder::Component in_apply_to)

Removes all vertex colors (RGB colors or material indices) for the specified cylinder component.

Parameters

in_apply_to – The cylinder component for which to remove the colors.

Returns

A reference to this CylinderKit.

CylinderKit &UnsetVertexColorsByList(size_t in_count, size_t const in_vertices[])

Removes the vertex visibilities on a selection of arbitrary vertices.

Parameters
  • in_count – The number of vertex visibilities to remove for this CylinderKit.

  • in_vertices – The indices of the vertices on which to remove the visibilities.

Returns

A reference to this CylinderKit.

CylinderKit &UnsetVertexColorsByList(size_t in_count, size_t const in_vertices[], Cylinder::Component in_apply_to)

Removes the vertex visibilities on a selection of arbitrary vertices.

Parameters
  • in_count – The number of vertex visibilities to remove for this CylinderKit.

  • in_vertices – The indices of the vertices on which to remove the visibilities.

  • in_apply_to – The cylinder component that should be unset.

Returns

A reference to this CylinderKit.

CylinderKit &UnsetVertexColorsByList(SizeTArray const &in_vertices)

Removes the vertex colors (RGB colors or material indices) for all cylinder components on a selection of arbitrary vertices.

Parameters

in_vertices – The indices of the vertices on which to remove the colors.

Returns

A reference to this CylinderKit.

CylinderKit &UnsetVertexColorsByList(SizeTArray const &in_vertices, Cylinder::Component in_apply_to)

Removes the vertex colors (RGB colors or material indices) for the specified cylinder component on a selection of arbitrary vertices.

Parameters
  • in_vertices – The indices of the vertices on which to remove the colors.

  • in_apply_to – The cylinder component for which to remove the colors.

Returns

A reference to this CylinderKit.

CylinderKit &UnsetVertexColorsByRange(size_t in_start, size_t in_count)

Removes the specified range of vertex colors (RGB colors or material indices) for all cylinder components starting at the specified offset.

Parameters
  • in_start – The offset into the vertices for this CylinderKit at which to start removing colors.

  • in_count – The number of vertex colors to remove for this CylinderKit.

Returns

A reference to this CylinderKit.

CylinderKit &UnsetVertexColorsByRange(size_t in_start, size_t in_count, Cylinder::Component in_apply_to)

Removes the specified range of vertex colors (RGB colors or material indices) for the specified cylinder component starting at the specified offset.

Parameters
  • in_start – The offset into the vertices for this CylinderKit at which to start removing colors.

  • in_count – The number of vertex colors to remove for this CylinderKit.

  • in_apply_to – The cylinder component for which to remove the colors.

Returns

A reference to this CylinderKit.

virtual ~CylinderKit()

Public Static Attributes

static const HPS::Type staticType = HPS::Type::CylinderKit