Jump to content

Blender export problem


excelsior
 Share

Recommended Posts


	    var darkblue = new BABYLON.StandardMaterial('darkblue', scene)
	    darkblue.alpha = 1;
	    darkblue.diffuseColor = new BABYLON.Color3.FromInts(249,232,180);
	    darkblue.emissiveColor  = new BABYLON.Color3(0,0,0);
	    darkblue.ambientColor = new BABYLON.Color3(0, 0, 0);

	    var cube =  BABYLON.Mesh.CreateBox('cube',2,scene);
	    cube.scaling.z = 1;
	    cube.scaling.y = 0.5;
	    cube.position.x = -5;
	    cube.position.y =  2;
	    cube.position.z =  -2;
	    cube.material = darkblue;





BABYLON.SceneLoader.ImportMesh("", "mesh/book/", "untitled.babylon", scene, function (newMeshes){
										console.log(newMeshes)

											test = newMeshes[0]
											test.material = scene.tex.darkblue;

									})

So i ve created 2 cube one with babylon the one  on the left,  the other is the starting cube from blender that i exported. i apply the same material on both of them why does the light react differently on them ? 

Capture.PNG

Link to comment
Share on other sites

Well this a test, two cubes - one from Blender, one created in BJS. I use the material for both that you defined as "darkblue". The Blender file contains a point light placed between the two cubes and above them.

2 cubes

The javascript is in the html file - so just view the page content in the web console

cheers, gryff :)

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...