Kanzi 3.9.10
kanzi::QuadDescription Class Reference

Use QuadDescription to create renderable quad geometry. More...

#include <kanzi/core.ui/graphics2d/quad_description.hpp>

Public Member Functions

unsigned int clipBottom (float border)
 Clips from the bottom side.
 
unsigned int clipLeft (float border)
 Clips from the left side.
 
unsigned int clipRight (float border)
 Clips from the right side.
 
unsigned int clipTop (float border)
 Clips from the top side.
 
Vector2 getOffset () const
 Gets the quad offset.
 
Vector2 getSize () const
 Gets the size of the quad.
 
Vector2 getTextureOffset () const
 Gets the offset of the texture.
 
Vector2 getTextureSize () const
 Gets the size of the texture.
 
bool operator!= (const QuadDescription &other) const
 Checks whether two quads are not equal.
 
bool operator== (const QuadDescription &other) const
 Checks whether two quads are equal.
 
 QuadDescription ()=default
 Empty constructor.
 
 QuadDescription (Vector2 offset, Vector2 size)
 Constructor.
 
 QuadDescription (Vector2 offset, Vector2 size, Vector2 texcoordOffset, Vector2 texcoordSize)
 Constructor with full info.
 

Static Public Attributes

static const unsigned int ClippingResultBottom
 Clipping mask - bottom part.
 
static const unsigned int ClippingResultCenter
 Clipping mask - center area.
 
static const unsigned int ClippingResultLeft
 Clipping mask - left part.
 
static const unsigned int ClippingResultOutside
 Layer clipping result - any outside area.
 
static const unsigned int ClippingResultRight
 Clipping mask - right part.
 
static const unsigned int ClippingResultSingleOutsideRectangle
 Single rectangular outside area, do not care which one.
 
static const unsigned int ClippingResultTop
 Clipping mask - top part.
 

Detailed Description

Use QuadDescription to create renderable quad geometry.

Constructor & Destructor Documentation

◆ QuadDescription() [1/3]

kanzi::QuadDescription::QuadDescription ( )
explicitdefault

Empty constructor.

◆ QuadDescription() [2/3]

kanzi::QuadDescription::QuadDescription ( Vector2 offset,
Vector2 size )
inlineexplicit

Constructor.

Parameters
offsetOffset.
sizeSize.

◆ QuadDescription() [3/3]

kanzi::QuadDescription::QuadDescription ( Vector2 offset,
Vector2 size,
Vector2 texcoordOffset,
Vector2 texcoordSize )
inlineexplicit

Constructor with full info.

Parameters
offsetOffset.
sizeSize.
texcoordOffsetTexcoord offset.
texcoordSizeTexcoord size.

Member Function Documentation

◆ clipBottom()

unsigned int kanzi::QuadDescription::clipBottom ( float border)

Clips from the bottom side.

Parameters
borderThe border to which to clip.
Returns
Clip mask of remaining areas.

◆ clipLeft()

unsigned int kanzi::QuadDescription::clipLeft ( float border)

Clips from the left side.

Parameters
borderThe border to which to clip.
Returns
Clip mask of remaining areas.

◆ clipRight()

unsigned int kanzi::QuadDescription::clipRight ( float border)

Clips from the right side.

Parameters
borderThe border to which to clip.
Returns
Clip mask of remaining areas.

◆ clipTop()

unsigned int kanzi::QuadDescription::clipTop ( float border)

Clips from the top side.

Parameters
borderThe border to which to clip.
Returns
Clip mask of remaining areas.

◆ getOffset()

Vector2 kanzi::QuadDescription::getOffset ( ) const
inline

Gets the quad offset.

Returns
Quad offset vector.

◆ getSize()

Vector2 kanzi::QuadDescription::getSize ( ) const
inline

Gets the size of the quad.

Returns
Quad size vector.

◆ getTextureOffset()

Vector2 kanzi::QuadDescription::getTextureOffset ( ) const
inline

Gets the offset of the texture.

Returns
Texture offset vector.

◆ getTextureSize()

Vector2 kanzi::QuadDescription::getTextureSize ( ) const
inline

Gets the size of the texture.

Returns
Texture size vector.

◆ operator==()

bool kanzi::QuadDescription::operator== ( const QuadDescription & other) const
inline

Checks whether two quads are equal.

Parameters
otherThe other quad.
Returns
If the quads are equal, true, otherwise false.

◆ operator!=()

bool kanzi::QuadDescription::operator!= ( const QuadDescription & other) const
inline

Checks whether two quads are not equal.

Parameters
otherThe other quad.
Returns
If the quads are not equal, true, otherwise false.

Member Data Documentation

◆ ClippingResultCenter

const unsigned int kanzi::QuadDescription::ClippingResultCenter
static

Clipping mask - center area.

◆ ClippingResultBottom

const unsigned int kanzi::QuadDescription::ClippingResultBottom
static

Clipping mask - bottom part.

◆ ClippingResultLeft

const unsigned int kanzi::QuadDescription::ClippingResultLeft
static

Clipping mask - left part.

◆ ClippingResultRight

const unsigned int kanzi::QuadDescription::ClippingResultRight
static

Clipping mask - right part.

◆ ClippingResultTop

const unsigned int kanzi::QuadDescription::ClippingResultTop
static

Clipping mask - top part.

◆ ClippingResultSingleOutsideRectangle

const unsigned int kanzi::QuadDescription::ClippingResultSingleOutsideRectangle
static

Single rectangular outside area, do not care which one.

◆ ClippingResultOutside

const unsigned int kanzi::QuadDescription::ClippingResultOutside
static

Layer clipping result - any outside area.


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