ImageGlyphElement

class ImageGlyphElement : public HPS::GlyphElement

The ImageGlyphElement class is a user space object.

Public Functions

ImageGlyphElement()

The default constructor creates an empty ImageGlyphElement object.

ImageGlyphElement(GlyphElement const &in_that)

This constructor creates a ImageGlyphElement object that contains the same settings as the source GlyphElement. The copy will only be successful if the source glyph element is really an upcast of a line glyph element. Otherwise the copy will fail and the resulting LineGlyphElement will be invalid.

Parameters:

in_that – The source GlyphElement to copy.

ImageGlyphElement(ImageGlyphElement &&in_that)

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

Parameters:

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

ImageGlyphElement(ImageGlyphElement const &in_that)

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

Parameters:

in_that – The source ImageGlyphElement to copy.

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.

ImageGlyphElement &operator=(ImageGlyphElement &&in_that)

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

Parameters:

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

Returns:

A reference to this LineGlyphElement.

void SetDecimationFilter(bool in_filter)

Sets if decimation filtering is use for this ImageGlyphElement.

Parameters:

in_filter – If the glyph should use decimation filtering. The default is true.

void SetFixedColoring(bool in_fixed_color)

Sets if fixed color is used for this ImageGlyphElement.

Parameters:

in_fixed_color – If the glyph should use the image colors or the effective marker color. The default is true.

void SetFixedScaling(bool in_fixed_scale)

Sets if fixed scaling is used for this ImageGlyphElement.

Parameters:

in_fixed_scale – If the glyph should use the image size for scaling or the effective marker size. The default is true.

void SetInterpolationFilter(bool in_filter)

Sets if interpolation filtering is use for this ImageGlyphElement.

Parameters:

in_filter – If the glyph should use interpolation filtering. The default is true.

void SetOffset(float in_x_offset, float in_y_offset)

Sets an offset for the center of this ImageGlyphElement. The expected range of offset values is [0, 1]. This locates the origin of the glyph coordinate system relative to the center of the glyph.

Parameters:
  • in_x_offset – The x offset of the source image. The default is 0.5.

  • in_y_offset – The y offset of the source image. The default is 0.5.

void SetRotation(float in_rotation)

Sets a rotation this ImageGlyphElement.

Parameters:

in_rotation – The rotation in degrees for the source image. The default is 0.0.

void SetScaling(float in_x_scale, float in_y_scale)

Sets extra scaling for this ImageGlyphElement.

Parameters:
  • in_x_scale – The x scaling of the source image. The default is 1.0.

  • in_y_scale – The y scaling of the source image. The default is 1.0.

void SetSource(char const *in_name)

Sets the source image by name for this ImageGlyphElement.

Parameters:

in_name – The name of the source image.

bool ShowDecimationFilter(bool &out_filter) const

Shows if decimation filtering is use for this ImageGlyphElement.

Parameters:

out_filter – If the glyph should use decimation filtering.

Returns:

true if a decimation filtering was set, false otherwise.

bool ShowFixedColoring(bool &out_fixed_color) const

Shows if fixed color is used for this ImageGlyphElement.

Parameters:

out_fixed_color – If the glyph should use the image colors or the effective marker color.

Returns:

true if a fixed color was set, false otherwise.

bool ShowFixedScaling(bool &out_fixed_scale) const

Shows if fixed scaling is used for this ImageGlyphElement.

Parameters:

out_fixed_scale – If the glyph should use the image size for scaling or the effective marker size.

Returns:

true if a fixed scaling was set, false otherwise.

bool ShowInterpolationFilter(bool &out_filter) const

Shows if interpolation filtering is use for this ImageGlyphElement.

Parameters:

out_filter – If the glyph should use interpolation filtering.

Returns:

true if a interpolation filtering was set, false otherwise.

bool ShowOffset(float &out_x_offset, float &out_y_offset) const

Shows an offset for the center of this ImageGlyphElement.

Parameters:
  • out_x_offset – The x offset of the source image.

  • out_y_offset – The y offset of the source image.

Returns:

true if an offset was set, false otherwise.

bool ShowRotation(float &out_rotation) const

Shows a rotation this ImageGlyphElement.

Parameters:

out_rotation – The rotation in degrees for the source image.

Returns:

true if a rotation was set, false otherwise.

bool ShowScaling(float &out_x_scale, float &out_y_scale) const

Shows extra scaling for this ImageGlyphElement.

Parameters:
  • out_x_scale – The x scaling of the source image.

  • out_y_scale – The y scaling of the source image.

Returns:

true if a scaling was set, false otherwise.

bool ShowSource(UTF8 &out_name) const

Shows the source image by name for this ImageGlyphElement.

Parameters:

out_name – UTF8-encoded name of the source image.

Returns:

true if a source image name was set, false otherwise.

~ImageGlyphElement()

Public Static Attributes

static const HPS::Type staticType = HPS::Type::ImageGlyphElement