coda
coda

Reputation: 105

Three.js - wrong rendering output

I have a problem with my simple three.js code. The code contains a few lines for the setup and displays a few cubes. But the some cubes in the background are displayed in the foreground.

Did I forgot something to do?

I hosted the code on http://goo.gl/qUZKRt (press shift to rotate the camera).

Any sort of help would be great!

Thank you

Upvotes: 0

Views: 104

Answers (1)

Alex Under
Alex Under

Reputation: 1489

First of all - you have 2 renderers in your code, both - WebGL and Canvas. Check it. Than, since you are using lights in your scene, setting just color to your material would not be enough. So check it as well. The rest - just a matter of playing around with your lights' values.

See this example: http://jsfiddle.net/FeMq7/1/

Hope that helps, Alex

Upvotes: 1

Related Questions