(self, view, renderer)
| 533 | self._points.append(point) |
| 534 | |
| 535 | def draw(self, view, renderer): |
| 536 | super(TrianglePrim, self).draw(view, renderer) |
| 537 | |
| 538 | view.beginGL() |
| 539 | glFT = renderer.glFunctionTable() |
| 540 | glFT.glPushAttrib(omr.MGL_LINE_BIT) |
| 541 | glFT.glBegin(omr.MGL_TRIANGLES) |
| 542 | |
| 543 | for i, point in enumerate(self._points): |
| 544 | # unpacking the color in a color 3f |
| 545 | if self._is_color_list(): |
| 546 | glFT.glColor3f(*self.colors[i]) |
| 547 | else: |
| 548 | glFT.glColor3f(*self.colors) |
| 549 | # drawing the point |
| 550 | glFT.glVertex3f(point.x, point.y, point.z) |
| 551 | |
| 552 | glFT.glEnd() |
| 553 | glFT.glPopAttrib() |
| 554 | view.endGL() |
| 555 | |
| 556 | |
| 557 | # === Scene Manager === |
nothing calls this directly
no test coverage detected