通过对目前比较常用的GDI绘图和OpenGL绘图进行比较分析,显示了用OpenGL开发的三维有限元图形系统具有的速度快、绘图功能强、捕捉方便、视觉效果好等优越性。介绍了PKPM-SAUSAGE软件三维模型绘图流程,凹多边形网格化显示技术,背面剔除及alpha混合,实时旋转、平移、缩放算法和高效的捕捉算法,以及后处理结果平滑显示技术和着色器编程颜色修正技术。最后通过工程实例验证了PKPM-SAUSAGE软件OpenGL图形显示、旋转、平移、缩放及捕捉的高效性。
In this paper,the superiorities of 3D finite element graphics system developed by OpenGL, such as high speed,powerful drawing function, convenient selection and feedback and nice visual effect are demonsrated through the comparison between GDI and OpenGL,which are both popular in graphies system at present. The paper also introduces drawing process of 3D model by OpenGL, display technology of concave polygon, back face culling and alpha blending, real-time rotation, translation, sealing, and efficient capture algorithm of PKPM-SAUSAGE software as well as the results display smoothing technology and color correction technology by shader programming in post-processing. Finally, the efficiency of OpenGL graphics display, rotation, translation, scaling and capture in PKPM-SAUSAGE software is verified by practical engineering examples.