Jump to content

Search the Community

Showing results for tags 'depth sort'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • 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

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Website URL


Twitter


Skype


Location


Interests

Found 1 result

  1. Hi ladies and Gentlemen, Here comes a new feature in the FacetData pack. As you may know, for performance reasons, the facets of a given mesh are always drawn in the same order. This comes to visual issues when the mesh is transparent and is no longer oriented in the right place from the camera : http://playground.babylonjs.com/#FWKUY0 This new feature solves the self transparency issue by sorting the mesh facets from some location (the camera position by default) just before drawing them. The mesh is required to be updatable. The depth sort is done on each call to updateFacetData(). It can be disabled at any time to save CPU cycles if the mesh and the camera don't move any more. Usage : // the mesh must be updatable var mesh = BABYLON.MeshBuilder.CreateTorusKnot("mesh", {updatable: true}, scene); mesh.material = mat; // transparent material mesh.mustDepthSortFacets = true; // enable the depth sort, can be disabled at any time scene.registerBeforeRender(function() { mesh.updateFacetData(); // sort the facets each frame }); Note that this feature uses more memory and more CPU than an usual standard mesh. Please wait for the code review and the PR to be merged and to be pushed in the PG. Demo : http://jerome.bousquie.fr/BJS/test/facetDepthSort.html
×
×
  • Create New...