|
@@ -99062,12 +99062,28 @@ and limitations under the License.
|
|
|
, r = n(4)
|
|
|
, o = function() {
|
|
|
function t() {}
|
|
|
+ // return t.fromArray = function(t) {
|
|
|
+ // if (t) {
|
|
|
+ // if (4 !== t.length)
|
|
|
+ // throw new i.IVFrontendException("Wrong number of ordinates for a quaternion!");
|
|
|
+ // //return new r.Quaternion(t[1],t[2],t[3],t[0])
|
|
|
+ // return new r.Quaternion(t[1],-t[2],t[3],t[0]).multiply((new r.Quaternion).setFromAxisAngle(new r.Vector3(0,0,1), r.Math.degToRad(-90)));
|
|
|
+ // }
|
|
|
+ // }
|
|
|
return t.fromArray = function(t) {
|
|
|
if (t) {
|
|
|
- if (4 !== t.length)
|
|
|
+ if (4 !== t.length)// 存储的array是[w,x,y,z]
|
|
|
throw new i.IVFrontendException("Wrong number of ordinates for a quaternion!");
|
|
|
//return new r.Quaternion(t[1],t[2],t[3],t[0])
|
|
|
- return new r.Quaternion(t[1],-t[2],t[3],t[0]).multiply((new r.Quaternion).setFromAxisAngle(new r.Vector3(0,0,1), r.Math.degToRad(-90)));
|
|
|
+ //return new r.Quaternion(t[1],-t[2],t[3],t[0]).multiply((new r.Quaternion).setFromAxisAngle(new r.Vector3(0,0,1), r.Math.degToRad(-90)));
|
|
|
+
|
|
|
+
|
|
|
+ /* let a = new r.Quaternion(t[1],t[3],-t[2],t[0]).multiply((new r.Quaternion).setFromAxisAngle(new r.Vector3(0,1,0), r.Math.degToRad(90)));
|
|
|
+ a.multiply((new r.Quaternion).setFromAxisAngle(new r.Vector3(1,0,0), r.Math.degToRad(-90)));
|
|
|
+ return a */
|
|
|
+ return new r.Quaternion(t[1],t[2],t[3],t[0]).multiply((new r.Quaternion).setFromAxisAngle(new r.Vector3(0,0,1), r.Math.degToRad(-90)));
|
|
|
+
|
|
|
+
|
|
|
}
|
|
|
}
|
|
|
,
|
|
@@ -110418,8 +110434,8 @@ and limitations under the License.
|
|
|
}
|
|
|
,
|
|
|
e.prototype.computeLocalCoordinatesFromGlobal = function() {
|
|
|
- this.location = this.GeoTransformationService.vectorToLocal(this.globalLocation),
|
|
|
- this.floorLocation = this.GeoTransformationService.vectorToLocal(this.globalFloorLocation),
|
|
|
+ this.location = this.GeoTransformationService.vectorToLocal(this.globalLocation);
|
|
|
+ this.floorLocation = this.GeoTransformationService.vectorToLocal(this.globalFloorLocation);
|
|
|
this.orientation = this.globalOrientation ? this.globalOrientation.clone() : void 0,
|
|
|
this.floorOrientation = this.globalFloorOrientation ? this.globalFloorOrientation.clone() : void 0
|
|
|
}
|
|
@@ -123072,10 +123088,40 @@ and limitations under the License.
|
|
|
this.proj4Transformer = t
|
|
|
}
|
|
|
return t.prototype.forward = function(t) {
|
|
|
+ // var e = this.proj4Transformer.forward(t);
|
|
|
+ // return t.x = e.x,
|
|
|
+ // t.y = e.y,
|
|
|
+ // t
|
|
|
var e = this.proj4Transformer.forward(t);
|
|
|
- return t.x = e.x,
|
|
|
- t.y = e.y,
|
|
|
- t
|
|
|
+ console.log('t-x:'+t.x+',t-y'+t.y);
|
|
|
+ if(t.x == 113.59571152939596 || t.y == 22.366594630499026 ){
|
|
|
+ console.log('okokokokokokokok1');
|
|
|
+ //t.x = -0.3665;
|
|
|
+ //t.y = -3.3755;
|
|
|
+ t.x = 0;
|
|
|
+ t.y = 0;
|
|
|
+ t.z = 0; //0.43665
|
|
|
+ }
|
|
|
+ else if(t.x == 113.595707287329 || t.y == 22.366616648951815){
|
|
|
+ console.log('okokokokokokokok2:'+t.z);
|
|
|
+ //t.x = -0.4656740128993988;
|
|
|
+ //t.y = 2.6516430377960205;
|
|
|
+ }
|
|
|
+ // else if(t.x == 113.59500109428738 || t.y == 22.367331946366644){
|
|
|
+ // console.log('okokokokokokokok2:'+t.z);
|
|
|
+ // t.x = -0.30490899085998535;
|
|
|
+ // t.y = -0.37807899713516235;
|
|
|
+ // }
|
|
|
+ // else if(t.x == 113.59500087 || t.y == 22.36732539){
|
|
|
+ // console.log('okokokokokokokok3:'+t.z);
|
|
|
+ // t.x = -0.30490899085998535;
|
|
|
+ // t.y = -0.37807899713516235;
|
|
|
+ // }
|
|
|
+ else{
|
|
|
+ t.x = e.x;
|
|
|
+ t.y = e.y;
|
|
|
+ }
|
|
|
+ return t;
|
|
|
}
|
|
|
,
|
|
|
t.prototype.inverse = function(t) {
|