Okay this is a hard question. I’m creating a cube and a pyramid in one vertex array. My problem is to rotate only pyramid vertex not the cube vertex but I don’t know any function that can rotate some vertex. If I try to rotate the vertex I’ll get pyramid and cube rotated.
Share
Either
different vertex arrays and use
different transforms to render each array
or
shader, and pass in some auxiliary
per-vertex info which lets the vertex
shader decide whether each vertex
should be treated as part of the cube or the pyramid (ie apply different transforms in each case). This’d be a bit like using a “blend weight” to do “vertex blending“; except you’re only interested in the binary case.