• Content Count

  • Joined

  • Last visited

Everything posted by Gijs

  1. I'm switching to BABYLON.GUI as well, and I've made a context menu: It's in its early stages, but it's good enough for my project ATM. In my project, the menu it is tied to a custom event system and color scheme, so in this demo the colors are hard-coded, and the clicked button only prints to the console. I'm also interested in what's out there! Edit: The TypeScript source:
  2. Extruding the bottom: It's a bit hacky
  3. From the Three.js demo: I took the vertex shader from the source: Put it in CYOS, downloaded it, then put it in this playground: I don't know how to do this properly, but it's something.
  4. I've never done that, but can you maybe see anything of interest in F12 > Console or F12 > Network?
  5. @SpaceToast If you hover over the setVerticesData function in the playground, you will see that the data can be either a number array or a Float32 array
  6. @bulisor You have "BABYLON.DOUBLESIDE", which should be "BABYLON.Mesh.DOUBLESIDE"
  7. Better late than never: turns out the problem here is that the skull doesn't have its UVs set:
  8. You have var scene = createScene; //Call the createScene function Which should be var scene = createScene(); //Call the createScene function I got it to work that way
  9. Hi all, I updated to the latest preview version of BJS, and now the camera panning behaves differently: What I want: Current behavior: What has changed? Thanks
  10. @Sebavan Ok, thanks for your help. It's the preview version, so things like that are to be expected of course.
  11. Hi, I've replaced a previous 3.1-alpha with the latest preview, and now when I use a registerBeforeRender to set the alpha and beta rotation values, it allows you to rotate the camera before the render, and after the rotation is reset. Now: Then (August 17): Is it a bug? Thanks.
  12. Never mind, I found the solution after all: canvas.addEventListener('mousedown', function(event){; }); Thanks for your input @jerome The events are only still received when you keep holding down the mouse button as you move outside the canvas Edit: apparently it's not a cross-browser thing, so you can't use the snippet above like that
  13. Hi, On Firefox the camera stops rotating when your pointer leaves the canvas: Which doesn't happen on Edge, IE, Chrome or Opera
  14. Have you tried different settings on your webcam? I see no problems with the camera that's built into my laptop.
  15. Did you make it with TypeScript? Because when I upgraded, the code checker showed me which parts I had to rewrite. I also had some hacks in place that worked for 2.5 only, so that's also something you could check. Finally, the 3.0 version is being updated all the time, so you could check if an earlier version does work: release/babylon.js
  16. Hi, For #1 I got it working by replacing the loops with direct calculations of the positions: Maybe those loops also caused #3 by never ending, though that wouldn't make the memory usage high. Good luck with your project
  17. Extrusions are the best! They're simple but powerful. I agree with what said in this thread about Blender, and I'm actually making a 3D modelling application that uses extrusions.
  18. I seems that the bounding box is only calculated for the parent mesh and its submeshes, so for the children you have to do it manually. But you can put the code away in a function you replace refreshBoundingInfo with:
  19. You could add the child bounding boxes together like this:
  20. I know of @davrous' "very ugly UI": It's at #6
  21. Hi, you can do this with BABYLON.WeirdSpriteManager: The manager has the function pickSpritePixel, which takes a child sprite as argument, and returns the pixel under the pointer. It does this by putting a plane mesh at the sprite position with the right rotation and scale, then pick that mesh to get the image (x, y) coordinates, and then get the pixel from the imageData like in your jsfiddle. It uses its own copy of the sprite image. Edit: Here is the typescript source: WeirdSpriteManager.ts Edit 2: With the mesh not pickable, and Math.round instead of Math.floor in the pickSpritePixel function: WeirdSpriteManager.ts
  22. @jerome @NasimiAsl Maybe a shader can be made that uses a pixel from either the front or back image depending on whether a vertex normal is facing the camera