diff --git a/static/index.html b/static/index.html
index 95a9b3b..46999cb 100644
--- a/static/index.html
+++ b/static/index.html
@@ -21,6 +21,7 @@
+
nothing
diff --git a/static/scripts/materials.js b/static/scripts/materials.js
index f6102f4..2b1a285 100644
--- a/static/scripts/materials.js
+++ b/static/scripts/materials.js
@@ -6,23 +6,25 @@ var curveProperties = {
};
materials.prepare = function() {
- var sprite = new THREE.Texture(document.getElementById("ball"));
- sprite.needsUpdate = true;
+ var ballSprite = new THREE.Texture(document.getElementById("ball"));
+ var tipSprite = new THREE.Texture(document.getElementById("tip"));
+ ballSprite.needsUpdate = true;
+ tipSprite.needsUpdate = true;
materials.edge = new THREE.LineBasicMaterial({
color: "gray",
transparent: false,
linewidth: 1
});
- materials.point = new THREE.PointsMaterial({
- size: 0.1,
- map: sprite,
+ materials.tip = new THREE.PointsMaterial({
+ size: 0.4,
+ map: tipSprite,
alphaTest: 0.5,
transparent: true,
- vertexColors: THREE.VertexColors
+ color: "red"
});
materials.qubit = new THREE.PointsMaterial({
size: 0.3,
- map: sprite,
+ map: ballSprite,
alphaTest: 0.5,
transparent: true,
vertexColors: THREE.VertexColors
diff --git a/static/scripts/mouse.js b/static/scripts/mouse.js
index 7b87ed2..a22c6a9 100644
--- a/static/scripts/mouse.js
+++ b/static/scripts/mouse.js
@@ -1,5 +1,6 @@
var mouse = {};
mouse.wasClick = true;
+mouse.pressed = false;
mouse.raycaster = new THREE.Raycaster();
@@ -32,10 +33,10 @@ mouse.onDown = function(event) {
};
mouse.onUp = function(event) {
+ mouse.pressed = false;
if (!mouse.wasClick) {
return;
}
- mouse.pressed = false;
if (event.ctrlKey) {
mouse.onCtrlClick();
} else if (event.shiftKey) {