Temechon Posted July 23, 2014 Share Posted July 23, 2014 Hey guys ! I really wanted to try to use Oimo.js with Babylon, so I made a quick test here : http://pixelcodr.com/oimo/index.html (Maybe for a new tutorial, who knows ? )The thing is: it works reaaally well ! In my scene, I create 1000 spheres, and no problem at all. You can compare with cannon.js here : http://pixelcodr.com/oimo/index_cannon.htmlWith cannonjs, i can see a lot of sphere are going through the ground, and the fps is not very high. I may work on the plugin creation if you are interested. Cheers ! celian-garcia, Dad72 and Xanmia 3 Quote Link to comment Share on other sites More sharing options...
Dad72 Posted July 23, 2014 Share Posted July 23, 2014 Me that interest me greatly. Thanks Temechon. This is a super new and I wish you good luck with the plugin.It seems much better with Oimo. the comparisons is huge visually and in performance. Quote Link to comment Share on other sites More sharing options...
jiweigang1 Posted July 23, 2014 Share Posted July 23, 2014 its really good Quote Link to comment Share on other sites More sharing options...
reddozen Posted July 23, 2014 Share Posted July 23, 2014 Please do! Quote Link to comment Share on other sites More sharing options...
Temechon Posted July 23, 2014 Author Share Posted July 23, 2014 Oimojs is not very developer-friendly... No documentation, only 3 or 4 examples...I'm reading the source code of Oimojs, and there is no way to create a pixel perfect impostor, only a composition of box, cylinder and spheres are possible. Is is ok for you guys ? EDIT : In CannonJs, no pixel perfect mesh impostor, but at least the system creates a ConvexPolyhedron automatically for your custom mesh. It will certainly be a limitation for Oimojs. Quote Link to comment Share on other sites More sharing options...
Dad72 Posted July 23, 2014 Share Posted July 23, 2014 I found good Ammo.js https://github.com/kripken/ammo.js What would be good is for the hilly terrain. having imposters capsule, cylinder, box, sphere, and mesh would be ideal. What is missing more than it is for the hilly terrain. Quote Link to comment Share on other sites More sharing options...
GameMonetize Posted July 23, 2014 Share Posted July 23, 2014 I love you Temechon:) Please create the oimo plugin. No problem if only basic shapes are supported your demo rocks! Temechon 1 Quote Link to comment Share on other sites More sharing options...
Temechon Posted July 23, 2014 Author Share Posted July 23, 2014 Thanks :) I already started the plugin in javascript. I'll update this post with my progress, or If I have any problems. Cheers ! Quote Link to comment Share on other sites More sharing options...
reddozen Posted July 23, 2014 Share Posted July 23, 2014 That's too bad that it wont do complex shapes. I'm just going to have to make a grid for my game of acceptable Y locations by X,Z coordinates. Should be faster as a lookup than a physics calculation anyway. Quote Link to comment Share on other sites More sharing options...
Dad72 Posted July 23, 2014 Share Posted July 23, 2014 Ammo.js could manage more complex shapes. Quote Link to comment Share on other sites More sharing options...
reddozen Posted July 23, 2014 Share Posted July 23, 2014 Any way to link different functions / parts with different physics engines as needed? Quote Link to comment Share on other sites More sharing options...
Dad72 Posted July 23, 2014 Share Posted July 23, 2014 This is an issue which had been ask and who was not positive for a matter of performance. You can also use only a single plugin at the same time. Quote Link to comment Share on other sites More sharing options...
Temechon Posted July 23, 2014 Author Share Posted July 23, 2014 Only one plugin can run at a time in a scene.But you can create your own plugin linked to several physics engine I guess it will be very CPU intensive Quote Link to comment Share on other sites More sharing options...
reddozen Posted July 23, 2014 Share Posted July 23, 2014 Only one plugin can run at a time in a scene.But you can create your own plugin linked to several physics engine I guess it will be very CPU intensive That wouldn't be worth it... If it came to that you may be better off only pulling out the parts of each engine you need into your own little micro engine that only had the functions you use. I'll probably just end up using as little physics as possible or none at all. I may just end up calculating the couple small things in need server side and forcing results into the client... Quote Link to comment Share on other sites More sharing options...
Temechon Posted July 23, 2014 Author Share Posted July 23, 2014 End of the coding night : the plugin is coming out slowly Right now : position, rotation, box, sphere, planes are working : http://www.pixelcodr.com/oimo2/ Cheers ! Dad72 1 Quote Link to comment Share on other sites More sharing options...
Dad72 Posted July 24, 2014 Share Posted July 24, 2014 Excellent Temechon 1 Quote Link to comment Share on other sites More sharing options...
Kilombo Posted July 24, 2014 Share Posted July 24, 2014 Really great stuff mate, good work. We are really missing one alternative to cannon.js Temechon 1 Quote Link to comment Share on other sites More sharing options...
jiweigang1 Posted July 24, 2014 Share Posted July 24, 2014 great work :D Temechon 1 Quote Link to comment Share on other sites More sharing options...
Temechon Posted July 25, 2014 Author Share Posted July 25, 2014 The plugin is nearly finished. You can try it here. Be careful, there are A LOT of cubes ! You've been warned Here for a more useful version. Cheers ! Dad72 1 Quote Link to comment Share on other sites More sharing options...
Dad72 Posted July 25, 2014 Share Posted July 25, 2014 Wow too cool. At mee the two scene works very well, without lag. I hope this plugin will become the default Babylon, cannon.js has some small problems... Quote Link to comment Share on other sites More sharing options...
reddozen Posted July 25, 2014 Share Posted July 25, 2014 Any chance of doing ammo next since it can handle complex objects? lol Quote Link to comment Share on other sites More sharing options...
jiweigang1 Posted July 26, 2014 Share Posted July 26, 2014 does it work well with 3dmax? nice work Quote Link to comment Share on other sites More sharing options...
Temechon Posted July 26, 2014 Author Share Posted July 26, 2014 I won't work at all on the 3DS plugin, but as it is a physicpolugin, all methods used by babylon will stay with the same name, so I guess it will work. Only the underlying logic will be linked to Oimo.js. @reddozen : I tried the ammo benchmark, and I run at 15 fps with 750 boxes... Not so great Quote Link to comment Share on other sites More sharing options...
Dad72 Posted July 26, 2014 Share Posted July 26, 2014 Ah yes indeed, with 500 boxes, I am a 42 fps and with 1000, I am a 25 fps. Oimo is one that has better performance. But it is true that it is a pity for complex objects. but this physics engine is further developed, compared to cannon.js which is abandoned. May be that Oimo.js will evolve in this direction and we could also evolve the plugin here with Oimo.js developments. I think that is your idea Temechon, if Oimo evolves, you would continue the plugin with new imposters. Quote Link to comment Share on other sites More sharing options...
reddozen Posted July 26, 2014 Share Posted July 26, 2014 Good to know at least. With that, Ammo isn't an option. 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.