Jump to content

zmahomedy

Members
  • Content Count

    11
  • Joined

  • Last visited

  1. Hi guys I been working on a small project where I am rotation the mesh along its y axis. I am using the following to "animate" the mesh. scene.registerBeforeRender(function () { physicalbase.rotation.y += 0.01; }); Now I like to add in GUI functionality that can stop, speed or change the direction. In the code below I am trying to stop the rotation but it doesnt work. I even tried changing the direction but that too doesnt work. I will some advice help in this regards to better understand animation in BabylonJs properly and then learn how to intera
  2. WIngnut thanks for the help solved alot of my problems
  3. Hi Guys, I am working with a custom model and I am attaching child meshes to it. I am trying to rectify a problem that I am having when I add colour to the model. I lose the 3d shape, the child meshes look flat and you cant differentiate between them When I remove the colour in the material, in greyscale it looks fine. see attached pictures for comparison. Also Multi Material doesnt seem to be working as expected. The next issue I am having is the orientation of the "base modal". When I init the script its rendering the base in an angle vs being upright, as
  4. Hi JohnK here is the babylon playground link http://www.babylonjs-playground.com/#2AXMQX as you can see there are alot of meshes floating outside the base mesh. Im using verticesdata to get each point so theoretically all new meshes should be all within the base mesh. another slight hicup as I continue to work on this project To get the orientation correct, I transformed the base mesh using rotation tet1.rotation.z = -0.4;tet1.rotation.y = 2.5;tet1.rotation.x = 2.6;tet1.bakeCurrentTransformIntoVertices();now when I want to add in some animation using scene.beforeRender its taking the a
  5. thanks for clarifying the issue on the number of vertices. can anyone shed any light on why getVerticesData is giving me points off the model in space? Should it not all be on the model? I am very new to this. Zak
  6. JohnK I have 72 positions not 24 from the model import. Even if there was some duplication, where isnt my meshes not aligning with the base mesh vertices points ,when using data from its vertex data function
  7. Hi I am trying to do the following, Take a model in wireframe and add new meshes to its vertices. I created a simple model of 2 tetrahedrons and imported it into babylon using the raw data from the export file, using setVerticesData. It renders correctly however the next part to my project is to add meshes to each vertex point ( suppose to be 8 ), I instead get 24 points into my array when I use the function getVerticesData(BABYLON.VertexBuffer.PositionKind);In clara.io I see 8 vertices. So I am not sure why I am getting so many vertex points. The reason why I am importing the raw data i
  8. Hi ya ok so i figured why I was getting errors and the default export file not working in the sandbox. On the export I was using download manger to download the file. For some reason it was corrupting it. A regular save as did the trick zak
  9. Hi I am trying to figure out my why my import babylon scene file is always not found. I included it in the same location as my html files I am not running it off a web server, its running of my browser. var canvas = document.getElementById("3dCanvas"); var engine = new BABYLON.Engine(canvas, true); var scene; BABYLON.SceneLoader.Load("", "t.babylon", engine, function (newScene){ scene = newScene; var c = scene.getMeshByName("tetrahedron"); //Do what you want });XMLHttpRequest cannot load file:///C:/Users/zmm/lifeprint/new/t.babylon.manifest?1448032895642. Cross origin requests are o
  10. Hi I am new to Babylon and 3d modelling in general. I manage to get the basics down. I am trying to export a basic model into babylon however it never seems to initialize. I tried the same import file in the babylon sandbox and get the same black scene with the loading circle. My scene in clara.io is pretty simple, its an upside down tetrahedron. https://clara.io/view/2ee8381f-23f5-4eeb-b682-01e6f68f037d I also tried exporting it to blend and I get some error. Any ideas on what I could be doing wrong? thanks zak
×
×
  • Create New...