Qt3d. Draw transparent QSphereMesh over triangles

前端 未结 3 1105
太阳男子
太阳男子 2020-11-30 14:11

I have a function that draws triangles through OpenGL

I draw two triangles by pressing a button (function on_drawMapPushButton_clicked()).

Then i draw a sph

3条回答
  •  野趣味
    野趣味 (楼主)
    2020-11-30 14:47

    My mistake was that i did wrong order of creating and deletion of Triangles and Sphere entities.

    In pseudo code right order is as follows:

    clearTriangles();
    clearSphere();       
    drawTriangles();
    drawSphere();
    

提交回复
热议问题