Fixed physics initialization in benchmark 40/302440/1
authorDavid Steele <david.steele@samsung.com>
Wed, 6 Dec 2023 18:41:15 +0000 (18:41 +0000)
committerDavid Steele <david.steele@samsung.com>
Wed, 6 Dec 2023 18:41:15 +0000 (18:41 +0000)
commit29710d9332d9230d4d88c1bb6ef20f029e0af34a
tree9236014f210e1f589971688a07d95bb9dfbcad7b
parent8144f1252578b62ec6c01e58ba764740e2929d4f
Fixed physics initialization in benchmark

Physics bodies created in the same location creates too many
collision arbiters when added to the space, and initialization
takes too long

Solution: ensure that they are positioned separately before
adding to the space.

Note, if there are so many particles that they overlap, then collision
is noticeably slow.

Change-Id: I88f8ce970bcceb90b213d0f9999400a4e2134944
Signed-off-by: David Steele <david.steele@samsung.com>
examples/benchmark-2dphysics/benchmark-2d-physics-controller.cpp