Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
如果我想画线,只有两个位置的带有 GL_LINES 基元的纯线。
我也应该打开 glPolygonMode 到 GL_LINE 吗?或者将绘图原语设置为 GL_LINES 就足够了?
编辑:我使用现代 OpenGL 技术
在渲染线图元时,更改多边形模式是无用且多余的。顾名思义,多边形模式只影响多边形(三角形图元),但不影响线和点图元。glPolygonMode只控制多边形(三角形)的光栅化。
glPolygonMode