Jump to content


  • Content Count

  • Joined

  • Last visited

About Seba

  • Rank

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Hello there, I trying to reduce the draw calls in my project and in my in investigation I noticed that a sprite manager is taking 2 draw calls even if we have no sprite in its sprite list. So just adding this line will cost you 2 draw calls : var spriteManager = new BABYLON.SpriteManager("spm", "fakeurl", 1, 10, scene); Is it a bug or there is a reason for this behavior ? If no reason is possible to fix it in the next Babylon version ? Cheers.
  2. Hello I get some black parts on custom shapes created with BABYLON.MeshBuilder.ExtrudeShape Here is my code (this.points is an array of Vector2): if (!this._shapeInScene) { let points: Array<BABYLON.Vector3>; let path: Array<BABYLON.Vector3>; let color: BABYLON.Color4; // points = new Array<BABYLON.Vector3>(); for (let p of this.points) { points.push(new BABYLON.Vector3(p.x, p.y, this.plan.planCenter.y)); } points.push(po
  3. Ok got it! Thanks a lot for this clear explanation.
  4. And for more informations if I do same on the others axis. So if I rotate 91 degrees or whatever on axis Y and Z. I do get back the good results from quaternion.toEulerAngles()
  5. Hey JohnK thank for your answer. Yes I did read this article but I still don't understand why when you rotate above 90 degrees on axe X all axis are changed. I did a mistake in code when converting radian to degrees which fix problem 1. So for my second problem if I apply a rotation of 91 degrees like below : mesh.rotationQuaternion = BABYLON.Quaternion.RotationYawPitchRoll( 0, (91 * Math.PI) / 180, // 91 degrees convert to rad 0 ); var euler = quaternion.toEulerAngles(); I get thi following results: euler.x = 89 degrees, but should be 91 e
  6. Hello Babylon community, I have troubles to understand how to switch from quaternion to euler angles and vice versa. First problem: When I apply a rotation to a cube on axe X which should be a 90 degrees (when the face facing us get on the top) I get a value above 130 degrees from my convertion (quaternion to euler). Second problem: When I go over 140 degree on axe X, axes Y and Z are changed! However I'm just playing with X axe. Am I missing something? Here a playground: https://playground.babylonjs.com/#7QNRN2#1 Press the key 'a' to rotate on the axe
  7. Hello Jerome. Thanks for your reply. Ok I was really hoping to keep my sprites system, but I'll try either your solution or Deltakosh one.
  8. Hi Deltakosh, Thanks for your reply. Do you mean something like using a mesh instead of a sprite like a plane, then set my texture to this plane and set plane.billboardMode to BILLBOARDMODE_ALL? I have a lot of sprites. My project is a Map in 3D of a building let's say a shopping center and each shop is represented by a mesh in 3D and floating above a sprite which is the shop's logo. I'm affraid that using meshes instead of sprites will drop down the rendering.
  9. Ok I found how to fix it by using renderingGroupId parameter from the meshes and the sprite manager. set 0 to meshes and 1 to sprite manager. But it's not perfect, if we set the camera position under the plane (grass) we have the sprite drawn before the plane.
  10. Hello guys, I have troubles with showing shapes that have an opacity < 1 and which are behind a sprite that also has an opacity < 1. I attach a screenshot and here the playground As you can see the shapes behind the sprite disappear I tried differents options with material's shape such as : forceDepthWrite needDepthPrePass separateCullingPass zOffset But nothing works, and on the Sprite side we don't have a lot of parameters to play with. I wonder if it's not due to a kind of optimization of babylon to not drop down the render.
  • Create New...