scene = new THREE.Scene();
var menu = "Подарки";
var menu_text = new THREE.TextGeometry( menu, {
size: 14,
height: 5,
curveSegments: 2,
font: "arial"
});
menu_text.computeBoundingBox();
var textMaterial = new THREE.MeshBasicMaterial( { color: Math.random() * 0xffffff, overdraw: true } );
var text = new THREE.Mesh( menu_text, textMaterial );
text.rotation.y = 60 * Math.PI/180;
text.position.set(10* Math.cos(text.rotation.y), 120, -10* Math.sin(text.rotation.y));
var text1=text;
var menu = "Счет";
menu_text = new THREE.TextGeometry( menu, {
size: 14,
height: 5,
curveSegments: 2,
font: "arial"
});
menu_text.computeBoundingBox();
//var textMaterial = new THREE.MeshBasicMaterial( { color: Math.random() * 0xffffff, overdraw: true } );
var text = new THREE.Mesh( menu_text, textMaterial );
text.rotation.y = 60 * Math.PI/180;
text.position.set(10* Math.cos(text.rotation.y), 95, -10* Math.sin(text.rotation.y));
var text2 = text;
var menu = "Выход";
var menu_text = new THREE.TextGeometry( menu, {
size: 14,
height: 5,
curveSegments: 2,
font: "arial"
});
menu_text.computeBoundingBox();
//var textMaterial = new THREE.MeshBasicMaterial( { color: Math.random() * 0xffffff, overdraw: true } );
var text = new THREE.Mesh( menu_text, textMaterial );
text.rotation.y = 60 * Math.PI/180;
text.position.set(10* Math.cos(text.rotation.y), 70, -10* Math.sin(text.rotation.y));
var text3 = text;
var menu = "Новое";
var menu_text = new THREE.TextGeometry( menu, {
size: 14,
height: 5,
curveSegments: 2,
font: "arial"
});
menu_text.computeBoundingBox();
//var textMaterial = new THREE.MeshBasicMaterial( { color: Math.random() * 0xffffff, overdraw: true } );
var text = new THREE.Mesh( menu_text, textMaterial );
text.rotation.y = 180 * Math.PI/180;
text.position.set(10* Math.cos(text.rotation.y), 120, -10* Math.sin(text.rotation.y));
var text41 = text;
var menu = "сообщение";
var menu_text = new THREE.TextGeometry( menu, {
size: 14,
height: 5,
curveSegments: 2,
font: "arial"
});
menu_text.computeBoundingBox();
var textMaterial = new THREE.MeshBasicMaterial( { color: Math.random() * 0xffffff, overdraw: true } );
var text = new THREE.Mesh( menu_text, textMaterial );
text.rotation.y = 180 * Math.PI/180;
text.position.set(10* Math.cos(text.rotation.y), 105, -10* Math.sin(text.rotation.y));
var text42 = text;
var menu = "Список";
var menu_text = new THREE.TextGeometry( menu, {
size: 14,
height: 5,
curveSegments: 2,
font: "arial"
});
menu_text.computeBoundingBox();
//var textMaterial = new THREE.MeshBasicMaterial( { color: Math.random() * 0xffffff, overdraw: true } );
var text = new THREE.Mesh( menu_text, textMaterial );
text.rotation.y = 180 * Math.PI/180;
text.position.set(10* Math.cos(text.rotation.y), 90, -10* Math.sin(text.rotation.y));
var text51 = text;
var menu = "сообщений";
var menu_text = new THREE.TextGeometry( menu, {
size: 14,
height: 5,
curveSegments: 2,
font: "arial"
});
menu_text.computeBoundingBox();
//var textMaterial = new THREE.MeshBasicMaterial( { color: Math.random() * 0xffffff, overdraw: true } );
var text = new THREE.Mesh( menu_text, textMaterial );
text.rotation.y = 180 * Math.PI/180;
text.position.set(10* Math.cos(text.rotation.y), 75, -10* Math.sin(text.rotation.y));
var text52 = text;
var menu;
if (M_J=1){
menu = "Фаворитки";
}
else{
menu = "Фавориты";
}
var menu_text = new THREE.TextGeometry( menu, {
size: 14,
height: 5,
curveSegments: 2,
font: "arial"
});
menu_text.computeBoundingBox();
//var textMaterial = new THREE.MeshBasicMaterial( { color: Math.random() * 0xffffff, overdraw: true } );
var text = new THREE.Mesh( menu_text, textMaterial );
text.rotation.y = 180 * Math.PI/180;
text.position.set(10* Math.cos(text.rotation.y), 50, 10* Math.sin(text.rotation.y));
var text6 = text;
// Cube
var geometry = new THREE.CubeGeometry( 110, 300, 5 );
//var material = new THREE.MeshBasicMaterial( { color: Math.random() * 0xffffff, opacity: 0.5, transparent: true });
cube1 = new THREE.Mesh( geometry, material );
cube1.rotation.y = 120 * Math.PI/180;
cube1.position.set(-50* Math.cos(cube1.rotation.y), 0, 50* Math.sin(cube1.rotation.y));
//var material = new THREE.MeshBasicMaterial( { color: Math.random() * 0xffffff, opacity: 0.5, transparent: true });
cube2 = new THREE.Mesh( geometry, material );
cube2.rotation.y = 240 * Math.PI/180;
cube2.position.set(-50* Math.cos(cube2.rotation.y), 0, 50* Math.sin(cube2.rotation.y));
var loader = new THREE.TextureLoader();
loader.load( 'textures/land_ocean_ice_cloud_2048.jpg', function ( texture ) );
var material = new THREE.MeshBasicMaterial( { map: texture, opacity: 0.5, transparent: true });
cube3 = new THREE.Mesh( geometry, material );
cube3.rotation.y = 360 * Math.PI/180;
cube3.position.set(-50* Math.cos(cube3.rotation.y), 0, 50* Math.sin(cube3.rotation.y));
// для прорисовки
megalit.add(cube1);
megalit.add(cube2);
megalit.add(cube3);
megalit.add(text1);
megalit.add(text2);
megalit.add(text3);
megalit.add(text41);
megalit.add(text42);
megalit.add(text51);
megalit.add(text52);
megalit.add(text6);
megalit.position.set(-1000,450,-300);
// добавление текста
scene.add( megalit );
objects.push(cube1);
objects.push(cube2);
objects.push(cube3);
objects.push(text1);
objects.push(text2);
objects.push(text3);
objects.push(text41);
objects.push(text42);
objects.push(text51);
objects.push(text52);
objects.push(text6);
// Plane