Draws vector graphics to a bitmap.
#include <graphics/YiCanvas.h>
Public Member Functions | |
| CYICanvas () | |
| virtual | ~CYICanvas () |
| void | SetBitmap (CYIBitmap *pBitmap) |
| void | DrawPath (const CYIPath *pPath, const CYIPaint &paint) |
| void | DrawColor (const CYIColor &clr) |
| void | SetMatrix (const glm::mat3x3 &matrix) |
| const glm::mat3x3 & | GetMatrix () const |
| void | Translate (const glm::vec2 &translate) |
| void | Scale (const glm::vec2 &scale) |
| void | Rotate (float fRotation) |
Protected Member Functions | |
| void | TransformPolygonData (const CYIPolygonData &polygonDataIn, CYIPolygonData *pPolygonDataOut) |
Protected Attributes | |
| glm::mat3x3 | m_Matrix |
| CYIBitmap * | m_pBitmap |
| CYIPolygonFill * | m_pPolygonFill |
| CYICanvas::CYICanvas | ( | ) |
|
virtual |
| void CYICanvas::DrawColor | ( | const CYIColor & | clr | ) |
Draws the entire buffer with a given color.
Draws a path with the given paint.
| const glm::mat3x3& CYICanvas::GetMatrix | ( | ) | const |
Get current transform matrix.
| void CYICanvas::Rotate | ( | float | fRotation | ) |
Apply rotation (degrees) to matrix.
| void CYICanvas::Scale | ( | const glm::vec2 & | scale | ) |
Apply scale to matrix.
| void CYICanvas::SetBitmap | ( | CYIBitmap * | pBitmap | ) |
Sets the current destination buffer.
| void CYICanvas::SetMatrix | ( | const glm::mat3x3 & | matrix | ) |
Set entirely new matrix.
|
protected |
| void CYICanvas::Translate | ( | const glm::vec2 & | translate | ) |
Apply translate to matrix.
|
protected |
|
protected |
|
protected |