• Content Count

  • Joined

  • Last visited

About rgalindox

  • Rank

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. rgalindox

    Line width similar to LineRenderer in Unity

    I'm playing around ribbons and they are awesome, as I can to my lines in parallel and then apply the ribbon, looks great! Do you know if the resulting ribbon is a mesh that can be clicked on? I'll test this shortly but wondering if you already tested this. Thanks
  2. rgalindox

    Line width similar to LineRenderer in Unity

    Let me check the Ribbons and play with the billboard mode. Thanks
  3. rgalindox

    Line width similar to LineRenderer in Unity

    Thanks Kesshi, I'm wondering how Unity implemented this when exporting to WebGL as it looks exactly as exporting to other platforms.
  4. Hello guys, I'm investigating BabylonJS for our next project at the company, we have our current application built in Unity and exported to WebGL, it is working pretty well however BabylonJS seems a great alternative in terms of portability to other platforms specially mobiles. We relay a lot on line renderers into the application as we crate many items on the fly, but I see the line function in BabylonJS doesn't support width. Someone has a workaround to have lines wider on scenes? I've tried tubes but they don't look very well compared to a line drawn on the fly as I have a function that smoothes the lines using interpolation. Thanks in advance
  5. Hi, in which part of the code should I add the camera limits for the zoom? or when it is triggered? Thanks
  6. rgalindox

    BabylonJS Import Classes

    Thank you very much! I appreciate your help.
  7. Hi, I was able to make scenes using vanilla javascript and BabylonJS. Now I want to refactor all in Typescript as my background is with C#. Anyone has an example how to import a class from another file including what loader do you use, I'm getting this error on the web browser: Uncaught ReferenceError: define is not defined at game.js This are extract of the files: index.html <!DOCTYPE html> <head> <script src="js/babylon.3.0.js"></script> <script src="js/hand-1.3.7.js"></script> <script src="./scripts/game.js"></script> <style> game.ts /// <reference path=".././js/babylon.3.0.d.ts"/> import { SceneUtils } from './sceneutils'; class Game { private _canvas: HTMLCanvasElement; private _engine: BABYLON.Engine; private _scene: BABYLON.Scene; private _camera: BABYLON.ArcRotateCamera; private _light: BABYLON.Light; constructor(canvasElement : string) { // Create canvas and engine this._canvas = <HTMLCanvasElement>document.getElementById(canvasElement); this._engine = new BABYLON.Engine(this._canvas, true); } createScene() : void { console.log("Start create scene"); // create a basic BJS Scene object this._scene = new BABYLON.Scene(this._engine); // create a FreeCamera, and set its position to (x:0, y:5, z:-10) //this._camera = new BABYLON.FreeCamera('camera1', new BABYLON.Vector3(0, 5,-10), this._scene); this._camera = new BABYLON.ArcRotateCamera('camera1', 0, 0, 0, BABYLON.Vector3.Zero(), this._scene); this._camera.setPosition(new BABYLON.Vector3(0, 15, -30)); // target the camera to scene origin this._camera.setTarget(BABYLON.Vector3.Zero()); // attach the camera to the canvas this._camera.attachControl(this._canvas, false); // create a basic light, aiming 0,1,0 - meaning, to the sky this._light = new BABYLON.HemisphericLight('light1', new BABYLON.Vector3(0,1,0), this._scene); // create a built-in "sphere" shape; with 16 segments and diameter of 2 let sphere = BABYLON.MeshBuilder.CreateSphere('sphere1', {segments: 16, diameter: 2}, this._scene); // move the sphere upward 1/2 of its height sphere.position.y = 1; // create a built-in "ground" shape let ground = BABYLON.MeshBuilder.CreateGround('ground1', {width: 6, height: 6, subdivisions: 2}, this._scene); } sceneutils.ts /// <reference path=".././js/babylon.3.0.d.ts"/> export class SceneUtils { constructor(){} public SetSceneBackground(backgroundColor: string, scene): void { scene.clearColor = new BABYLON.Color3(1,0,0); } public GetCurrentBKColor(): string { return '#556789'; } } If I don't use the import declaration in game.ts, I don't get any errors and I can see my scene. However my project will have a lot of classes that I need to import in game.ts and other files. I was playing with require.js but I can't make it work. Thank you very much for your feedback!!!!!
  8. Hi guys, sorry for coming back to this thread. I'm importing a scene exported from Unity. I want the background to be green, but as soon as I import the .babylon scene it turns to black. This is the code: BABYLON.SceneLoader.Load("", "assets/myscene.babylon", engine, function (scene) { scene.clearColor = new BABYLON.Color3(0.5, 0.8, 0.5); scene.ambientColor = new BABYLON.Color3(0.3, 0.3, 0.3); If I create a scene without invoking the SceneLoader.Load the background color works fine. Any idea or hint is welcome.
  9. rgalindox

    Sponza demo

    Thank you @Raggar I'll test it right away!
  10. rgalindox

    Sponza demo

    Hi, I'm testing BabylonJS using Electron for Desktop-Multiplatform. It is possible to download the sponza project so I can test how well it runs loading all assets from a local Hard Disk using Electron? Thanks
  11. rgalindox

    How good is Babylon.js?

    Great news!!!! I'll give a look to the links. Kind regards
  12. rgalindox

    How good is Babylon.js?

    Thank you very much @JohnK, sorry I didn't explain myself correctly. I just want the normal parent child setting, so when I move the parent the child moves along. this is because I have a chain of 32 elements with a common parent. What I did for now was created the models and parented inside Unity and exported to BabylonJS, in this case it seems it is working correctly. But still doing some tests. Keep you posted. At the beginning as I come from the Unity world Babylon looks so complicated, but now I feel more comfortable and for basic stuff is not that complicated. My main concern for the application I working on is to know if there are more commercial products built on Babylon as our product is going to sell to large clients and my concern is how good is for production products. Thanks again
  13. rgalindox

    How good is Babylon.js?

    Hi Guys, I'm testing Babylon for a new project. In Unity I have a parent object, and then setting up a child object is easy, in the Editor I move the object and I know the position and rotation, then I can write down the coordinates on the code. With Babylon I'm trying to do this but it's very complex as I have to move the object and test and test and test, It takes several hours to place the child object correctly. NOTE: The parent object position is not its center as I need to rotate it from another pivot point, so I can't use the parent's position to start moving the child. Any suggestions to this process?
  14. rgalindox

    Unity to Babylon exporter Problem

    Hi, when you export from Unity do you see your 3d models with smooth textures? I export from Unity and it is showing the texture like a low poly model, the texture is not smooth. Any recommendations? Thanks