1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-09-18 14:27:39 +03:00

0028099: Visualization, OpenGl_Text - handle DIMENSION and SUBTITLE styles within Core Profile

OpenGl_Text now creates VBO for drawing background rectangle.
This commit is contained in:
kgv
2016-11-14 13:14:04 +03:00
committed by apn
parent 45d0af05b9
commit 6fe58c66d9
3 changed files with 102 additions and 32 deletions

View File

@@ -128,6 +128,11 @@ private:
void drawText (const Handle(OpenGl_Context)& theCtx,
const OpenGl_AspectText& theTextAspect) const;
//! Draw rectangle from bounding text box.
void drawRect (const Handle(OpenGl_Context)& theCtx,
const OpenGl_AspectText& theTextAspect,
const OpenGl_Vec4& theColorSubs) const;
//! Main rendering code
void render (const Handle(OpenGl_Context)& theCtx,
const OpenGl_AspectText& theTextAspect,
@@ -141,6 +146,7 @@ protected:
mutable NCollection_Vector<GLuint> myTextures; //!< textures' IDs
mutable NCollection_Vector<Handle(OpenGl_VertexBuffer)> myVertsVbo; //!< VBOs of vertices
mutable NCollection_Vector<Handle(OpenGl_VertexBuffer)> myTCrdsVbo; //!< VBOs of texture coordinates
mutable Handle(OpenGl_VertexBuffer) myBndVertsVbo;//!< VBOs of vertices for bounding box
mutable Font_Rect myBndBox;
protected: