You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For the same input, and same binary, Box2D/Planck.js will reproduce any simulation.
People often want to know if Box2D/Planck.js can produce identical results on different binaries and on different platforms.
The answer is no. The reason for this answer has to do with how floating point math is implemented in many compilers and processors.
I remember seeing this same limitation listed in Box2D's docs, but I'm wondering if this was intentional or incidental copying? I would think that given this is a javascript implementation, there's not really a notion of a different "binary". Or is binary/platform in this case referring to the particular browser engine?
Ultimately what I'm trying to understand is if i I ship a networked application with an embedded version of chrome, and every app has this v8 version, is that considered the same binary, such that I can expect determinism?
The text was updated successfully, but these errors were encountered:
The library code is deterministic, however as you pointed the result depends on how floating point math is implemented where the library code runs. We need to updating the wording in the documentation and replace "binary" with "javascript runtime".
If two runtimes have the same floating point implementation I would expect the same result.
The docs state:
I remember seeing this same limitation listed in Box2D's docs, but I'm wondering if this was intentional or incidental copying? I would think that given this is a javascript implementation, there's not really a notion of a different "binary". Or is binary/platform in this case referring to the particular browser engine?
Ultimately what I'm trying to understand is if i I ship a networked application with an embedded version of chrome, and every app has this v8 version, is that considered the same binary, such that I can expect determinism?
The text was updated successfully, but these errors were encountered: