[Bf-blender-cvs] [883c62d5d3c] blender2.8: Add comment about vertex format created in OCIO
Sergey Sharybin
noreply at git.blender.org
Mon May 8 17:06:03 CEST 2017
Commit: 883c62d5d3c896b44d8e9503629c1079654fb284
Author: Sergey Sharybin
Date: Mon May 8 16:40:48 2017 +0200
Branches: blender2.8
https://developer.blender.org/rB883c62d5d3c896b44d8e9503629c1079654fb284
Add comment about vertex format created in OCIO
===================================================================
M intern/opencolorio/ocio_impl_glsl.cc
===================================================================
diff --git a/intern/opencolorio/ocio_impl_glsl.cc b/intern/opencolorio/ocio_impl_glsl.cc
index 8323cffd09b..89df3080749 100644
--- a/intern/opencolorio/ocio_impl_glsl.cc
+++ b/intern/opencolorio/ocio_impl_glsl.cc
@@ -416,7 +416,14 @@ bool OCIOImpl::setupGLSLDraw(OCIO_GLSLDrawState **state_r, OCIO_ConstProcessorRc
glActiveTexture(GL_TEXTURE0);
- /* IMM needs vertex format even if we don't draw with it */
+ /* IMM needs vertex format even if we don't draw with it.
+ *
+ * NOTE: The only reason why it's here is because of Cycles viewport.
+ * All other areas are managing their own vertex formats.
+ * Doing it here is probably harmless, but kind of stupid.
+ *
+ * TODO(sergey): Look into some nicer solution.
+ */
VertexFormat *format = immVertexFormat();
VertexFormat_add_attrib(format, "pos", COMP_F32, 2, KEEP_FLOAT);
VertexFormat_add_attrib(format, "texCoord", COMP_F32, 2, KEEP_FLOAT);
More information about the Bf-blender-cvs
mailing list