|
Otclient 1.0
14/8/2020
|
#include <painterogl.h>


Classes | |
| struct | PainterState |
Public Member Functions | |
| PainterOGL () | |
| virtual | ~PainterOGL () |
| virtual void | bind () |
| virtual void | unbind () |
| void | resetState () |
| virtual void | refreshState () |
| void | saveState () |
| void | saveAndResetState () |
| void | restoreSavedState () |
| void | clear (const Color &color) |
| void | clearRect (const Color &color, const Rect &rect) |
| virtual void | setTransformMatrix (const Matrix3 &transformMatrix) |
| virtual void | setProjectionMatrix (const Matrix3 &projectionMatrix) |
| virtual void | setTextureMatrix (const Matrix3 &textureMatrix) |
| virtual void | setCompositionMode (CompositionMode compositionMode) |
| virtual void | setBlendEquation (BlendEquation blendEquation) |
| virtual void | setClipRect (const Rect &clipRect) |
| virtual void | setShaderProgram (PainterShaderProgram *shaderProgram) |
| virtual void | setTexture (Texture *texture) |
| virtual void | setAlphaWriting (bool enable) |
| void | setTexture (const TexturePtr &texture) |
| void | setResolution (const Size &resolution) |
| void | scale (float x, float y) |
| void | translate (float x, float y) |
| void | rotate (float angle) |
| void | rotate (float x, float y, float angle) |
| void | pushTransformMatrix () |
| void | popTransformMatrix () |
| Matrix3 | getTransformMatrix () |
| Matrix3 | getProjectionMatrix () |
| Matrix3 | getTextureMatrix () |
| BlendEquation | getBlendEquation () |
| PainterShaderProgram * | getShaderProgram () |
| bool | getAlphaWriting () |
| void | resetBlendEquation () |
| void | resetTexture () |
| void | resetAlphaWriting () |
| void | resetTransformMatrix () |
Public Member Functions inherited from Painter | |
| Painter () | |
| virtual | ~Painter () |
| virtual void | drawCoords (CoordsBuffer &coordsBuffer, DrawMode drawMode=Triangles)=0 |
| virtual void | drawFillCoords (CoordsBuffer &coordsBuffer)=0 |
| virtual void | drawTextureCoords (CoordsBuffer &coordsBuffer, const TexturePtr &texture)=0 |
| virtual void | drawTexturedRect (const Rect &dest, const TexturePtr &texture, const Rect &src)=0 |
| void | drawTexturedRect (const Rect &dest, const TexturePtr &texture) |
| virtual void | drawUpsideDownTexturedRect (const Rect &dest, const TexturePtr &texture, const Rect &src)=0 |
| virtual void | drawRepeatedTexturedRect (const Rect &dest, const TexturePtr &texture, const Rect &src)=0 |
| virtual void | drawFilledRect (const Rect &dest)=0 |
| virtual void | drawFilledTriangle (const Point &a, const Point &b, const Point &c)=0 |
| virtual void | drawBoundingRect (const Rect &dest, int innerLineWidth=1)=0 |
| virtual void | setColor (const Color &color) |
| void | setShaderProgram (const PainterShaderProgramPtr &shaderProgram) |
| void | scale (float factor) |
| void | translate (const Point &p) |
| void | rotate (const Point &p, float angle) |
| virtual void | setOpacity (float opacity) |
| Size | getResolution () |
| Color | getColor () |
| float | getOpacity () |
| Rect | getClipRect () |
| CompositionMode | getCompositionMode () |
| void | resetClipRect () |
| void | resetOpacity () |
| void | resetCompositionMode () |
| void | resetColor () |
| void | resetShaderProgram () |
| virtual bool | hasShaders ()=0 |
Protected Member Functions | |
| void | updateGlTexture () |
| void | updateGlCompositionMode () |
| void | updateGlBlendEquation () |
| void | updateGlClipRect () |
| void | updateGlAlphaWriting () |
| void | updateGlViewport () |
Protected Attributes | |
| CoordsBuffer | m_coordsBuffer |
| std::vector< Matrix3 > | m_transformMatrixStack |
| Matrix3 | m_transformMatrix |
| Matrix3 | m_projectionMatrix |
| Matrix3 | m_textureMatrix |
| BlendEquation | m_blendEquation |
| Texture * | m_texture |
| bool | m_alphaWriting |
| PainterState | m_olderStates [10] |
| int | m_oldStateIndex |
| uint | m_glTextureId |
Protected Attributes inherited from Painter | |
| PainterShaderProgram * | m_shaderProgram |
| CompositionMode | m_compositionMode |
| Color | m_color |
| Size | m_resolution |
| float | m_opacity |
| Rect | m_clipRect |
Additional Inherited Members | |
Public Types inherited from Painter | |
| enum | BlendEquation { BlendEquation_Add, BlendEquation_Max } |
| enum | CompositionMode { CompositionMode_Normal, CompositionMode_Multiply, CompositionMode_Add, CompositionMode_Replace, CompositionMode_DestBlending, CompositionMode_Light } |
| enum | DrawMode { Triangles = GL_TRIANGLES, TriangleStrip = GL_TRIANGLE_STRIP } |
Definition at line 28 of file painterogl.h.
| PainterOGL::PainterOGL | ( | ) |
|
inlinevirtual |
Definition at line 47 of file painterogl.h.
|
inlinevirtual |
Reimplemented from Painter.
Reimplemented in PainterOGL1, and PainterOGL2.
Definition at line 49 of file painterogl.h.


