internal/graphicscommand: refactoring

This commit is contained in:
Hajime Hoshi 2023-07-30 18:37:18 +09:00
parent 335dab9175
commit 81b7fd7641

View File

@ -175,9 +175,6 @@ func (q *commandQueue) Flush(graphicsDriver graphicsdriver.Graphics, endFrame bo
swapBuffersForGL()
}
})
if endFrame {
q.uint32sBuffer.reset()
}
return
}
@ -215,6 +212,10 @@ func (q *commandQueue) flush(graphicsDriver graphicsdriver.Graphics, endFrame bo
q.vertices = q.vertices[:0]
q.indices = q.indices[:0]
q.tmpNumVertexFloats = 0
if endFrame {
q.uint32sBuffer.reset()
}
}()
cs := q.commands