Search the Community

Showing results for tags 'fileformat'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • HTML5 Game Coding
    • News
    • Game Showcase
    • Facebook Instant Games
    • Web Gaming Standards
    • Coding and Game Design
  • Frameworks
    • Phaser 3
    • Phaser 2
    • Pixi.js
    • Babylon.js
    • Panda 2
    • melonJS
  • General
    • General Talk
  • Business
    • Collaborations (un-paid)
    • Jobs (Hiring and Freelance)
    • Services Offered

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Website URL


Twitter


Skype


Location


Interests

Found 2 results

  1. Hello, What is the correct format of a .babylon file so that it can load an HDR texture into the reflectionTexture slot of a PBRMaterial? I know how to do this in code: var hdrTexture = new BABYLON.HDRCubeTexture("/g/test/interior.hdr", scene, 512); But I can't achieve the same thing with a .babylon file that is loaded with BABYLON.SceneLoader.ImportMesh. This is the last format I tried: { "materials": [ { "customType":"BABYLON.PBRMaterial", "name":"Material", "id":"Material", "alpha":1, "backFaceCulling":true, "albedoTexture": // the albedo loads fine! { "name":"DefaultMaterial_Base_Color.png", "level":1, "hasAlpha":0, "coordinatesMode":0, "uOffset":0, "vOffset":0, "uScale":1, "vScale":1, "uAng":0, "vAng":0, "wAng":0, "wrapU":true, "wrapV":true, "coordinatesIndex":0 }, "reflectionTexture": // this causes an error on load! { "name":"interior.hdr", "level":1, "hasAlpha":0, "coordinatesMode":3, "size":512, "uOffset":0, "vOffset":0, "uScale":1, "vScale":1, "uAng":0, "vAng":0, "wAng":0, "wrapU":true, "wrapV":true, "coordinatesIndex":0 } } ], "meshes":[{...}] } The model loads fine. As does the albedo texture (shown) and the reflectivity and normal textures (not shown). But when I include the Reflection texture it fails. The message in the console is: "babylon.js:3 BJS - [12:09:33]: Error while trying to load texture: /g/test/interior.hdr". Any help much appreciated. kind regards Karl
  2. Hi, I have trouble using mesh instances while parsing a .babylon file. I'm using Newtonsoft to parse a .babylon file in c# and since i'm trying to improve the parsing and save memory space and time by using mesh instances instead of having vetex data copies inside meshes the model keeps loading fine in sandbox but doesn't show the instances geometries on the screen... (they all are enable and visible) I have the exact same problem when i try to use geometry ids which are the same for meshes with similar vertex data but different placement. (what should be an instance...) I can give samples files if you want to help me on that. I also made log files to compare matrices transformations in different cases which appears that it should be working But my parser is used in a very particular case so it wont any usefull to share it.. My best guess was that instances worked like parent | child so the child transformation depends on it's parent transformation. but i've seen files working where the child transformation was based on the world transformation and no link at all with the containing mesh. I was then wondering if there was a limit on the number of instances then i saw that there was not on the documentation. I'm stuck here and hope that somebody could help me on that ! preview : { "materials": [{ "name": "124848", "id": "124848", "ambient": [0.0, 0.0, 0.0], "diffuse": [0.423529416, 0.266666681, 0.0431372561], "specular": [0.0, 0.0, 0.0], "emissive": [0.0, 0.0, 0.0], "specularPower": 0.0, "alpha": 1.0, "backFaceCulling": false, "checkReadyOnlyOnce": true }], "meshes": [{ "name": "9d3d5698", "id": "d6880dd6-4a83-4891-8746-61ca867be8d7", "skeletonId": "-1", "materialId": "124848", "billboardMode": 0, "autoAnimateFrom": 0, "autoAnimateTo": 100, "isVisible": true, "isEnabled": true, "pickable": false, "freezeWorldMatrix": false, "checkCollisions": false, "receiveShadows": true, "autoAnimateLoop": true, "showBoundingBox": false, "showSubMeshesBoundingBox": false, "infiniteDistance": false, "autoAnimate": true, "visibility": 1.0, "subMeshes": [{ "materialIndex": 0, "verticesStart": 0, "verticesCount": 72, "indexStart": 0, "indexCount": 36 }], "instances": [{ "id": "cfe2ea30-9cda-4185-9bbf-5e3c5780f8e1", "materialId": "124848", "name": "fd255bd6", "position": [14.1874352, 23.2159557, -33.19057], "rotation": [0.0, 0.0, 0.0], "rotationQuaternion": [0.0, 1.0, 0.0, 0.0], "scaling": [0.01, 0.01, 0.01], "freezeWorldMatrix": true, "animations": [] }], "position": [15.387435, 23.2159557, -33.19057], "rotation": [0.0, 0.0, 0.0], "rotationQuaternion": [0.0, 1.0, 0.0, 0.0], "scaling": [0.01, 0.01, 0.01], "pivotMatrix": [1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0], "positions": [... (72)], "normals": [... (72)], "indices": [... (36)], "animations": [empty] }] }