Triangle tessellation steps8/4/2023 ![]() ![]() So this setting is only a starting point, not an ending point. Each triangle's final winding order will be based on how the positions of those vertices are transformed by the TES (or a subsequent Geometry Shader). Note that this only specifies the winding order of the triangles in the space of the abstract patch. Which is considered "front" is still defined by glFrontFace. The winding order is specified in terms of the direction: cw and ccw. ![]() It is a layout option specified by the TES, rather than a runtime value. The winding order of the abstract patch vertices generated during Tessellation is controlled by the Tessellation Evaluation Shader. Which side is considered the "front" side is controlled by this function: Counter-clockwise means that the three vertices, in order, rotate counter-clockwise around the triangle's center. Clockwise means that the three vertices, in order, rotate clockwise around the triangle's center. Given an ordering of the triangle's three vertices, a triangle can appear to have a clockwise winding or counter-clockwise winding. This is determined by the winding order of the triangle. The order of the vertices in a triangle, when combined with their visual orientation, can be used to determine whether the triangle is being seen from the "front" or the "back" side. When vertices are broken down into Primitives during Primitive Assembly, the order of the vertices relative to the others in the primitive is noted. The Tessellation Evaluation Shader can directly control the order of the vertices in the tessellated patch using special options. The Geometry Shader can alter the order, but even then, the vertices created by each GS invocation are ordered relative to the other vertices. ![]() When the user issues a Drawing Command, the vertices processed by the Rendering Pipeline are processed in the order provided by Vertex Specification. ![]()
0 Comments
Leave a Reply.AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |