MackeyK24 Posted August 24, 2017 Share Posted August 24, 2017 Just checking if anybody .. Maybe @Sebavan or @Deltakosh or @davrous have ANY info on the new physics engine... Engery.js I think it was called. A C++ ported physics engine Quote Link to comment Share on other sites More sharing options...
GameMonetize Posted August 24, 2017 Share Posted August 24, 2017 No news on my side Quote Link to comment Share on other sites More sharing options...
Sebavan Posted August 24, 2017 Share Posted August 24, 2017 Not for me either Quote Link to comment Share on other sites More sharing options...
adam Posted August 24, 2017 Share Posted August 24, 2017 It should be released next month: http://www.visualiser.fr/page.php?id=Energy.js This appears to be @Samuel Girardin 's project. Raggar 1 Quote Link to comment Share on other sites More sharing options...
MackeyK24 Posted September 15, 2017 Author Share Posted September 15, 2017 On 8/24/2017 at 6:58 AM, adam said: It should be released next month: http://www.visualiser.fr/page.php?id=Energy.js This appears to be @Samuel Girardin 's project. Yo @adam or @Samuel Girardin ... Any news on Energy.JS for Babylon Quote Link to comment Share on other sites More sharing options...
RaananW Posted September 15, 2017 Share Posted September 15, 2017 I just wanted to add that a plugin for the engine was developed for an alpha version. If everything goes well, 3.1 will probably have a working plugin for Energy.js. Raggar and Pryme8 2 Quote Link to comment Share on other sites More sharing options...
Samuel Girardin Posted October 2, 2017 Share Posted October 2, 2017 Hi, Few news about energyJS, It's still in dev. Here is a quick very alpha preview with examples. This is not a bjs plugin version. @RaananW worked one year ago on the plugin. We need to talk about that, For the moment it reproduces more the c inteface of ODE c++ project(http:// www.ode.org). It's quite usefull, ODE documentation is really good, and I kept all the method name. Energyjs is port of Open dynamic engine to JS with EMSscripten (http://kripken.github.io/emscripten-site/) . Tuto1_friction Tuto2_friction2 Tuto3_bounce Tuto4_rolling_friction Tuto5_rolling_friction2 Tuto6_contact_cfm_erp Tuto7_contact_cfm_erp2 Tuto8_motion Tuto1_auto_disable_body WoodMachine BallJoint Trimeshes Vehicle (maybe you need to refresh the html page - loading is async and I forgot to fix that,, same for v+trailers) Vehicle+trailers (arrow key to control the vehicle, d to flip the vehicle) It's only cpu dependent, maybe a little more faster than oimo and canon. Really well documented on ODE's part. You may have a TOTAL_MEMORY bug, search '167108864' in js/energy.js and increased this value. This is just a start. I will publish this week the the typescript dev commented on github . GameMonetize, RaananW, brianzinn and 8 others 11 Quote Link to comment Share on other sites More sharing options...
GameMonetize Posted October 6, 2017 Share Posted October 6, 2017 Huge!!!!!! We should work on a doc page to reference all your great samples! Quote Link to comment Share on other sites More sharing options...
Samuel Girardin Posted October 8, 2017 Share Posted October 8, 2017 (edited) @Deltakosh , I'm going to work on a doc page this week. Another thing, I ported energy.js to webAssembly, it works pretty well : file size is half than the asm.js version, performances are 5-10% better in FF or Chrome. Edge (40.15063.0.0) is far behind, (still alpha support of webAssembly ?). Edit : about Edge, I test the new release in Preview build 16299 , performances are equivalent to ff and chrome. Asm.js version runs almost equally in the 3 browsers. Here is 2 perf tests, asm.js and webassembly. Launch the page clic on the scene and press S, You have to wait all red boxes become gray. Its about 21000ms on my i3 for asm.js and 19000ms for webAssembly. asm.js test webAssembly test Can someone test those demos and confirm webassembly is faster than asm in this particular test ? sam Edited October 11, 2017 by Samuel Girardin Dad72 1 Quote Link to comment Share on other sites More sharing options...
sable Posted October 9, 2017 Share Posted October 9, 2017 On an i7 3770k: Chrome 61: 8783ms for asm 8326ms for wasm FF 57 (dev edition): 7769ms for asm 7611ms for wasm The frame time (top right corner) sits at 12-13ms for wasm, but 16-17ms for asm after the test is finished. Samuel Girardin 1 Quote Link to comment Share on other sites More sharing options...
jerome Posted October 9, 2017 Share Posted October 9, 2017 I confirm wasm is also always a bit faster than asm in Chrome and FF on my Linux laptop. Samuel Girardin 1 Quote Link to comment Share on other sites More sharing options...
Samuel Girardin Posted October 9, 2017 Share Posted October 9, 2017 Thanks guys. A blog post about wasm perf by Alon Zakai https://hacks.mozilla.org/2017/03/why-webassembly-is-faster-than-asm-js/ jerome 1 Quote Link to comment Share on other sites More sharing options...
jerome Posted October 9, 2017 Share Posted October 9, 2017 btw, about wasm, did anyone of you test yet this https://github.com/AssemblyScript/assemblyscript ? sounds promising ... Samuel Girardin 1 Quote Link to comment Share on other sites More sharing options...
Samuel Girardin Posted October 9, 2017 Share Posted October 9, 2017 I only use emscripten to produce asm or wasm. The workflow ia exactly the same. I just have to add a specific flag to the compiler to emit asm or wasm. For the moment webassembly was just a test case. About your link, could be useful for heavy math calculation, but Javascript vm are more and more optimized.. Webaasembly is really useful to port existing c++ library to browsers. @Jerome Quote Link to comment Share on other sites More sharing options...
RaananW Posted October 9, 2017 Share Posted October 9, 2017 what about browser-compatibility? can either support all WebGL-enabled browsers? Quote Link to comment Share on other sites More sharing options...
GameMonetize Posted October 9, 2017 Share Posted October 9, 2017 We need to provide a cros platform story but I feel that the asm.js should work everywhere Quote Link to comment Share on other sites More sharing options...
jerome Posted October 10, 2017 Share Posted October 10, 2017 actually wasm is more widely supported than asm : http://caniuse.com/#feat=asmjs http://caniuse.com/#feat=wasm As wasm is also standardized, I supposed it's the way to go now (although asm is easier to write by hand directly without any compilation) [EDIT] and that's the reason why I wish the AssemblyScript project could get reliable and mature soon. It would allow us to translate some parts of the existing TS code (maths, matrix computations, for instance) at almost no cost (just by checking we specify the right types) directly to WASM. [EDIT 2] just found this site showing some live gain (or not) about image processing with WASM vs JS : https://d2jta7o2zej4pf.cloudfront.net/ [EDIT 3] I just discovered that AssemblyScript (ASC) guys are already working on the next version of ASC, called NEXT : https://github.com/AssemblyScript/next They need to decouple ASC from the current TS compiler to be able to compile the ASC compiler itself directly in WASM instead of in TS. Complex, but makes sense. Quote Link to comment Share on other sites More sharing options...
jerome Posted October 10, 2017 Share Posted October 10, 2017 That said, ASM.js is still great, can be written by hand, is legal JS and brings immediate real gain. Example (open your console) : http://playground.babylonjs.com/#DH683D#2 This PG just sets a big array with a float value (no maths or complex things here). The "normal" time is the JS classical array assignement, the "asm" time is the same done by the asm loop function. mmmhh... having an idea to make an asm test with the SPS experiment, not sure this will work Quote Link to comment Share on other sites More sharing options...
Samuel Girardin Posted October 10, 2017 Share Posted October 10, 2017 On 07/10/2017 at 12:58 AM, Deltakosh said: Huge!!!!!! We should work on a doc page to reference all your great samples! @Deltakosh I ve started that : https://github.com/samuelgirardin/Documentation/blob/master/content/extensions/EnergyJS/EnergyJS.md I m not sure where you want to put it ? jerome 1 Quote Link to comment Share on other sites More sharing options...
GameMonetize Posted October 10, 2017 Share Posted October 10, 2017 Extensions is perfectly fine for now. You can add your own header if you want (at same level as Material library for isntance) Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.