提交 73283a60 编写于 作者: M Mr.doob

Added .setPrecision() to Ray. Fixes #1328.

上级 2c6e0d18
......@@ -24,6 +24,14 @@ THREE.Ray = function ( origin, direction ) {
};
var precision = 0.0001;
this.setPrecision = function ( value ) {
precision = value;
};
var a = new THREE.Vector3();
var b = new THREE.Vector3();
var c = new THREE.Vector3();
......@@ -101,7 +109,7 @@ THREE.Ray = function ( origin, direction ) {
// bail if ray and plane are parallel
if ( Math.abs( dot ) < 0.0001 ) continue;
if ( Math.abs( dot ) < precision ) continue;
// calc distance to plane
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册