trevordev

Members
  • Content Count

    229
  • Joined

  • Last visited

  • Days Won

    2

Everything posted by trevordev

  1. Created PR for the focus issue and prevent backspace navigation in firefore here: https://github.com/BabylonJS/Babylon.js/pull/5382
  2. Try http://playground.babylonjs.com/#349JX1#1, this creates a new one every time w is pressed, for perf you could create them up front and make them rendered only when a new one is "created" like Seb said. To get it to render every second you can just add up the deltatimes until it equals one or use a settimeout method.
  3. My guess is they are the same in data. Like if you print out the positions, they should be the same if the logic was done in the exact same order in the client vs the server's null engine. If you have a repro where numbers printed out by null vs non-null engine are different please do share.
  4. @ssaket are you saying this is an issue with babylon? If so, yes, please to do create a PR
  5. If you want just a simple direct path to camera you can try this http://playground.babylonjs.com/#349JX1 .
  6. Yes SSAO2 requires webgl2. From looking at the code the expensiveBlur and samples parameters used in this PG (http://playground.babylonjs.com/#7D2QDD#0) look like they would effect performance the most, try settings like this and a smaller radius ssao.expensiveBlur = false; ssao.samples = 4;
  7. If you are performing logic on the server side and passing only data such as position to the client you might run into errors because the way the pivot works, changing the pivot may not update the position. I would recommend using a parent object instead of the pivot, see first paragraph here https://doc.babylonjs.com/how_to/pivots and this PG: https://www.babylonjs-playground.com/#GH4N1R#1
  8. Take a look at https://doc.babylonjs.com/how_to/webvr_helper in the device position and rotation section. It references this playground https://www.babylonjs-playground.com/#VIGXA3#7 . Let me know if you run into any issues with that.
  9. See https://playground.babylonjs.com/#U0AE2U#5 . In your playground you attach controls to both cameras right away, if you only have the active camera attached, only it will be moved.
  10. I'm not sure this is built in but here's a playground that does this http://playground.babylonjs.com/#Z4ZGAY. I created a mesh and made the light a child of it, then created a pointer event such that when its clicked it changes the intensity.
  11. WebXR should make it into popular browsers early next year 🤞. but you can already use it via chrome canary and support in babylon is already in progress: https://github.com/BabylonJS/Babylon.js/issues/3899 .
  12. Maybe this playground can help. It uses a custom shader to create portals: https://www.babylonjs-playground.com/#EEOWP#7
  13. Please share your playground and i can take another look.
  14. Tracking the highlight issue here: https://github.com/BabylonJS/Babylon.js/issues/5324 and PR is out. Im still not understanding the vr camera moving issue you describe. Is there a playground for that one?
  15. @oschakravarthi You shouldn't need to load all assets prior to entering vr. You just need to make sure that your assets to overwrite the active camera. You can load an asset container at any time and it shouldn't modify the scene until you call addAllToScene. What feature would you like to add?
  16. If you just load that scene do you see the same issue? I just tried on a laptop with gyro and could not reproduce this issue. Potentially the scene is too large and causing a driver/memory issue on lower end devices?
  17. @oschakravarthi see https://doc.babylonjs.com/how_to/how_to_use_assetcontainer , KeepAssets can be used to maintain objects when removing objects from the scene. When adding objects to the scene, you can inspect the scene.activeCamera and scene.lights and remove the ones that are not in your keep assets object.
  18. If you create a playground with just the buttons and don't load anything else does the ray work as expected? My guess is that something else you are loading into the scene is blocking the ray,
  19. @oschakravarthi What device are you using? When on desktop with WMR acer hmd this looks to work. Do you see any error in the console?
  20. Could you share a playground of what you are describing and I can take a look. My quick guess might be that this may be related parenting throwing off y position values.
  21. @droggam You could try to use offsetX instead of pointerX, offsetX will be the pixel offset of the canvas you clicked on. You can then use scene.getEngine().getRenderingCanvas().width to get the width of the canvas. Subtract scene.getEngine().getRenderingCanvas().width/2 from the offset X and you have the distance in pixels from the center of the canvas. Multiply this by a ratio to convert pixel distance to meters (eg. 1/100) and set the x position to that. Maybe that is more what you are looking for?
  22. This should position it correctly: http://www.babylonjs-playground.com/#6V9NM1#3 All the docs for scaling/positioning the gui is here: https://doc.babylonjs.com/how_to/gui3d#controls
  23. It looks like your gui is not visible, I created a sphere and move its position to be in front of the head, give this a shot http://www.babylonjs-playground.com/#6V9NM1#1
  24. Can you share a playground of what you have right now? If I get it right, you are just missing a function to position something in front of the camera? This could work very similar to how the plane is positioned in this PG: https://www.babylonjs-playground.com/#Q1VRX3#12