I have 2 different shapes and 2 sets of patterns. My primary objective is to sometimes hide a portion of the first shape (requiring 2 groups) while simultaneously displaying a section of the second shape (only needing 1 group). Prior to the r72 update, I used the following code:
1st shape:
bufCompaniesGeomNotActive.addDrawCall(0, geomCompaniesNotActive.faces.length * 3, 0);
bufCompaniesGeomNotActive.addDrawCall(0, 0, 0);
2nd shape:
bufCompaniesGeomActive.addDrawCall(0, 0, 0);
In the r72 release, addDrawCall was simply renamed to addGroup. However, the issue lies in having 2 groups for the first shape. Despite my attempts to reveal sections like before:
floor.companiesGeomNotActive.groups[0].start = 0;
floor.companiesGeomNotActive.groups[0].count = obj.startFaceIndexNotActive * 3;
floor.companiesGeomNotActive.groups[1].start = obj.endFaceIndexNotActive * 3;
floor.companiesGeomNotActive.groups[1].count = lengthNotActive - obj.endFaceIndexNotActive * 3;
I have not been successful. I discovered the method
companiesGeomActive.setDrawRange(obj.startFaceIndexActive * 3, 3 * (obj.endFaceIndexActive - obj.startFaceIndexActive));
which works, but how can I apply ranges to multiple groups?