@viamrobotics/motion-tools 1.12.1 → 1.12.2

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.
@@ -1,5 +1,5 @@
1
1
  import type { Snapshot } from '../../buf/draw/v1/snapshot_pb';
2
- import type { SuccessMessage } from '../../loaders/pcd/worker';
2
+ import type { SuccessMessage } from '../../loaders/pcd/messages';
3
3
  import type { BufferGeometry } from 'three';
4
4
  interface FileDropSuccess {
5
5
  success: true;
@@ -54,6 +54,12 @@
54
54
  }
55
55
  }
56
56
 
57
+ $effect(() => {
58
+ if (isLassoMode) {
59
+ settings.current.cameraMode = 'orthographic'
60
+ }
61
+ })
62
+
57
63
  $effect(() => {
58
64
  if (enabled) {
59
65
  settings.current.interactionMode = 'lasso'
@@ -1,2 +1,2 @@
1
- import type { SuccessMessage } from './worker';
1
+ import type { SuccessMessage } from './messages';
2
2
  export declare const parsePcdInWorker: (data: Uint8Array<ArrayBufferLike>) => Promise<SuccessMessage>;
@@ -1,4 +1,7 @@
1
- const worker = new Worker(new URL('./worker', import.meta.url), { type: 'module' });
1
+ import { workerCode } from './worker.inline';
2
+ const blob = new Blob([workerCode], { type: 'text/javascript' });
3
+ const url = URL.createObjectURL(blob);
4
+ const worker = new Worker(url);
2
5
  let requestId = 0;
3
6
  const pending = new Map();
4
7
  worker.addEventListener('message', (event) => {
@@ -0,0 +1,9 @@
1
+ export interface SuccessMessage {
2
+ id: number;
3
+ positions: Float32Array<ArrayBuffer>;
4
+ colors: Uint8Array<ArrayBuffer> | null;
5
+ }
6
+ export type Message = SuccessMessage | {
7
+ id: number;
8
+ error: string;
9
+ };
@@ -0,0 +1 @@
1
+ export {};
@@ -1,9 +1 @@
1
- export interface SuccessMessage {
2
- id: number;
3
- positions: Float32Array<ArrayBuffer>;
4
- colors: Uint8Array<ArrayBuffer> | null;
5
- }
6
- export type Message = SuccessMessage | {
7
- id: number;
8
- error: string;
9
- };
1
+ export {};