@openglobus/og 0.17.0 → 0.17.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/@openglobus/og.esm.js +2 -2
- package/dist/@openglobus/og.esm.js.map +1 -1
- package/dist/@openglobus/og.umd.js +2 -2
- package/dist/@openglobus/og.umd.js.map +1 -1
- package/package.json +1 -1
- package/src/og/Events.js +2 -2
- package/src/og/Globe.js +1 -1
- package/src/og/ImageCanvas.js +2 -2
- package/src/og/LonLat.js +1 -1
- package/src/og/Object3d.js +1 -1
- package/src/og/QueueArray.js +1 -1
- package/src/og/Stack.js +1 -1
- package/src/og/astro/earth.js +3 -3
- package/src/og/camera/Frustum.js +4 -4
- package/src/og/camera/PlanetCamera.js +7 -7
- package/src/og/cons.js +1 -1
- package/src/og/control/DebugInfo.js +3 -3
- package/src/og/control/EarthNavigation.js +6 -13
- package/src/og/control/Lighting.js +1 -1
- package/src/og/control/MouseNavigation.js +1 -1
- package/src/og/control/visibleExtent/Segment.js +2 -2
- package/src/og/ellipsoid/Ellipsoid.js +31 -50
- package/src/og/entity/BillboardHandler.js +3 -3
- package/src/og/entity/EntityCollection.js +7 -7
- package/src/og/entity/GeoObject.js +6 -4
- package/src/og/entity/GeoObjectHandler.js +30 -20
- package/src/og/entity/GeometryHandler.js +15 -15
- package/src/og/entity/LabelHandler.js +10 -10
- package/src/og/entity/LabelWorker.js +1 -1
- package/src/og/entity/PointCloud.js +2 -2
- package/src/og/entity/PointCloudHandler.js +2 -2
- package/src/og/entity/Polyline.js +11 -11
- package/src/og/entity/PolylineHandler.js +2 -2
- package/src/og/entity/RayHandler.js +2 -2
- package/src/og/entity/StripHandler.js +2 -2
- package/src/og/input/KeyboardHandler.js +6 -6
- package/src/og/layer/BaseGeoImage.js +1 -1
- package/src/og/layer/CanvasTiles.js +1 -1
- package/src/og/layer/Vector.js +2 -2
- package/src/og/math/Vec3.js +5 -0
- package/src/og/math.js +3 -3
- package/src/og/mercator.js +1 -1
- package/src/og/quadTree/Node.js +15 -14
- package/src/og/renderer/Renderer.js +5 -5
- package/src/og/scene/BaseNode.js +1 -1
- package/src/og/scene/Planet.js +16 -21
- package/src/og/scene/RenderNode.js +9 -9
- package/src/og/segment/Segment.js +2 -2
- package/src/og/segment/SegmentLonLat.js +1 -1
- package/src/og/segment/segmentHelper.js +12 -12
- package/src/og/shaders/atmos.js +1 -1
- package/src/og/utils/GeoImageCreator.js +1 -1
- package/src/og/utils/NormalMapCreator.js +3 -3
- package/src/og/utils/PlainSegmentWorker.js +9 -9
- package/src/og/utils/TerrainWorker.js +2 -2
- package/src/og/utils/TextureAtlas.js +1 -1
- package/src/og/utils/earcut.js +8 -8
- package/src/og/utils/shared.js +10 -10
- package/src/og/webgl/Framebuffer.js +2 -2
- package/src/og/webgl/Handler.js +1 -1
- package/src/og/webgl/Multisample.js +2 -2
- package/src/og/webgl/Program.js +4 -4
- package/types/ImageCanvas.d.ts +1 -1
- package/types/ellipsoid/Ellipsoid.d.ts +3 -1
- package/types/entity/GeoObject.d.ts +1 -2
- package/types/math/Vec3.d.ts +2 -0
- package/types/scene/Planet.d.ts +1 -2
|
@@ -121,7 +121,7 @@ export class Framebuffer {
|
|
|
121
121
|
destroy() {
|
|
122
122
|
var gl = this.handler.gl;
|
|
123
123
|
|
|
124
|
-
for (
|
|
124
|
+
for (let i = 0; i < this.textures.length; i++) {
|
|
125
125
|
gl.deleteTexture(this.textures[i]);
|
|
126
126
|
}
|
|
127
127
|
this.textures = new Array(this._size);
|
|
@@ -148,7 +148,7 @@ export class Framebuffer {
|
|
|
148
148
|
|
|
149
149
|
if (!this._isBare) {
|
|
150
150
|
let attachmentArr = [];
|
|
151
|
-
for (
|
|
151
|
+
for (let i = 0; i < this.textures.length; i++) {
|
|
152
152
|
let ti = this.textures[i] || this.handler.createEmptyTexture2DExt(this._width, this._height, this._filter, this._internalFormatArr[i], this._formatArr[i], this._typeArr[i]);
|
|
153
153
|
|
|
154
154
|
let att_i = gl[this._attachmentArr[i]];
|
package/src/og/webgl/Handler.js
CHANGED
|
@@ -1138,7 +1138,7 @@ class Handler {
|
|
|
1138
1138
|
// const data = new DataView(xhr.response);
|
|
1139
1139
|
// const array =
|
|
1140
1140
|
// new Float32Array(data.byteLength / Float32Array.BYTES_PER_ELEMENT);
|
|
1141
|
-
// for (
|
|
1141
|
+
// for (let i = 0; i < array.length; ++i) {
|
|
1142
1142
|
// array[i] = data.getFloat32(i * Float32Array.BYTES_PER_ELEMENT, true);
|
|
1143
1143
|
// }
|
|
1144
1144
|
// callback(array);
|
|
@@ -88,7 +88,7 @@ export class Multisample {
|
|
|
88
88
|
destroy() {
|
|
89
89
|
var gl = this.handler.gl;
|
|
90
90
|
|
|
91
|
-
for (
|
|
91
|
+
for (let i = 0; i < this.renderbuffers.length; i++) {
|
|
92
92
|
gl.deleteRenderbuffer(this.renderbuffers[i]);
|
|
93
93
|
}
|
|
94
94
|
this.renderbuffers = new Array(this._size);
|
|
@@ -116,7 +116,7 @@ export class Multisample {
|
|
|
116
116
|
gl.bindFramebuffer(gl.FRAMEBUFFER, this._fbo);
|
|
117
117
|
|
|
118
118
|
let colorAttachments = [];
|
|
119
|
-
for (
|
|
119
|
+
for (let i = 0; i < this.renderbuffers.length; i++) {
|
|
120
120
|
let rb = gl.createRenderbuffer();
|
|
121
121
|
gl.bindRenderbuffer(gl.RENDERBUFFER, rb);
|
|
122
122
|
|
package/src/og/webgl/Program.js
CHANGED
|
@@ -154,7 +154,7 @@ class Program {
|
|
|
154
154
|
*/
|
|
155
155
|
set(material) {
|
|
156
156
|
this._textureID = 0;
|
|
157
|
-
for (
|
|
157
|
+
for (let i in material) {
|
|
158
158
|
this._variables[i].value = material[i];
|
|
159
159
|
this._variables[i]._callback(this, this._variables[i]);
|
|
160
160
|
}
|
|
@@ -167,7 +167,7 @@ class Program {
|
|
|
167
167
|
apply() {
|
|
168
168
|
this._textureID = 0;
|
|
169
169
|
var v = this._variables;
|
|
170
|
-
for (
|
|
170
|
+
for (let i in v) {
|
|
171
171
|
v[i]._callback(this, v[i]);
|
|
172
172
|
}
|
|
173
173
|
}
|
|
@@ -318,7 +318,7 @@ class Program {
|
|
|
318
318
|
|
|
319
319
|
this.use();
|
|
320
320
|
|
|
321
|
-
for (
|
|
321
|
+
for (let a in this._attributes) {
|
|
322
322
|
//this.attributes[a]._name = a;
|
|
323
323
|
this._variables[a] = this._attributes[a];
|
|
324
324
|
|
|
@@ -371,7 +371,7 @@ class Program {
|
|
|
371
371
|
this.attributes[a] = this._p[a];
|
|
372
372
|
}
|
|
373
373
|
|
|
374
|
-
for (
|
|
374
|
+
for (let u in this._uniforms) {
|
|
375
375
|
//this.uniforms[u]._name = u;
|
|
376
376
|
|
|
377
377
|
if (typeof this._uniforms[u].type === "string") {
|
package/types/ImageCanvas.d.ts
CHANGED
|
@@ -92,7 +92,7 @@ export class Ellipsoid {
|
|
|
92
92
|
* @param {Number} height - Height.
|
|
93
93
|
* @returns {Vec3} -
|
|
94
94
|
*/
|
|
95
|
-
public geodeticToCartesian(lon: number, lat: number, height
|
|
95
|
+
public geodeticToCartesian(lon: number, lat: number, height: number, res: any): Vec3;
|
|
96
96
|
/**
|
|
97
97
|
* Gets Wgs84 geodetic coordinates from cartesian ECEF.
|
|
98
98
|
* @public
|
|
@@ -155,6 +155,7 @@ export class Ellipsoid {
|
|
|
155
155
|
* @returns {Vec3} -
|
|
156
156
|
*/
|
|
157
157
|
public hitRay(origin: Vec3, direction: Vec3): Vec3;
|
|
158
|
+
getNorthFrameRotation(cartesian: any): Quat;
|
|
158
159
|
/**
|
|
159
160
|
* @todo this is not precise function, needs to be replaced or removed
|
|
160
161
|
* @param lonLat1
|
|
@@ -166,3 +167,4 @@ export class Ellipsoid {
|
|
|
166
167
|
}
|
|
167
168
|
import { Vec3 } from "../math/Vec3.js";
|
|
168
169
|
import { LonLat } from "../LonLat.js";
|
|
170
|
+
import { Quat } from "../math/Quat.js";
|
|
@@ -112,7 +112,6 @@ export class GeoObject {
|
|
|
112
112
|
*/
|
|
113
113
|
public setPickingColor3v(color: og.Vec3): void;
|
|
114
114
|
updateDirection(): void;
|
|
115
|
-
_qNorthFrame:
|
|
115
|
+
_qNorthFrame: any;
|
|
116
116
|
}
|
|
117
117
|
import { Vec3 } from "../math/index.js";
|
|
118
|
-
import { Quat } from "../math/index.js";
|
package/types/math/Vec3.d.ts
CHANGED
package/types/scene/Planet.d.ts
CHANGED
|
@@ -16,7 +16,6 @@
|
|
|
16
16
|
* @fires og.scene.Planet#geoimageadd
|
|
17
17
|
*/
|
|
18
18
|
export class Planet extends RenderNode {
|
|
19
|
-
static getBearingNorthRotationQuat(cartesian: any): Quat;
|
|
20
19
|
constructor(options?: {});
|
|
21
20
|
_cameraFrustums: any;
|
|
22
21
|
/**
|
|
@@ -260,6 +259,7 @@ export class Planet extends RenderNode {
|
|
|
260
259
|
_renderScreenNodesPASS: () => void;
|
|
261
260
|
_atmosphereEnabled: any;
|
|
262
261
|
_atmosphereMaxMinOpacity: Float32Array;
|
|
262
|
+
getNorthFrameRotation(cartesian: any): any;
|
|
263
263
|
set atmosphereMaxOpacity(arg: number);
|
|
264
264
|
get atmosphereMaxOpacity(): number;
|
|
265
265
|
set atmosphereMinOpacity(arg: number);
|
|
@@ -593,4 +593,3 @@ import { PlainSegmentWorker } from "../utils/PlainSegmentWorker.js";
|
|
|
593
593
|
import { Loader } from "../utils/Loader.js";
|
|
594
594
|
import { Key } from "../Lock.js";
|
|
595
595
|
import { LonLat } from "../LonLat.js";
|
|
596
|
-
import { Quat } from "../math/index.js";
|