|
virtual |
Implements Painter.
Definition at line 105 of file painterogl.cpp.

|
inline |
Definition at line 87 of file painterogl.h.
|
inline |
Definition at line 85 of file painterogl.h.
|
inline |
Definition at line 83 of file painterogl.h.
|
inline |
Definition at line 86 of file painterogl.h.
|
inline |
Definition at line 84 of file painterogl.h.
|
inline |
Definition at line 82 of file painterogl.h.
|
virtual |
Implements Painter.
Definition at line 245 of file painterogl.cpp.

|
virtual |
Implements Painter.
Definition at line 239 of file painterogl.cpp.
|
virtual |
Reimplemented in PainterOGL1.
Definition at line 54 of file painterogl.cpp.


|
inline |
Definition at line 91 of file painterogl.h.


|
inline |
Definition at line 89 of file painterogl.h.


| void PainterOGL::resetState | ( | ) |
Definition at line 41 of file painterogl.cpp.


|
inline |
Definition at line 90 of file painterogl.h.


|
inline |
Definition at line 92 of file painterogl.h.


|
virtual |
Implements Painter.
Definition at line 88 of file painterogl.cpp.

|
virtual |
Implements Painter.
Definition at line 221 of file painterogl.cpp.


|
virtual |
Implements Painter.
Definition at line 232 of file painterogl.cpp.

|
virtual |
Implements Painter.
Definition at line 82 of file painterogl.cpp.

|
virtual |
Implements Painter.
Definition at line 64 of file painterogl.cpp.

|
virtual |
Implements Painter.
Definition at line 199 of file painterogl.cpp.

|
virtual |
Implements Painter.
Definition at line 164 of file painterogl.cpp.


|
virtual |
Implements Painter.
Definition at line 128 of file painterogl.cpp.


|
virtual |
Implements Painter.
Definition at line 136 of file painterogl.cpp.


|
virtual |
Implements Painter.
Definition at line 120 of file painterogl.cpp.


|
inlinevirtual |
Reimplemented in PainterOGL1.
Definition at line 62 of file painterogl.h.

|
virtual |
Reimplemented from Painter.
Definition at line 173 of file painterogl.cpp.


|
inlinevirtual |
Reimplemented from Painter.
Definition at line 67 of file painterogl.h.

|
inline |
Definition at line 71 of file painterogl.h.


|
virtual |
Implements Painter.
Definition at line 144 of file painterogl.cpp.


|
inlinevirtual |
Reimplemented in PainterOGL1.
Definition at line 63 of file painterogl.h.

|
inlinevirtual |
Reimplemented in PainterOGL1.
Definition at line 61 of file painterogl.h.

|
virtual |
Implements Painter.
Definition at line 210 of file painterogl.cpp.


|
inlinevirtual |
Reimplemented from Painter.
Reimplemented in PainterOGL1, and PainterOGL2.
Definition at line 50 of file painterogl.h.
|
protected |
|
protected |
Definition at line 285 of file painterogl.cpp.


|
protected |
Definition at line 295 of file painterogl.cpp.


|
protected |
Definition at line 258 of file painterogl.cpp.


|
protected |
|
protected |
Definition at line 314 of file painterogl.cpp.


|
protected |
Definition at line 111 of file painterogl.h.
|
protected |
Definition at line 109 of file painterogl.h.
|
protected |
Definition at line 102 of file painterogl.h.
|
protected |
Definition at line 116 of file painterogl.h.
|
protected |
Definition at line 113 of file painterogl.h.
|
protected |
Definition at line 114 of file painterogl.h.
|
protected |
Definition at line 106 of file painterogl.h.
|
protected |
Definition at line 110 of file painterogl.h.
|
protected |
Definition at line 107 of file painterogl.h.
|
protected |
Definition at line 105 of file painterogl.h.
|
protected |
Definition at line 104 of file painterogl.h.