Lysa  0.0
Lysa 3D Engine
UIRenderer Class Reference
+ Inheritance diagram for UIRenderer:

Public Member Functions

 UIRenderer (const RenderingConfiguration &renderingConfiguration)
 
void resize (const vireo::Extent &extent)
 
auto getAspectRatio () const
 
void drawLine (const float2 &start, const float2 &end)
 
void drawFilledRect (const ui::Rect &rect)
 
void drawFilledRect (const ui::Rect &rect, const std::shared_ptr< Image > &texture)
 
void drawFilledRect (float x, float y, float w, float h, const std::shared_ptr< Image > &texture=nullptr)
 
void drawText (const std::string &text, Font &font, float fontScale, float x, float y)
 
auto setPenColor (const float4 &color)
 
auto setTranslate (const float2 &t)
 
auto setTransparency (const float a)
 
- Public Member Functions inherited from VectorRenderer
 VectorRenderer (bool depthTestEnable, bool enableAlphaBlending, bool useTextures, const RenderingConfiguration &renderingConfiguration, const std::string &name="VectorRenderer", const std::string &shadersName="vector", const std::string &glyphShadersName="glyph", bool filledTriangles=false, bool useCamera=true)
 
void drawLine (const float3 &from, const float3 &to, const float4 &color)
 
void drawTriangle (const float3 &v1, const float3 &v2, const float3 &v3, const float4 &color)
 
void drawText (const std::string &text, Font &font, float fontScale, const float3 &position, const quaternion &rotation, const float4 &innerColor)
 
void restart ()
 
void update (const vireo::CommandList &commandList, uint32 frameIndex)
 
void render (vireo::CommandList &commandList, const Scene &scene, const std::shared_ptr< vireo::RenderTarget > &colorAttachment, const std::shared_ptr< vireo::RenderTarget > &depthAttachment, uint32 frameIndex)
 
void render (vireo::CommandList &commandList, const std::shared_ptr< vireo::RenderTarget > &colorAttachment, const std::shared_ptr< vireo::RenderTarget > &depthAttachment, uint32 frameIndex)
 
virtual ~VectorRenderer () = default
 
 VectorRenderer (VectorRenderer &) = delete
 
VectorRenderer & operator= (VectorRenderer &) = delete
 

Additional Inherited Members

- Protected Member Functions inherited from VectorRenderer
int32 addTexture (const std::shared_ptr< Image > &texture)
 
int32 addFont (const Font &font)
 
- Protected Attributes inherited from VectorRenderer
const RenderingConfigurationconfig
 
bool vertexBufferDirty {true}
 
std::vector< VertexlinesVertices
 
std::vector< VertextriangleVertices
 
std::vector< VertexglyphVertices
 

Constructor & Destructor Documentation

UIRenderer ( const RenderingConfiguration renderingConfiguration)

Member Function Documentation

void drawFilledRect ( const ui::Rect rect)
void drawFilledRect ( const ui::Rect rect,
const std::shared_ptr< Image > &  texture 
)
void drawFilledRect ( float  x,
float  y,
float  w,
float  h,
const std::shared_ptr< Image > &  texture = nullptr 
)
void drawLine ( const float2 &  start,
const float2 &  end 
)
void drawText ( const std::string &  text,
Font font,
float  fontScale,
float  x,
float  y 
)
auto getAspectRatio ( ) const
inline
void resize ( const vireo::Extent &  extent)
auto setPenColor ( const float4 &  color)
inline
auto setTranslate ( const float2 &  t)
inline
auto setTransparency ( const float  a)
inline