
OpenGL
justslowdown_going
这个作者很懒,什么都没留下…
展开
-
RGB颜色编码与解码
rgb颜色的编码与解码原创 2023-02-22 13:16:49 · 581 阅读 · 0 评论 -
OSG深度应用:可渲染对象的编译、裁剪和绘制
osg中可渲染对象的剔除、包围盒计算原创 2022-02-24 17:04:18 · 856 阅读 · 0 评论 -
如果在glsl中,通过四元数旋转一个顶点?
原文:How to Rotate a Vertex by a Quaternion in GLSL (*Updated*) | Geeks3DIn a vertex shader, the rotation and position are usually encoded in the model matrix and we have something like this: vec4 worldPos = ModelMatrix * InPosition; Here is another method t原创 2021-09-12 14:40:05 · 379 阅读 · 0 评论 -
OSG实例化渲染:Instancing
实例化的两种方式 当实例数量较少时选择通过uniform数组 + gl_InstanceID方式实现;当数据较大时超过uniform限定时选择通过顶点数组的方式实现,需要用到的相关opengl函数glVertexAttribDivisor(int a, int b)。 方式二:vbo + glVertexAttribDivisor { //----------------instance t...原创 2020-04-30 13:55:53 · 2306 阅读 · 1 评论