I’m trying to create a Cylinder but with no success.
This is my code:
geometry02 = new THREE.CylinderGeometry( 20, 100, 100, 1000 );
material02 = new THREE.MeshBasicMaterial({color: 0x0000ff});
cylinder02 = new THREE.Mesh( geometry02, material02 );
cylinder02.position.x = 300;
scene.addObject( cylinder02 );
Am I forgetting to include something?
There is nothing wrong with the snippet you just posted. I can confirm it runs ok if I paste in an example.
Make sure that:
camera.lookAt(yourObject);is a good way to do that)As a side note, you might want to decrease the segmentsRadius parameter(1000) to a smaller value. You might get a similar look/level detail with less vertices/faces.