Commit 1a0a4727 authored by Amanda Ghassaei's avatar Amanda Ghassaei

debugging

parent b7523b21
......@@ -107,8 +107,8 @@ function initViveInterface(globals){
controller.head = camera;
var
meshColorOff = 0x888888,
meshColorOn = 0x555555,
meshColorOff = 0x555555,
meshColorOn = 0x888888,
controllerMaterial = new THREE.MeshStandardMaterial({
color: meshColorOff
}),
......@@ -255,7 +255,7 @@ function initViveInterface(globals){
//todo get position and mesh in same reference frame
var cast = new THREE.Raycaster(position, tDirection, 0, 1);
var cast = new THREE.Raycaster(position, tDirection, 0, 0.1);
var intersects = cast.intersectObjects(globals.model.getMesh(), false);
if (intersects.length>0){
var intersection = intersects[0];
......@@ -281,9 +281,7 @@ function initViveInterface(globals){
nodes[i] = nodesArray[nodeIndex];
object3D.position.copy(transformToGlobalCoords(nodes[i].getPosition().clone()));
object3D.visible = true;
controllers[i].userData.mesh.material.color.setHex( 0x888888 );
} else {
controllers[i].userData.mesh.material.color.setHex( 0xff0000 );
nodes[i] = null;
}
......
......@@ -176,7 +176,7 @@ function initModel(globals){
function setGeoUpdates(){
geometry.attributes.position.needsUpdate = true;
if (globals.colorMode == "axialStrain") geometry.attributes.color.needsUpdate = true;
// if (globals.userInteractionEnabled || globals.vrEnabled) geometry.computeBoundingBox();
if (globals.userInteractionEnabled || globals.vrEnabled) geometry.computeBoundingBox();
}
function startSolver(){
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment