• Content Count

  • Joined

  • Last visited

  • Days Won


Everything posted by ozRocker

  1. Woh! I had no idea BabylonJS had that kind of functionality. Ok I got this. Prepare to see something awesome soon!
  2. Does anyone know if this would be possible? I know someone brought this up before but it was regarding SysEx messages from a MIDI track. I'm talking about playback from an MP3 or WAV file. I know its possible to detect beat in songs by analysing the bass frequencies. There's gotta be a way to implement that in a .babylon animation. Basically I'm trying to get dancing animations synced to the beat of music.
  3. I've been experimenting with a tool for shoppers so they can create their bodyshape in realtime and see which clothes fit them (whether that's a viable platform or not depends on the what the shoppers think) Here is the LIVE demo: https://punkoffice.com/bodyshape There was a bit of stuffing around to make this work. I had to separate the body-parts into polygroups. To do this I needed to add code to the Blender exporter so it would export vertex groups. Then I added code to the Babylon.js library to be able to parse the vertex groups from the exported JSON file. I've got a base model and an overweight model and I'm basically morphing polygroups from base to overweight. The girl was a housemate that I scanned but her bodyshape is a female from MakeHuman http://www.makehumancommunity.org/. The overweight morph target was also made in MakeHuman. I use Wrap from these guys https://www.russian3dscanner.com/ so I can change the topology of my scans to another topology (in this case, the MakeHuman avatar). This is all done via the CPU. Maybe a better coder than me can get it working on the GPU.
  4. I finally got off my lazy ass and implemented a solution. You can see the result here: preview.punkoffice.com/bodyparts I altered the mesh.py file of the Blender exporter to parse the vertex groups. If anyone wants to see the code changes I've attached my version of mesh.py. The bits I added have # _NEW_ before the code. I'm not great at Python so maybe it can be improved. @JCPalmer this might be of use to you if you want to incorporate vertex groups. So the extra JSON in the .babylon file looks like this: "vertexGroups":[{"name":"waist","id":"waist","indices":[4053,4054,4055,405, etc....]}] In the Babylon.js code in the Mesh.parse function I added this ( @Deltakosh if you want to incorporate vertex groups you can use this) // Vertex groups if (parsedMesh.vertexGroups) { mesh.vertexGroups = parsedMesh.vertexGroups; } I also had to add a new function to find the vertex group: BABYLON.Mesh.prototype.getVertexGroupByName = function(vgName) { for (var i=0; i<this.vertexGroups.length; i++) { if (this.vertexGroups[i].name == vgName) return this.vertexGroups[i]; } return null; } I'm not sure if this is the best way so feel free to ignore if its not efficient, but it works for my needs. mesh.py
  5. OMG I found the actual problem! I set visibility to my particle placeholder meshes to 0. RenderTarget won't pick up particles if the placeholder mesh isn't visible. Looks like I just need to find another way to hide the placeholder meshes
  6. Well it works here https://www.babylonjs-playground.com/#WBQ8EM#25 I'll try it in my local environment and if that works I'll tick this one off
  7. Does that mean particles will eventually show up when I use CreateScreenshotUsingRenderTarget? I tried with v4.0.0 alpha-7 but its not there yet.
  8. I've noticed that CreateScreenshot will capture particles but CreateScreenshotUsingRenderTarget doesn't. Does anyone know how to capture particles with the render target capturing method?
  9. Thank you @JCPalmer I got it working now
  10. ok, it looks like there is something different between the avatars that's causing the problem. I made a new playground using 2 different avatars and they are synced perfectly. https://playground.babylonjs.com/#BCU1XR#191 I don't have access to the original files so I'm trying to find a way to fix up the sync with Babylon.js code Edit: The animations are for skeletons with 62 bones (fingers and toes in there). Some of the avatars have a different number of bones because they might not have the same number of fingers/toes. If I use copyAnimationRange like that it will complain about different number of bones, so I wrote a function RemoveExtraBones that will remove the bones in the animator's skeleton that don't exist in the avatar's skeleton. In the 1st playground the bearded guy has 62 bones but the 2nd guy has 38 bones and the result is out-of-sync In the 2nd playground they both have 38 bones and the result is perfectly synced. Could number of bones have something to do with the speed? Edit edit: https://playground.babylonjs.com/#BCU1XR#192 Number of bones doesn't seem to make a difference. I made sure they both had 38 bones but it didn't help
  11. Did you mean the FPS of the animation files or the FPS of the avatar files? In this example I'm using just the one animation file and copying that to the avatar skeletons so those animations should have the same FPS
  12. Here we go: https://playground.babylonjs.com/#BCU1XR#190 2 guys with the same animation applied. One guy breakdances faster than the other guy. How can I make them dance the same speed?
  13. Not sure if I'm doing something wrong, but I can't get this working with skeleton animatables. It only accepts animation objects.
  14. You are correct, which is why I mentioned all the platforms I used to create a registration form. However, the framework that I built is for commercial purposes.
  15. Sure no prob! The code hasn't been made public but I'm happy to sell it off to whoever wants it. Just shoot me a msg or email marcusmilne@punkoffice.com
  16. You can just use standard web programming languages for that. HTML, Javascript, PHP, MySQL, etc... Like this one I made before http://threedium.com
  17. I've noticed animations run on different speeds depending on the mesh they're applied to. Is there a way to make animation always end at the same time?
  18. That exporter is a missing link also. So I'm guessing BabylonJS no longer parses Collada files in runtime and we're expected to convert it to another format instead?
  19. This link doesn't exist. I can't find anywhere how to import Collada files anymore. Is there a new link?
  20. Does anyone know if the Blender exporter will also export the particle system?
  21. Well, that was the greatest answer I could ever hope for. Its fixed! Thanks heaps @Sebavan
  22. I've got an animated character that flies around and the camera target is following the root bone. For some reason on mobile devices (both iPhone and Android) and only in portrait, the character disappears briefly when viewed front-on. It doesn't happen from the side though. You can test this by using the device simulator in Developer Tools with Chrome. Its the same on an actual mobile device as well. The website is here http://punkoffice.com/aadev Has anyone ever encountered this problem? Is there a way to prevent the clipping?
  23. Do you know if this is possible with Morph Manager? To be able to morph different areas with different influence amounts?
  24. I went to make a playground and it worked. I checked Babylon version and its using 3.3.0 beta. I was using 3.3.0 alpha. I downloaded the beta version and CPU bones now works. It works so well I can't even tell difference in frame drop. Thanks for your help @Sebavan