Search found 4546 matches

by Norbo
Wed Jul 15, 2020 5:34 pm
Forum: Questions and Help
Topic: [Nuget] Include Bepu1 and Bepu2 in one Project
Replies: 6
Views: 13005

Re: [Nuget] Include Bepu1 and Bepu2 in one Project

Could you explain what you're deploying to that requires strong naming? I ask primarily because of this issue.

Also, could you elaborate on the usage of both bepuphysics1 and bepuphysics2 in one project?
by Norbo
Tue Jul 14, 2020 5:10 pm
Forum: Questions and Help
Topic: Applying force on dynamics with statics
Replies: 3
Views: 9506

Re: Applying force on dynamics with statics

Sounds like the PositionFirstTimestepper, which integrates velocity into position at the beginning of the frame. If the velocity is modified outside the timestep, it'll move the body before collision detection or the solver has a chance to stop it. Switching to the PositionLastTimestepper would prob...
by Norbo
Thu Jul 09, 2020 1:18 am
Forum: General
Topic: Pools
Replies: 7
Views: 16437

Re: Pools

Pretty much, with one small note: using a collection of pools does not necessarily imply locking and contention provided that every worker has a guarantee it's the only one touching a pool; the annoyance is primarily ownership tracking. Also, assuming that the shapes you're concerned about are prima...
by Norbo
Wed Jul 08, 2020 9:24 pm
Forum: General
Topic: Pools
Replies: 7
Views: 16437

Re: Pools

Is there a downside to holding onto the same pools for the lifetime of the app? If we Return memory, but never Clear the pool, will it leak? A leak could happen if you let a BufferPool go out of use while it retains pinned references to memory. If you intend to let a BufferPool get garbage collecte...
by Norbo
Wed Jul 08, 2020 5:37 pm
Forum: Questions and Help
Topic: [Nuget] Include Bepu1 and Bepu2 in one Project
Replies: 6
Views: 13005

Re: [Nuget] Include Bepu1 and Bepu2 in one Project

I'll definitely consider it, but could you elaborate more on your use case so I can understand the context better?
by Norbo
Tue Jul 07, 2020 9:07 pm
Forum: General
Topic: about save the snapshot of the space
Replies: 3
Views: 8751

Re: about save the snapshot of the space

Rewind-replay clientside prediction is generally doable even without any clientside determinism due to the very short timescales. If you are seeing massive divergence on the client over ~100 milliseconds in a simulation that isn't super chaotic after copying motion states, there may be other problem...
by Norbo
Tue Jul 07, 2020 6:34 pm
Forum: General
Topic: about save the snapshot of the space
Replies: 3
Views: 8751

Re: about save the snapshot of the space

Collecting the motion state (position, orientation, linear velocity, angular velocity) gets you 95% of the way there. It's true that it's not a full snapshot, though- the activity state of bodies, the constraints that exist, the accumulated impulses cached for those constraints, and so on all matter...
by Norbo
Tue Jul 07, 2020 5:49 pm
Forum: Questions and Help
Topic: [Nuget] Include Bepu1 and Bepu2 in one Project
Replies: 6
Views: 13005

Re: [Nuget] Include Bepu1 and Bepu2 in one Project

Unfortunately that's an oversight. I didn't really think about using both in one project, so unless there's some automagic nuget stuff for handling collisions in dependencies that I'm unaware of, one easy option is to pull down one or both as source and add a project reference, and then modify the o...
by Norbo
Sun Jul 05, 2020 1:36 am
Forum: Questions and Help
Topic: [v2] Friction blending with static objects
Replies: 7
Views: 11945

Re: [v2] Friction blending with static objects

FYI, updated nugets: https://www.nuget.org/packages/BEPUphysics/2.3.0-beta0

It's automated now, so they'll be quite a bit more frequent. There's supposed to be a package uploaded to the github registry too, though that's... currently failing for inscrutable reasons.
by Norbo
Thu Jul 02, 2020 6:25 pm
Forum: Questions and Help
Topic: [v2] Friction blending with static objects
Replies: 7
Views: 11945

Re: [v2] Friction blending with static objects

If it's convenient and speedy enough, it'll be fine. As always, being 'speedy enough' depends on the data access patterns. If you need to jump through those indirections a million times a frame, it might require some more attention, but otherwise, might as well do the simple thing.
by Norbo
Wed Jul 01, 2020 9:14 pm
Forum: Questions and Help
Topic: [v2] Friction blending with static objects
Replies: 7
Views: 11945

Re: [v2] Friction blending with static objects

Historically, infrequently to the point of inconvenience. I keep intending to set up automatic prerelease publishing. I might just do that today while I wait on my ML training runs to fail :P
by Norbo
Wed Jul 01, 2020 8:56 pm
Forum: Questions and Help
Topic: [v2] Friction blending with static objects
Replies: 7
Views: 11945

Re: [v2] Friction blending with static objects

Good catch. There's a (bad) reason: laziness! The BodyProperty was a piece of demos-focused code that was intended more as an example than anything else, since it doesn't do anything special. At some point I moved it into the engine and didn't generalize it (or even update some of the comments, appa...
by Norbo
Fri Jun 05, 2020 8:57 pm
Forum: Questions and Help
Topic: Custom prediction of collision resolution
Replies: 1
Views: 7797

Re: Custom prediction of collision resolution

Unless there's a reason not to (like performance budget), I'd recommend just going with running the simulation forward. There's no built in 'rewind' functionality, but you could cache the original position/orientation/velocities and reset them afterwards. Or create a separate simulation, create equi...
by Norbo
Thu May 28, 2020 9:53 pm
Forum: Questions and Help
Topic: Custom collision response solving [v1]
Replies: 2
Views: 8687

Re: Custom collision response solving [v1]

I would recommend against modifying velocities in the CreatingContact event handler. While you're presumably only using one thread to guarantee determinism in v1 so it shouldn't cause a race condition now, it may help avoid future confusion or bugs if it's in a safer location. Consider enumerating c...
by Norbo
Sun May 24, 2020 10:26 pm
Forum: Questions and Help
Topic: [v1]Accelerating StaticMesh creation
Replies: 2
Views: 8446

Re: [v1]Accelerating StaticMesh creation

The easiest thing to do would be to keep a reference to the whole StaticMesh for later use. You can remove it from the Space and re-add it later. There's also the InstancedMesh, which is very similar to the StaticMesh but doesn't bake the world transform into the underlying tree so the shape it uses...