aFalcon

Members
  • Content count

    385
  • Joined

  • Last visited

  • Days Won

    3

Everything posted by aFalcon

  1. Question about setEnabled(false). Is it better performance than visibility = 0 ? And wondering what is the difference? If 1 mesh is rotating 10 children, and 5 can be hidden - which is more performant: visibility or setEnabled(false); I'll test it.... Lots of reading. Thanks!
  2. aFalcon

    Performance Optimization tips.

    Ok, Put in TIMESTAMPS ... gotta go. Thanks to who'ever made dude. Here is adapted timestamp utility, to easily measure performance anywhere: //TIMER var timeStamp = 0; var currentTimeStamp = 0; var timeReport = function(testname){ console.log('TIMESTART: '+testname); if(!timeStamp){ timeStamp = new Date().getTime(); } return function (testname) { currentTimeStamp = new Date().getTime(); var timeDelta = currentTimeStamp - timeStamp; console.log('TIMESTOP: '+testname+' = '+timeDelta); timeStamp = null; } } //EXAMPLE-USAGE-. // var debugTimeStop = timeReport('START Time Test'); // debugTimeStop('END Time Test'); Statistics pending...
  3. aFalcon

    Performance Optimization tips.

    Statistics -->great idea<-- Thank you setEnabled(true) insight! TINY-UPDATES: - the code below worked well as first pass rough-in. RESULTS: performance improvement achieved! (ding). - Will try setEnabled... on parents - -> But had interesting PROBLEM: need parent setEnabled(true) AND children setEnabled(false)???<-- anyway... : ) - Hello LOD! too. - Probably date.now all three [hope] (BZ thx). reloadLevel = function(){ for(var i=0; i<edges.length; i++){ edges[i].visibility = 1; } for(var i=0; i<orbs.length; i++){ orbs[i].visibility = 1; } for(var i=0; i<boxes.length; i++){ boxes[i].visibility = 1; } for (var i=0; i<tiles.length; i++){ tiles[i].visibility = 1; } } unloadLevel = function(){ for(var i=0; i<edges.length; i++){ edges[i].visibility = 0; } for(var i=0; i<orbs.length; i++){ orbs[i].visibility = 0; } for(var i=0; i<boxes.length; i++){ boxes[i].visibility = 0; } for (var i=0; i<tiles.length; i++){ tiles[i].visibility = 0; } }
  4. let you_guys = 'heros'; Because of this, was able to figure out alpha opacity on a sine wave for a shader-fader. Not perfect, but pretty cool for a rookie. : ) Hope it helps someone. http://www.babylonjs-playground.com/#16UICJ#9
  5. Hello, BabylonJS is fantasic. Thank you mr @Deltakosh and mr @davrous. Research: Augmented Reality making rapid advancements this year. GIS AR, Multi-Marker AR, TableTop AR - 3D on flat surfaces... Happening fast. Babylon is my 3D home. So I must ask: Is AR porting a priority for upcoming versions of BabylonJS. And if not, can it be? I looked at wishlist and roadmap. Found milestone/5 with no mention of AR: https://github.com/BabylonJS/Babylon.js/milestone/5 Here is link with history I'd follow: https://uploadvr.com/ar-js-efficient-augmented-reality-for-the-web/ Seems to be lineage of successful AR examples: https://github.com/opencv/opencv_contrib/tree/master/modules/aruco https://github.com/artoolkit/jsartoolkit5 https://github.com/jeromeetienne/ar.js For AR -> Babylon is most promising to me. How would one go about such a feature? Thanks,
  6. "binary encoded packet"... excellent! And multi-player tip very helpful. Thank you.
  7. aFalcon

    What's next?

    Sounds ambient...
  8. Super cool, and.booking vacation. : ) Curious, about that websocket, babylon node server, (examples or link)... How does that render out?
  9. aFalcon

    What's next?

    HighlightLayer.removeAll() would be really helpful. Because -> glows all the things.
  10. aFalcon

    What's next?

    🏆 The bird likes to learn. Asks boss, says "later".
  11. aFalcon

    What's next?

    Rewritten... animation-configuration-objects can be put in a single array, var anmScript = [anm1, anm2, anm3,...]; ...triggered at run-time. : ) BABYLON.animation(anm1); token animations - give single line animation loops,: BABYLON.animation({attr:'opacity',to:0, from:0, done:fn(){]); And single-line animation loops is what makes ....animation-factories. UPDATED.
  12. aFalcon

    What's next?

    BABYLON.animate( {src:{}, attr:'', from:0, to:10, done:fn(){} } ); //compact single-line interpolation factory syntax. : )
  13. "always bet on js" ...
  14. @Pryme8 links are - radical. Yes read/edit/review, after steam release next monthish. : )
  15. Wingy, check this out... how to make translucent thick dashed lines in a circle? Related to GUIMeter, but along lines of COMBINATION-LOCK.... https://codepen.io/yuanchuan/pen/KyJvmo UPDATE: had trouble getting line:width, thick translucent line would have been cool. Hello ribbon or tube, or...? ~GUILOCK1(http://www.babylonjs-playground.com/#XX54TW#3)
  16. @Pryme8, for use in the future... "take your indices clone it to a new array, reverse the array, and concat it to the original indices array, then update vertex data." 🏆
  17. I see a plane can be created as {sideOrientation: BABYLON.Mesh.DOUBLESIDE}, But is it possible to make a plane which is FRONTSIDE by default... and then DOUBLESIDE dynamically at runtime? CONTEXT: a plane is imported by blender (as a complex shape), it is DEFAULT FRONTSIDE. After many user interactions the plane then can become DOUBLESIDE . How to do this? Without it being DOUBLESIDE on the blender import. Feeble attempts in this playground: https://www.babylonjs-playground.com/#LXZPJK#53 There is a delay, and then tries to: 1) convert directly plane.sideOrientation = BABYLON.Mesh.DOUBLESIDE (no change) 2) and it seems possible to clone the mesh and re-create it with DOUBLESIDE (but complications with height,width, rotation, performance overhead, etc) So, curious: Is there a way to dynamically apply DOUBLESIDE to a plane? 3) if not, will probably blenderfix...etc. : ) Thanks,
  18. Nice option, tried it, and failed. But reading your steps carefully... I didn't clone the indices, and then update vertex data. Makes sense. Will try someday. Thx. Out of likes for the day.... The variation I tried was to create a new plane DOUBLESIDED, maybe that would work to do that then update vertex data? Worth a try. Not sure if it needed reverse or not.
  19. ! @Gijs and @jerome, didn't see you respond. Tips are excellent! Thank you for confirming variation on geometry, had no clue. : ) Makes sense. SOLUTION: Because the context involved blender-import, as usual, solution involves a BLENDERFIX. Tried 3 things: 1) checkbox for BackFaceCulling (unchecked) === seemed to have no effect. 2) Add Modifier -> SOLIDIFY -> Apply (for each plane) in edit mode === it works, but changed rendering, because geometries changed.... 3) Found Vertex Data Object -> checkbox -> DOUBLESIDED trying that... === seemed to have no effect. SOLUTION: going with solidify. : )
  20. aFalcon

    BABYLON.Augmented Reality ...

    ~ Awesome insights @ozRocker and @JCPalmer... All tests in this thread were: Google PIXEL, Android, and MS Surface. Did not see those errors.
  21. ...diving-in. great stuff @Pryme8 How do you do it? Workflow tips? Or, how do you reduce problem into functions? Etc. Please, need more info! : ) The single complete and grammatical sentence (above) dedicated to @Wingnut... Trying!
  22. Also "tachometer"... https://en.wikipedia.org/wiki/Tachometer
  23. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! ....add(falseCamera.position))? And the tan(fov/2) is the sizing? -> From the billboard output plane of the aspect ratio in the fake camera field of view... almost got it. Nope not it... shader.setFloat('time', time); shader.setVector3('camOffset', output.position.clone().add(falseCamera.position)); shader.setVector3('camTarget', falseCamera.getFrontPosition(1)); How does it stripe material, and move in opposite direction (based on time)... Finally just reads the _fs and _vs. It's all there! : ) Thank you for the intro to WebGL shaders. : ) MOD: https://www.babylonjs-playground.com/#C0PXB0#6
  24. Yes, "Nixie tubes" === typeof "cool". <finally-clicks-it/>. And "meter-needle", hear you, caught it too [as a-design-difference]. !important; : ) Hopefully we progress from opposite sides to same-center... Ray, tangent, arc!?! Will try PG next week after: createSteamAchievements(32); And time for a FANTASTIC QUOTE (unrelated to everything): http://www.gimptalk.com/index.php?showtopic=44529#p339365 http://www.mahvin.com/2010/01/i-found-this-stone-texture-tutorial-for.html from the-old-days. ~ njoy. PS. for meter positioning calculation: Q: how about offset in localspace? - and/or as inverted [design-difference] -> from raycast at tgt (hit===cube-tip). Worth a try... : )