Jump to content

Search the Community

Showing results for tags 'mergemeshes'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


  • HTML5 Game Coding
    • News
    • Game Showcase
    • Facebook Instant Games
    • Web Gaming Standards
    • Coding and Game Design
    • Paid Promotion (Buy Banner)
  • Frameworks
    • Pixi.js
    • Phaser 3
    • Phaser 2
    • Babylon.js
    • Panda 2
    • melonJS
    • Haxe JS
    • Kiwi.js
  • General
    • General Talk
    • GameMonetize
  • Business
    • Collaborations (un-paid)
    • Jobs (Hiring and Freelance)
    • Services Offered
    • Marketplace (Sell Apps, Websites, Games)

Find results in...

Find results that contain...

Date Created

  • Start


Last Updated

  • Start


Filter by number of...


  • Start



Website URL





Found 5 results

  1. Firstly, Congrats for completing 3.2 . We were looking forward to quite of a lot of features implemented here. This isn't a bug, but in my opinion I think the merge meshes should continue merging the rest of the meshes in the list when it encounters an invalid mesh instead of throwing an error. We have a model load workflow which on load finds the center and extent of the model using mergeMeshes. Few of our models have empty container like meshes that are parent of meshes that have real vertex data. And this breaks our App when vertexData.validate() throws "Positions are required". There is an easy fix for this - I made a pass before mergingMeshes like so: for (var i = 0; i < meshes.length; i++) { //only pass meshes that have valid position data if (meshes[i].getVerticesData(BABYLON.VertexBuffer.PositionKind)) clones.push(meshes[i].clone("clone" + i)); } var combinedMesh = BABYLON.Mesh.MergeMeshes(clones); This is potentially a breaking change as it works right with 3.1
  2. After merging 2 meshes trying to call applyImpulse results in a null exception something like this: Uncaught TypeError: Cannot read property 'applyImpulse' of undefined at CannonJSPlugin.applyImpulse (es6.js:81725) at PhysicsImpostor.applyImpulse (es6.js:80780) Same happens with Oimo. Replicated here: http://playground.babylonjs.com/#UGLFTI#1
  3. Hi, We have been using babylon2.5 (oddly, an alpha release) in our projects because it served our purposes. Now we want to update to 3.0.7 for various reasons. We have lots of meshes that are imported into an existing scene that have to be logically combined under a parent based on a predefined config. I used this following code to arrive at combination's size and center. var getCombinationData = function(meshes) { var clones = []; for (var i = 0; i < meshes.length; i++) { clones.push(meshes[i].clone("clone" + i)); } var combinedMesh = BABYLON.Mesh.MergeMeshes(clones); var boundingBox = combinedMesh.getBoundingInfo().boundingBox; var size = boundingBox.extendSize.scaleInPlace(2); var center = boundingBox.center; //dispose off the clones; for (var k = clones.length; k > 0; k--) { clones[k - 1].dispose(); } combinedMesh.dispose(); return { size: size, center: center }; }; Using babylonjs 3.0.7, the boundingBox.center is different from that obtained using 2.5, which I am assuming is right , because a box made with size and center got from the above method, neatly encapsulated the meshes. Has anything changed since 2.5 or An easy fix to doing this? The meshes can have parents ( but not different ones). Thanks.
  4. Hello dear Babylon lovers! I'll try to be clear : For the Babylon monthly challenge, I create a random maze, with many meshes. Then, I merge all the meshes for performance reason. It looks something like this http://www.babylonjs-playground.com/#QDDWX (better than this ) My question is : It merges the meshes, it's ok, but what about the inside faces ? Is it possible to remove it (the faces you can see inside the boxes) ?
  5. Hey guys, I have a little problem and I don't know what to do to make it work. Maybe it's not possible, but that would suck since my whole idea for the monthly challenge is based on that So you see, it's kinda important First things first, the playground: http://www.babylonjs-playground.com/#4UXRQ What I want to do: I have a mesh that I created by merging several other meshes with the help of mesh.MergeMeshes (the middle layer in the playground). Now I want to cut this shape out of another mesh (lowest layer in the playground). The result I get is the top layer in the playground, but it's not what I expected it to be like. I assumed I would get a clear path cut out of the lowest layer mesh. I think the problem is the merging of the meshes. If I turn on the debug layer, with clickable labels and select the merged mesh I can see that it looks like there are still multiple meshes overlapping each other. So what am I doing wrong? Am I using the merge wrong? Is there a better way of merging the meshes so that I can get my expected result? I tired to skip the merging and carve each single block out of my lowest layer, but that seemed to have very poor performance (my browser crashed). I hope you guys can help me with that!
  • Create New...