Jump to content

Search the Community

Showing results for tags 'multitexture'.

  • 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
    • Paid Promotion (Buy Banner)
  • Frameworks
    • Pixi.js
    • Phaser 3
    • Phaser 2
    • Babylon.js
    • Panda 2
    • melonJS
    • Haxe JS
    • Kiwi.js
  • General
    • General Talk
    • GameMonetize
  • Business
    • Collaborations (un-paid)
    • Jobs (Hiring and Freelance)
    • Services Offered
    • Marketplace (Sell Apps, Websites, Games)

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 3 results

  1. I have problem with physics and mesh impostor with sphere. I create some componets in blender. And add each component texture. I create pathMesh from components. (pathMesh have multi materials and textures because each component has its own material and texture) If I load babylon with sandbox it load OK (but sandbox doesn't have pathMesh.bakeCurrentTransformIntoVertices(); . If I have pathMesh.bakeCurrentTransformIntoVertices(); in loop then pathMesh is loaded without textures and physics works OK. If I remove pathMesh.bakeCurrentTransformIntoVertices(); then pathMesh is loaded correctly with textures, but physics doesn't work as it should. var pathMesh; meshTask.onSuccess = function (task) { for (var i=0; i<task.loadedMeshes.length; i++ ){ var newMesheI = task.loadedMeshes[i]; if ( newMesheI.id == "Path" ) { pathMesh = newMesheI; pathMesh.checkCollisions = true; pathMesh.bakeCurrentTransformIntoVertices(); // this line works ok with physics but pathMesh doesn load correcly with textures pathMesh.pBody= perplexus.setPhysicsState(BABYLON.PhysicsEngine.MeshImpostor , { mass: 0, friction: 0.4, restitution: 0 }); } ... I need pathMesh.bakeCurrentTransformIntoVertices(); and correcly inported pathMesh with its textures? Can anybody help me solve this problem? Any advice? What should I do? Am I missing anything? Greetings
  2. Hi all, First post here. Hello! I have some complex models I want to export to babylon, but seems that I made the exporter crash. These models are using a couple of textures both plugged to color channel, using different UV sets for each one and multiplying one to the other by blend mode. This is, the typical set of baked lights texture multiplying a color texture. When I try to export them, the exporter crashes. This is the output: Traceback (most recent call last): File "/home/jcarrasco/.config/blender/2.76/scripts/addons/io_export_babylon.py", line 294, in execute mesh = Mesh(object, scene, nextStartFace, forcedParent, nameID, self) File "/home/jcarrasco/.config/blender/2.76/scripts/addons/io_export_babylon.py", line 700, in __init__ bakedMat = BakedMaterial(exporter, object, recipe) File "/home/jcarrasco/.config/blender/2.76/scripts/addons/io_export_babylon.py", line 1991, in __init__ self.bake('diffuseTexture', 'DIFFUSE_COLOR', 'TEXTURE', image, mesh, uv, exporter, recipe) File "/home/jcarrasco/.config/blender/2.76/scripts/addons/io_export_babylon.py", line 2025, in bake self.bakeInternal(internal_type, image, uv) File "/home/jcarrasco/.config/blender/2.76/scripts/addons/io_export_babylon.py", line 2030, in bakeInternal Main.log('Internal baking texture, type: ' + bake_type + ', mapped using: ' + uv.name, 3)UnicodeDecodeError: 'utf-8' codec can't decode byte 0x80 in position 0: invalid start byte As far as I can see, there seems like the exporter is trying to bake this texture combination into a single one. Anyone has stepped into this problem before? Appart from the crash, Anyone know a working method to do this? Thanks in advance
  3. Hello everybody, when I render this code, it doesn't show all sphere multitexture, only shows the first texture: function createSceneTuto(engine){ var scene = new BABYLON.Scene(engine); var camera = new BABYLON.ArcRotateCamera("camara",-20,-45,35, new BABYLON.Vector3.Zero(),scene); var luz = new BABYLON.HemisphericLight("Sol", new BABYLON.Vector3(-10,150,0),scene); luz.diffuse = new BABYLON.Color3(0.6,0.7,1); luz.intensity = 0.5; var cubo = new BABYLON.Mesh.CreateBox("Cubo",10,scene); cubo.position.y = 10; var esfera = new BABYLON.Mesh.CreateSphere("Esfera",10,8,scene); var espejo = new BABYLON.StandardMaterial("texturaEspejo",scene); esfera.position = new BABYLON.Vector3(-15,10,0); suelo = new BABYLON.Mesh.CreateGround("tierra",200,200,2,scene,false); piedras = new BABYLON.StandardMaterial("Piedras",scene); piedras.bumpTexture = new BABYLON.Texture("../materiales/piedras.jpg",scene); rocas = new BABYLON.StandardMaterial("Rocas",scene); rocas.diffuseTexture = new BABYLON.Texture("../materiales/roca.png",scene); madera = new BABYLON.StandardMaterial("Plata",scene); madera.diffuseTexture = new BABYLON.Texture("../materiales/madera_gris.jpg",scene); multimat = new BABYLON.MultiMaterial("multi", scene); multimat.subMaterials.push(rocas); multimat.subMaterials.push(piedras); multimat.subMaterials.push(madera); esfera.subMeshes = []; var verticesCount = esfera.getTotalVertices(); esfera.subMeshes.push(new BABYLON.SubMesh(0,0, verticesCount,0,900,esfera)); esfera.subMeshes.push(new BABYLON.SubMesh(1,0, verticesCount,900,1800,esfera)); esfera.subMeshes.push(new BABYLON.SubMesh(2,0, verticesCount,1800,2088,esfera)); esfera.material = multimat; pelicula = new BABYLON.StandardMaterial("Pelicula",scene); pelicula.diffuseTexture = new BABYLON.VideoTexture("Sintel",["../textures/sintel.ogv"],256,scene,true); pelicula.emissiveColor = new BABYLON.Color3(1,1,1); suelo.material = pelicula; espejo.reflectionTexture = new BABYLON.MirrorTexture("espejo",512,scene,true); espejo.reflectionTexture.mirrorPlane = new BABYLON.Plane(1,-1.0,10,-10.0); espejo.reflectionTexture.renderList = [esfera,suelo]; cubo.material = espejo; return scene;}This is the image:
×
×
  • Create New...