|
150 | 150 | context, {0, static_cast<uint32_t>(count), mTriFanArraysIndexBuffer, 0})); |
151 | 151 | } |
152 | 152 |
|
153 | | - ANGLE_TRY(setupDraw(context, gl::PrimitiveMode::Triangles, first, genIndicesCount, 1, |
154 | | - gl::DrawElementsType::UnsignedInt, reinterpret_cast<const void *>(0))); |
| 153 | + ANGLE_TRY(setupDraw(context, gl::PrimitiveMode::TriangleFan, first, count, 1, |
| 154 | + gl::DrawElementsType::InvalidEnum, reinterpret_cast<const void *>(0))); |
155 | 155 |
|
156 | 156 | // Draw with the zero starting index buffer, shift the vertex index using baseVertex instanced |
157 | 157 | // draw: |
|
173 | 173 | context, {static_cast<uint32_t>(first), static_cast<uint32_t>(count), genIdxBuffer, |
174 | 174 | genIdxBufferOffset})); |
175 | 175 |
|
176 | | - ANGLE_TRY(setupDraw(context, gl::PrimitiveMode::Triangles, 0, genIndicesCount, 1, |
177 | | - gl::DrawElementsType::UnsignedInt, |
178 | | - reinterpret_cast<const void *>(genIdxBufferOffset))); |
| 176 | + ANGLE_TRY(setupDraw(context, gl::PrimitiveMode::TriangleFan, first, count, 1, |
| 177 | + gl::DrawElementsType::InvalidEnum, reinterpret_cast<const void *>(0))); |
179 | 178 |
|
180 | 179 | mRenderEncoder.drawIndexed(MTLPrimitiveTypeTriangle, genIndicesCount, MTLIndexTypeUInt32, |
181 | 180 | genIdxBuffer, genIdxBufferOffset); |
|
258 | 257 |
|
259 | 258 | ANGLE_TRY(mTriFanIndexBuffer.commit(this)); |
260 | 259 |
|
261 | | - ANGLE_TRY(setupDraw(context, gl::PrimitiveMode::Triangles, 0, genIndicesCount, 1, |
262 | | - gl::DrawElementsType::UnsignedInt, |
263 | | - reinterpret_cast<const void *>(genIdxBufferOffset))); |
| 260 | + ANGLE_TRY(setupDraw(context, gl::PrimitiveMode::TriangleFan, 0, count, 1, type, indices)); |
264 | 261 |
|
265 | 262 | mRenderEncoder.drawIndexed(MTLPrimitiveTypeTriangle, genIndicesCount, MTLIndexTypeUInt32, |
266 | 263 | genIdxBuffer, genIdxBufferOffset); |
|
0 commit comments