New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Parallel convexSweepTests #2004
Comments
Using a sensor sphere test VS simplified bounds should return the shapes
the capsule could be colliding with
Only checking this data would remove much of your itteration
In upbge we recently setup bvhtree so we can use it to get overlaps quickly.
(so simplified bounds check yields potential collision bodies, and bvhtree
returns overlapping leaves)
On Nov 25, 2018 9:10 PM, "Andrei Kortunov" <notifications@github.com> wrote:
Currently in OpenMW we use the Bullet for collision detection.
Basically, we have a btCollisionWorld with a lot of static compound shapes
(based on triangles) and couple of dozens of dynamic moving actors (which
use capsules or box shapes).
To detect collisions, we iterate over actors and use the convexSweepTest
for every actor in the single thread.
With many actors in area or with not fast CPU performance can be pretty low.
Is there a correct way to batch convexSweepTests?
I found this
<https://www.reddit.com/r/gamedev/comments/7nv541/bullet_physics_and_multiple_threads/>
thread on Reddit, where user built Bullet with the
DBULLET2_USE_THREAD_LOCKS=ON and just executed convexSweepTest in different
threads, but I do not know if it is a proper solution.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#2004>, or mute the thread
<https://github.com/notifications/unsubscribe-auth/AG25WWX2hp5JX26wQ3fP-O5-ZfNfSFK5ks5uy3ffgaJpZM4YyVZD>
.
|
@BluePrintRandom You mind explaining things a bit more, many of the terms you are using are flying over my head and like that of others? Also, the question that was asked hasn't yet be answered. :) |
In the bullet examples, the BenchmarkDemo has an example of doing raycasts in parallel (look for "USE_PARALLEL_RAYCASTS"). The same method should work for doing parallel convex sweeps as well. This example uses the thread management system included with Bullet, however it isn't required -- the convex sweep should be threadsafe (so long as bullet was compiled with the "BT_THREADSAFE=1" option) -- so any method for managing the threads should work just as well. Note that "BULLET2_USE_THREAD_LOCKS" is only used in Cmake (not in the code). It is a Cmake configuration option that simply sets the definition of "BT_THREADSAFE". Bullet code only checks for "BT_THREADSAFE". |
Currently in OpenMW we use the Bullet for collision detection.
Basically, we have a btCollisionWorld with a lot of static compound shapes (based on triangles) and with a couple of dozens of dynamic moving actors (which use capsules or box shapes).
To detect collisions, we iterate over actors and use the convexSweepTest for every actor in the single thread.
With many actors in area or with not fast CPU performance can be pretty low.
Is there a correct way to batch convexSweepTests?
I found this thread on Reddit, where user built Bullet with the -DBULLET2_USE_THREAD_LOCKS=ON and just executed convexSweepTests in different threads, but I do not know if it is a proper solution.
The text was updated successfully, but these errors were encountered: