mrdoob/three.js — Issue #1327: Set different materials on cube's different side?
Author: Dino4674
Created: 2012-02-14 23:01:29+00:00
State: open

In chrome console it says that material as an array has been deprecated.
I want to apply different material to cube's different side.

//convert from SVG
var imageCanvas = document.createElement("canvas");
canvg(imageCanvas, mark.svg);

var texture = new THREE.Texture(imageCanvas);
texture.needsUpdate = true;

var geometry = new THREE.CubeGeometry(200, 10, 200);
var cubeMaterial = new THREE.MeshBasicMaterial({
map : texture
});

var cube = new THREE.Mesh(geometry, cubeMaterial);

Like this, all 6 cube's sides have that picture as material. I would like to apply that picture material to only 2 sides an on the rest 4 I would like to put a color.
How can I do that?

And also, is there any other place between this issues list, API Docs and those examples here on GitHub where I can lear Three.js?