@aibee/crc-bmap 0.1.9 → 0.1.11

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/lib/bmap.esm.js CHANGED
@@ -1083,17 +1083,17 @@ function moveOnRoute(startPoint, endPoint, distance) {
1083
1083
  const newY = startY + (endY - startY) * ratio;
1084
1084
  return [newX, newY];
1085
1085
  }
1086
- var PathDirection = /* @__PURE__ */ ((PathDirection4) => {
1087
- PathDirection4["START"] = "start";
1088
- PathDirection4["END"] = "end";
1089
- PathDirection4["FRONT"] = "front";
1090
- PathDirection4["RIGHT"] = "right";
1091
- PathDirection4["LEFT"] = "left";
1092
- PathDirection4["RIGHT_FRONT"] = "right_front";
1093
- PathDirection4["LEFT_FRONT"] = "left_front";
1094
- PathDirection4["RIGHT_BACK"] = "right_back";
1095
- PathDirection4["LEFT_BACK"] = "left_back";
1096
- return PathDirection4;
1086
+ var PathDirection = /* @__PURE__ */ ((PathDirection3) => {
1087
+ PathDirection3["START"] = "start";
1088
+ PathDirection3["END"] = "end";
1089
+ PathDirection3["FRONT"] = "front";
1090
+ PathDirection3["RIGHT"] = "right";
1091
+ PathDirection3["LEFT"] = "left";
1092
+ PathDirection3["RIGHT_FRONT"] = "right_front";
1093
+ PathDirection3["LEFT_FRONT"] = "left_front";
1094
+ PathDirection3["RIGHT_BACK"] = "right_back";
1095
+ PathDirection3["LEFT_BACK"] = "left_back";
1096
+ return PathDirection3;
1097
1097
  })(PathDirection || {});
1098
1098
  function calc_direction(p0, p1, p2) {
1099
1099
  const angle = calc_angle(p0, p1, p2);
@@ -5413,7 +5413,7 @@ var Poi2 = class extends Object3D14 {
5413
5413
  }
5414
5414
  async initIcon() {
5415
5415
  if (this.options.icon) {
5416
- this._initIconPromise = new Promise(async (resolve) => {
5416
+ return this._initIconPromise = new Promise(async (resolve) => {
5417
5417
  const texture = await ImgTextureFactory.getTextureByUrl(this.options.icon);
5418
5418
  const spriteIcon = new Sprite(
5419
5419
  new SpriteMaterial({
@@ -10036,6 +10036,7 @@ var PositioningSystem = class {
10036
10036
  if (data_type === "acceleration" /* ACCELERATION */) {
10037
10037
  const acc = data;
10038
10038
  const step_length = this.pdr.getStepLength(time, acc);
10039
+ console.log("SENSOR_TYPE.ACCELERATION", step_length);
10039
10040
  if (step_length !== 0) {
10040
10041
  this.particleFilter.motionModelStepLength(
10041
10042
  step_length,
@@ -10066,7 +10067,7 @@ var PositioningSystem = class {
10066
10067
  this.particleFilter.motionModelCompassYaw(data, time);
10067
10068
  this.particleFilter.setLastCompassTime(time);
10068
10069
  }
10069
- if (this.last_pos_time && time - this.last_pos_time > 0.5) {
10070
+ if (this.last_pos_time && time - this.last_pos_time > 500) {
10070
10071
  this.position_count += 1;
10071
10072
  success = true;
10072
10073
  }
@@ -10174,6 +10175,7 @@ var PdrPosition = class extends EventDispatcher14 {
10174
10175
  this.sensor.start();
10175
10176
  this.sensor.addEventListener("add-data-item", ({ item }) => {
10176
10177
  const [success, x, y] = this.pdr.pfFusionPDRiBeacon(item);
10178
+ console.log(item, success, x, y);
10177
10179
  if (success) {
10178
10180
  this.dispatchEvent({ type: "position", x, y });
10179
10181
  }