rgalindox

Members
  • Content Count

    25
  • Joined

  • Last visited

About rgalindox

  • Rank
    Member

Recent Profile Visitors

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

  1. Hi, I figured out : now I need to see the collision function myRay(){ var door = scene.getMeshByName("mesh1"); var punti= scene.getMeshByName("mesh2"); var origin = door.position; var forward = punti.position; var direction = forward.subtract(origin); direction = BABYLON.Vector3.Normalize(direction); var length = 20; var ray = new BABYLON.Ray(origin, direction, length); let rayHelper = new BABYLON.RayHelper(ray); rayHelper.show(scene); }
  2. Hi, I'm trying to create a ray from one mesh to another one, but I have problems with the direction. I'm using this one: var ray = new BABYLON.Ray(); var rayHelper = new BABYLON.RayHelper(ray); var localMeshDirection = new BABYLON.Vector3(-1, 0,0); var localMeshOrigin = new BABYLON.Vector3(0, 0, 0); var length = 20; var door = scene.getMeshByName("shop08"); rayHelper.attachToMesh(door, localMeshDirection, localMeshOrigin, length); rayHelper.show(scene); In the above case I have a ray on the -x axis, but I need to use the direction of a specific mesh, basically when the user click on any mesh the ray will check for collisions in between. How can I get the direction of a specific mesh and include it on the rayHelper.attachToMesh ? Thanks for your valuable help. Rafael
  3. Thank you very much. I'll check the links you kindly sent me. I appreciate your support to this forum! Rafael
  4. Hi, We are creating some 3d apps for web and web mobile so Unity3D can't do the job for mobile web. We need to have 3d text on top of some 3d objects, the text needs to be created dynamically so we can't import it from Blender or another 3d authoring tool. What library do you recommend to add to Babylon to have 3d text? I tested the 3d GUI but you need to have buttons and the requirements is 3d text similar to what UNity3D offers. Any help will be appreciate it.
  5. By the way, I know this is another topic. How do you add 3d Text in Babylon? not as a GUI but as a mesh. Thanks
  6. Sebavan, you're a genious!!! you saved me 😀 It works a charm! Thanks for the prompt reply. I appreciate it a lot! Rafael
  7. Hi, Hope I'm clear with my explanation: I have a Babylon scene and when it is alone (no other div on the html that has the canvas) the OnPointerOverTrigger works perfectly. However, when I put the canvas inside a <div> the OnPointerOverTrigger seems shifted, I mean, when I hover over the mouse over the mesh the action starts outside the mesh. I need the scene to be inside a div as I'm using w2ui as the GUI interface of the application. Attached one example: camera.html and cameraGood.html camera.html is the one with the issue, it only adds these lines: <div> <h2>Title</h2> </div> <div> <canvas id="renderCanvas" touch-action="none"></canvas> </div> cameraGood.html has no divs <canvas id="renderCanvas" touch-action="none"></canvas> I create a sphere every time you click on the surface. Without the div it works great, but when I add a div for a title and another for the canvas it fails, it picks another position. It seems the mouse coordinates are being used for the complete web browser and not the canvas. Any recommendation? camera.html cameraGood.html
  8. I'm playing around ribbons and they are awesome, as I can to my lines in parallel and then apply the ribbon, looks great! Do you know if the resulting ribbon is a mesh that can be clicked on? I'll test this shortly but wondering if you already tested this. Thanks
  9. Let me check the Ribbons and play with the billboard mode. Thanks
  10. Thanks Kesshi, I'm wondering how Unity implemented this when exporting to WebGL as it looks exactly as exporting to other platforms.
  11. Hello guys, I'm investigating BabylonJS for our next project at the company, we have our current application built in Unity and exported to WebGL, it is working pretty well however BabylonJS seems a great alternative in terms of portability to other platforms specially mobiles. We relay a lot on line renderers into the application as we crate many items on the fly, but I see the line function in BabylonJS doesn't support width. Someone has a workaround to have lines wider on scenes? I've tried tubes but they don't look very well compared to a line drawn on the fly as I have a function that smoothes the lines using interpolation. Thanks in advance
  12. Hi, in which part of the code should I add the camera limits for the zoom? or when it is triggered? Thanks
  13. Thank you very much! I appreciate your help.