mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-09-01 15:18:06 +00:00
LibGL+LibSoftGPU: Clean up some for
loops
This commit is contained in:
parent
12d7b4e9ac
commit
a8655fbf52
Notes:
sideshowbarker
2024-07-17 20:35:11 +09:00
Author: https://github.com/gmta
Commit: a8655fbf52
Pull-request: https://github.com/SerenityOS/serenity/pull/12017
Reviewed-by: https://github.com/bgianfo ✅
2 changed files with 5 additions and 8 deletions
|
@ -733,8 +733,8 @@ void Device::draw_primitives(PrimitiveType primitive_type, FloatMatrix4x4 const&
|
|||
Triangle triangle;
|
||||
triangle.vertices[0] = vertices.at(0); // Root vertex is always the vertex defined first
|
||||
|
||||
for (size_t i = 1; i < vertices.size() - 1; i++) // This is technically `n-2` triangles. We start at index 1
|
||||
{
|
||||
// This is technically `n-2` triangles. We start at index 1
|
||||
for (size_t i = 1; i < vertices.size() - 1; i++) {
|
||||
triangle.vertices[1] = vertices.at(i);
|
||||
triangle.vertices[2] = vertices.at(i + 1);
|
||||
m_triangle_list.append(triangle);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue