@luxonis/visualizer-protobuf 2.66.8 → 2.66.9

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.
Files changed (51) hide show
  1. package/dist/{depth-B7VOdK0y.js → depth-BGin0LSZ.js} +15 -452
  2. package/dist/depth-coloring.worker-YB2xphzJ.js +84 -0
  3. package/dist/{deserialization.worker-GXEWF6Ah.js → deserialization.worker-CgJJ0wn7.js} +89 -6
  4. package/dist/{index-BxuDWAWd.js → index-0xvyd9_r.js} +5 -5
  5. package/dist/{index-UAnOeVfw.js → index-AReJXz0b.js} +5 -5
  6. package/dist/{index-BLaE8vrb.js → index-BJslJPfz.js} +5 -5
  7. package/dist/{index-CPFO1Uvg.js → index-BWnke17_.js} +5 -5
  8. package/dist/{index-BYTVvykH.js → index-BZBENqR3.js} +5 -5
  9. package/dist/{index-CfLr9xrN.js → index-Bb6PcuFb.js} +5 -5
  10. package/dist/{index-CUuB2DeV.js → index-C41fk9FJ.js} +24 -23
  11. package/dist/{index-BCNQjEez.js → index-CAKA0YwJ.js} +7 -6
  12. package/dist/{index-DgYMoCLL.js → index-CRGrBIhH.js} +5 -5
  13. package/dist/{index-D1xmWApp.js → index-Clq69yV3.js} +33 -102
  14. package/dist/index-CmrbNJoW.js +405 -0
  15. package/dist/{index-C05AhKNz.js → index-Ct1D6II_.js} +5 -5
  16. package/dist/{index-BRSoQ8_Y.js → index-CyYbEgIe.js} +5 -5
  17. package/dist/{index-BkruEbO5.js → index-Cyl0afzE.js} +5 -5
  18. package/dist/{index-DE5zu3LB.js → index-D-mDIWK_.js} +5 -5
  19. package/dist/{index-BqkFobGp.js → index-DkTZCwWX.js} +5 -5
  20. package/dist/{index-DyM7JMrj.js → index-DnFWiYGu.js} +5 -5
  21. package/dist/{index-DxPt_hhw.js → index-DuwwCf0Y.js} +5 -5
  22. package/dist/{index-OV08AjM2.js → index-JFZDeEB8.js} +5 -5
  23. package/dist/{index-DIY7ddlQ.js → index-nO2O7il5.js} +5 -5
  24. package/dist/index.js +2 -2
  25. package/dist/lib/src/connection/communicator.js.map +1 -1
  26. package/dist/lib/src/messaging/deserialization/video/depth-coloring.worker.d.ts +6 -0
  27. package/dist/lib/src/messaging/deserialization/video/depth-coloring.worker.d.ts.map +1 -0
  28. package/dist/lib/src/messaging/deserialization/video/depth-coloring.worker.js +89 -0
  29. package/dist/lib/src/messaging/deserialization/video/depth-coloring.worker.js.map +1 -0
  30. package/dist/lib/src/messaging/deserialization/video/depth-to-pointcloud.d.ts +14 -0
  31. package/dist/lib/src/messaging/deserialization/video/depth-to-pointcloud.d.ts.map +1 -0
  32. package/dist/lib/src/messaging/deserialization/video/depth-to-pointcloud.js +38 -0
  33. package/dist/lib/src/messaging/deserialization/video/depth-to-pointcloud.js.map +1 -0
  34. package/dist/lib/src/messaging/deserialization/video/depth.d.ts +8 -7
  35. package/dist/lib/src/messaging/deserialization/video/depth.d.ts.map +1 -1
  36. package/dist/lib/src/messaging/deserialization/video/depth.js +12 -22
  37. package/dist/lib/src/messaging/deserialization/video/depth.js.map +1 -1
  38. package/dist/lib/src/messaging/deserialization.worker.d.ts +3 -1
  39. package/dist/lib/src/messaging/deserialization.worker.d.ts.map +1 -1
  40. package/dist/lib/src/messaging/deserialization.worker.js +7 -4
  41. package/dist/lib/src/messaging/deserialization.worker.js.map +1 -1
  42. package/dist/lib/src/messaging/message-handler.d.ts.map +1 -1
  43. package/dist/lib/src/messaging/message-handler.js +1 -1
  44. package/dist/lib/src/messaging/message-handler.js.map +1 -1
  45. package/dist/packages/studio-base/src/panels/ThreeDeeRender/renderables/ImageMode/MessageHandler.d.ts +0 -1
  46. package/dist/packages/studio-base/src/panels/ThreeDeeRender/renderables/ImageMode/MessageHandler.d.ts.map +1 -1
  47. package/dist/packages/studio-base/src/panels/ThreeDeeRender/renderables/ImageMode/MessageHandler.js +28 -95
  48. package/dist/packages/studio-base/src/panels/ThreeDeeRender/renderables/ImageMode/MessageHandler.js.map +1 -1
  49. package/dist/packages/studio-base/src/panels/ThreeDeeRender/renderables/ImageMode/annotations/ImageAnnotations.d.ts.map +1 -1
  50. package/dist/packages/studio-base/src/panels/ThreeDeeRender/renderables/ImageMode/annotations/ImageAnnotations.js.map +1 -1
  51. package/package.json +1 -1
@@ -1,7 +1,8 @@
1
- import { c as commonjsGlobal, g as getDefaultExportFromCjs, d as getAugmentedNamespace, T as Type } from './protobuf-BFCtaU7c.js';
1
+ import { w as wrap } from './comlink-DHMAu6X7.js';
2
2
  import { useContext, useRef, useLayoutEffect, createContext, useReducer, useState, useCallback } from 'react';
3
3
  import 'zustand';
4
4
  import { isParent, getLeaves, createRemoveUpdate, updateTree, getNodeAtPath } from 'react-mosaic-component';
5
+ import { c as commonjsGlobal, g as getDefaultExportFromCjs, T as Type } from './protobuf-BFCtaU7c.js';
5
6
  import { useTheme } from '@mui/material';
6
7
  import { k as isObjectLike, l as baseGetTag, S as Symbol$1, i as isArray, m as getNative, r as root, n as overArg, g as isPrototype, c as isArrayLike, p as arrayLikeKeys, M as MapCache, f as isArguments, t as toSource, q as Map$1, u as eq, U as Uint8Array, d as isBuffer, v as Stack, e as isTypedArray, h as isObject, w as isLength, j as isIndex, x as identity, y as baseFor, b as baseRest, a as isArrayLikeObject } from './isArrayLikeObject-Bytw9p-q.js';
7
8
 
@@ -4084,407 +4085,6 @@ var tslib_es6$1 = /*#__PURE__*/Object.freeze({
4084
4085
  default: tslib_es6
4085
4086
  });
4086
4087
 
4087
- var typescript = {};
4088
-
4089
- var require$$0 = /*@__PURE__*/getAugmentedNamespace(tslib_es6$1);
4090
-
4091
- var ArrowPrimitive = /*#__PURE__*/Object.freeze({
4092
- __proto__: null
4093
- });
4094
-
4095
- var require$$1 = /*@__PURE__*/getAugmentedNamespace(ArrowPrimitive);
4096
-
4097
- var CameraCalibration = /*#__PURE__*/Object.freeze({
4098
- __proto__: null
4099
- });
4100
-
4101
- var require$$2 = /*@__PURE__*/getAugmentedNamespace(CameraCalibration);
4102
-
4103
- var CircleAnnotation = /*#__PURE__*/Object.freeze({
4104
- __proto__: null
4105
- });
4106
-
4107
- var require$$3 = /*@__PURE__*/getAugmentedNamespace(CircleAnnotation);
4108
-
4109
- var Color = /*#__PURE__*/Object.freeze({
4110
- __proto__: null
4111
- });
4112
-
4113
- var require$$4 = /*@__PURE__*/getAugmentedNamespace(Color);
4114
-
4115
- var CompressedImage = /*#__PURE__*/Object.freeze({
4116
- __proto__: null
4117
- });
4118
-
4119
- var require$$5 = /*@__PURE__*/getAugmentedNamespace(CompressedImage);
4120
-
4121
- var CompressedVideo = /*#__PURE__*/Object.freeze({
4122
- __proto__: null
4123
- });
4124
-
4125
- var require$$6 = /*@__PURE__*/getAugmentedNamespace(CompressedVideo);
4126
-
4127
- var CubePrimitive = /*#__PURE__*/Object.freeze({
4128
- __proto__: null
4129
- });
4130
-
4131
- var require$$7 = /*@__PURE__*/getAugmentedNamespace(CubePrimitive);
4132
-
4133
- var CylinderPrimitive = /*#__PURE__*/Object.freeze({
4134
- __proto__: null
4135
- });
4136
-
4137
- var require$$8 = /*@__PURE__*/getAugmentedNamespace(CylinderPrimitive);
4138
-
4139
- var FrameTransform = /*#__PURE__*/Object.freeze({
4140
- __proto__: null
4141
- });
4142
-
4143
- var require$$9 = /*@__PURE__*/getAugmentedNamespace(FrameTransform);
4144
-
4145
- var FrameTransforms = /*#__PURE__*/Object.freeze({
4146
- __proto__: null
4147
- });
4148
-
4149
- var require$$10 = /*@__PURE__*/getAugmentedNamespace(FrameTransforms);
4150
-
4151
- var GeoJSON = /*#__PURE__*/Object.freeze({
4152
- __proto__: null
4153
- });
4154
-
4155
- var require$$11 = /*@__PURE__*/getAugmentedNamespace(GeoJSON);
4156
-
4157
- var Grid = /*#__PURE__*/Object.freeze({
4158
- __proto__: null
4159
- });
4160
-
4161
- var require$$12 = /*@__PURE__*/getAugmentedNamespace(Grid);
4162
-
4163
- var ImageAnnotations = /*#__PURE__*/Object.freeze({
4164
- __proto__: null
4165
- });
4166
-
4167
- var require$$13 = /*@__PURE__*/getAugmentedNamespace(ImageAnnotations);
4168
-
4169
- var KeyValuePair = /*#__PURE__*/Object.freeze({
4170
- __proto__: null
4171
- });
4172
-
4173
- var require$$14 = /*@__PURE__*/getAugmentedNamespace(KeyValuePair);
4174
-
4175
- var LaserScan = /*#__PURE__*/Object.freeze({
4176
- __proto__: null
4177
- });
4178
-
4179
- var require$$15 = /*@__PURE__*/getAugmentedNamespace(LaserScan);
4180
-
4181
- var LinePrimitive = /*#__PURE__*/Object.freeze({
4182
- __proto__: null
4183
- });
4184
-
4185
- var require$$16 = /*@__PURE__*/getAugmentedNamespace(LinePrimitive);
4186
-
4187
- // Generated by https://github.com/foxglove/schemas
4188
- // Options: {}
4189
-
4190
- /** An enumeration indicating how input points should be interpreted to create lines */
4191
- let LineType = /*#__PURE__*/function (LineType) {
4192
- LineType[LineType["LINE_STRIP"] = 0] = "LINE_STRIP";
4193
- LineType[LineType["LINE_LOOP"] = 1] = "LINE_LOOP";
4194
- LineType[LineType["LINE_LIST"] = 2] = "LINE_LIST";
4195
- return LineType;
4196
- }({});
4197
-
4198
- var LineType$1 = /*#__PURE__*/Object.freeze({
4199
- __proto__: null,
4200
- LineType: LineType
4201
- });
4202
-
4203
- var require$$17 = /*@__PURE__*/getAugmentedNamespace(LineType$1);
4204
-
4205
- var LocationFix = /*#__PURE__*/Object.freeze({
4206
- __proto__: null
4207
- });
4208
-
4209
- var require$$18 = /*@__PURE__*/getAugmentedNamespace(LocationFix);
4210
-
4211
- var Log = /*#__PURE__*/Object.freeze({
4212
- __proto__: null
4213
- });
4214
-
4215
- var require$$19 = /*@__PURE__*/getAugmentedNamespace(Log);
4216
-
4217
- // Generated by https://github.com/foxglove/schemas
4218
- // Options: {}
4219
-
4220
- /** Log level */
4221
- let LogLevel = /*#__PURE__*/function (LogLevel) {
4222
- LogLevel[LogLevel["UNKNOWN"] = 0] = "UNKNOWN";
4223
- LogLevel[LogLevel["DEBUG"] = 1] = "DEBUG";
4224
- LogLevel[LogLevel["INFO"] = 2] = "INFO";
4225
- LogLevel[LogLevel["WARNING"] = 3] = "WARNING";
4226
- LogLevel[LogLevel["ERROR"] = 4] = "ERROR";
4227
- LogLevel[LogLevel["FATAL"] = 5] = "FATAL";
4228
- return LogLevel;
4229
- }({});
4230
-
4231
- var LogLevel$1 = /*#__PURE__*/Object.freeze({
4232
- __proto__: null,
4233
- LogLevel: LogLevel
4234
- });
4235
-
4236
- var require$$20 = /*@__PURE__*/getAugmentedNamespace(LogLevel$1);
4237
-
4238
- var ModelPrimitive = /*#__PURE__*/Object.freeze({
4239
- __proto__: null
4240
- });
4241
-
4242
- var require$$21 = /*@__PURE__*/getAugmentedNamespace(ModelPrimitive);
4243
-
4244
- // Generated by https://github.com/foxglove/schemas
4245
- // Options: {}
4246
-
4247
- /** Numeric type */
4248
- let NumericType = /*#__PURE__*/function (NumericType) {
4249
- NumericType[NumericType["UNKNOWN"] = 0] = "UNKNOWN";
4250
- NumericType[NumericType["UINT8"] = 1] = "UINT8";
4251
- NumericType[NumericType["INT8"] = 2] = "INT8";
4252
- NumericType[NumericType["UINT16"] = 3] = "UINT16";
4253
- NumericType[NumericType["INT16"] = 4] = "INT16";
4254
- NumericType[NumericType["UINT32"] = 5] = "UINT32";
4255
- NumericType[NumericType["INT32"] = 6] = "INT32";
4256
- NumericType[NumericType["FLOAT32"] = 7] = "FLOAT32";
4257
- NumericType[NumericType["FLOAT64"] = 8] = "FLOAT64";
4258
- return NumericType;
4259
- }({});
4260
-
4261
- var NumericType$1 = /*#__PURE__*/Object.freeze({
4262
- __proto__: null,
4263
- NumericType: NumericType
4264
- });
4265
-
4266
- var require$$22 = /*@__PURE__*/getAugmentedNamespace(NumericType$1);
4267
-
4268
- var PackedElementField = /*#__PURE__*/Object.freeze({
4269
- __proto__: null
4270
- });
4271
-
4272
- var require$$23 = /*@__PURE__*/getAugmentedNamespace(PackedElementField);
4273
-
4274
- var Point2 = /*#__PURE__*/Object.freeze({
4275
- __proto__: null
4276
- });
4277
-
4278
- var require$$24 = /*@__PURE__*/getAugmentedNamespace(Point2);
4279
-
4280
- var Point3 = /*#__PURE__*/Object.freeze({
4281
- __proto__: null
4282
- });
4283
-
4284
- var require$$25 = /*@__PURE__*/getAugmentedNamespace(Point3);
4285
-
4286
- var PointCloud = /*#__PURE__*/Object.freeze({
4287
- __proto__: null
4288
- });
4289
-
4290
- var require$$26 = /*@__PURE__*/getAugmentedNamespace(PointCloud);
4291
-
4292
- var PointsAnnotation = /*#__PURE__*/Object.freeze({
4293
- __proto__: null
4294
- });
4295
-
4296
- var require$$27 = /*@__PURE__*/getAugmentedNamespace(PointsAnnotation);
4297
-
4298
- // Generated by https://github.com/foxglove/schemas
4299
- // Options: {}
4300
-
4301
- /** Type of points annotation */
4302
- let PointsAnnotationType = /*#__PURE__*/function (PointsAnnotationType) {
4303
- PointsAnnotationType[PointsAnnotationType["UNKNOWN"] = 0] = "UNKNOWN";
4304
- PointsAnnotationType[PointsAnnotationType["POINTS"] = 1] = "POINTS";
4305
- PointsAnnotationType[PointsAnnotationType["LINE_LOOP"] = 2] = "LINE_LOOP";
4306
- PointsAnnotationType[PointsAnnotationType["LINE_STRIP"] = 3] = "LINE_STRIP";
4307
- PointsAnnotationType[PointsAnnotationType["LINE_LIST"] = 4] = "LINE_LIST";
4308
- return PointsAnnotationType;
4309
- }({});
4310
-
4311
- var PointsAnnotationType$1 = /*#__PURE__*/Object.freeze({
4312
- __proto__: null,
4313
- PointsAnnotationType: PointsAnnotationType
4314
- });
4315
-
4316
- var require$$28 = /*@__PURE__*/getAugmentedNamespace(PointsAnnotationType$1);
4317
-
4318
- var Pose = /*#__PURE__*/Object.freeze({
4319
- __proto__: null
4320
- });
4321
-
4322
- var require$$29 = /*@__PURE__*/getAugmentedNamespace(Pose);
4323
-
4324
- var PoseInFrame = /*#__PURE__*/Object.freeze({
4325
- __proto__: null
4326
- });
4327
-
4328
- var require$$30 = /*@__PURE__*/getAugmentedNamespace(PoseInFrame);
4329
-
4330
- var PosesInFrame = /*#__PURE__*/Object.freeze({
4331
- __proto__: null
4332
- });
4333
-
4334
- var require$$31 = /*@__PURE__*/getAugmentedNamespace(PosesInFrame);
4335
-
4336
- // Generated by https://github.com/foxglove/schemas
4337
- // Options: {}
4338
-
4339
- /** Type of position covariance */
4340
- let PositionCovarianceType = /*#__PURE__*/function (PositionCovarianceType) {
4341
- PositionCovarianceType[PositionCovarianceType["UNKNOWN"] = 0] = "UNKNOWN";
4342
- PositionCovarianceType[PositionCovarianceType["APPROXIMATED"] = 1] = "APPROXIMATED";
4343
- PositionCovarianceType[PositionCovarianceType["DIAGONAL_KNOWN"] = 2] = "DIAGONAL_KNOWN";
4344
- PositionCovarianceType[PositionCovarianceType["KNOWN"] = 3] = "KNOWN";
4345
- return PositionCovarianceType;
4346
- }({});
4347
-
4348
- var PositionCovarianceType$1 = /*#__PURE__*/Object.freeze({
4349
- __proto__: null,
4350
- PositionCovarianceType: PositionCovarianceType
4351
- });
4352
-
4353
- var require$$32 = /*@__PURE__*/getAugmentedNamespace(PositionCovarianceType$1);
4354
-
4355
- var Quaternion = /*#__PURE__*/Object.freeze({
4356
- __proto__: null
4357
- });
4358
-
4359
- var require$$33 = /*@__PURE__*/getAugmentedNamespace(Quaternion);
4360
-
4361
- var RawImage = /*#__PURE__*/Object.freeze({
4362
- __proto__: null
4363
- });
4364
-
4365
- var require$$34 = /*@__PURE__*/getAugmentedNamespace(RawImage);
4366
-
4367
- var SceneEntity = /*#__PURE__*/Object.freeze({
4368
- __proto__: null
4369
- });
4370
-
4371
- var require$$35 = /*@__PURE__*/getAugmentedNamespace(SceneEntity);
4372
-
4373
- var SceneEntityDeletion = /*#__PURE__*/Object.freeze({
4374
- __proto__: null
4375
- });
4376
-
4377
- var require$$36 = /*@__PURE__*/getAugmentedNamespace(SceneEntityDeletion);
4378
-
4379
- // Generated by https://github.com/foxglove/schemas
4380
- // Options: {}
4381
-
4382
- /** An enumeration indicating which entities should match a SceneEntityDeletion command */
4383
- let SceneEntityDeletionType = /*#__PURE__*/function (SceneEntityDeletionType) {
4384
- SceneEntityDeletionType[SceneEntityDeletionType["MATCHING_ID"] = 0] = "MATCHING_ID";
4385
- SceneEntityDeletionType[SceneEntityDeletionType["ALL"] = 1] = "ALL";
4386
- return SceneEntityDeletionType;
4387
- }({});
4388
-
4389
- var SceneEntityDeletionType$1 = /*#__PURE__*/Object.freeze({
4390
- __proto__: null,
4391
- SceneEntityDeletionType: SceneEntityDeletionType
4392
- });
4393
-
4394
- var require$$37 = /*@__PURE__*/getAugmentedNamespace(SceneEntityDeletionType$1);
4395
-
4396
- var SceneUpdate = /*#__PURE__*/Object.freeze({
4397
- __proto__: null
4398
- });
4399
-
4400
- var require$$38 = /*@__PURE__*/getAugmentedNamespace(SceneUpdate);
4401
-
4402
- var SpherePrimitive = /*#__PURE__*/Object.freeze({
4403
- __proto__: null
4404
- });
4405
-
4406
- var require$$39 = /*@__PURE__*/getAugmentedNamespace(SpherePrimitive);
4407
-
4408
- var TextAnnotation = /*#__PURE__*/Object.freeze({
4409
- __proto__: null
4410
- });
4411
-
4412
- var require$$40 = /*@__PURE__*/getAugmentedNamespace(TextAnnotation);
4413
-
4414
- var TextPrimitive = /*#__PURE__*/Object.freeze({
4415
- __proto__: null
4416
- });
4417
-
4418
- var require$$41 = /*@__PURE__*/getAugmentedNamespace(TextPrimitive);
4419
-
4420
- var TriangleListPrimitive = /*#__PURE__*/Object.freeze({
4421
- __proto__: null
4422
- });
4423
-
4424
- var require$$42 = /*@__PURE__*/getAugmentedNamespace(TriangleListPrimitive);
4425
-
4426
- var Vector2 = /*#__PURE__*/Object.freeze({
4427
- __proto__: null
4428
- });
4429
-
4430
- var require$$43 = /*@__PURE__*/getAugmentedNamespace(Vector2);
4431
-
4432
- var Vector3 = /*#__PURE__*/Object.freeze({
4433
- __proto__: null
4434
- });
4435
-
4436
- var require$$44 = /*@__PURE__*/getAugmentedNamespace(Vector3);
4437
-
4438
- (function (exports) {
4439
- Object.defineProperty(exports, "__esModule", { value: true });
4440
- const tslib_1 = require$$0;
4441
- tslib_1.__exportStar(require$$1, exports);
4442
- tslib_1.__exportStar(require$$2, exports);
4443
- tslib_1.__exportStar(require$$3, exports);
4444
- tslib_1.__exportStar(require$$4, exports);
4445
- tslib_1.__exportStar(require$$5, exports);
4446
- tslib_1.__exportStar(require$$6, exports);
4447
- tslib_1.__exportStar(require$$7, exports);
4448
- tslib_1.__exportStar(require$$8, exports);
4449
- tslib_1.__exportStar(require$$9, exports);
4450
- tslib_1.__exportStar(require$$10, exports);
4451
- tslib_1.__exportStar(require$$11, exports);
4452
- tslib_1.__exportStar(require$$12, exports);
4453
- tslib_1.__exportStar(require$$13, exports);
4454
- tslib_1.__exportStar(require$$14, exports);
4455
- tslib_1.__exportStar(require$$15, exports);
4456
- tslib_1.__exportStar(require$$16, exports);
4457
- tslib_1.__exportStar(require$$17, exports);
4458
- tslib_1.__exportStar(require$$18, exports);
4459
- tslib_1.__exportStar(require$$19, exports);
4460
- tslib_1.__exportStar(require$$20, exports);
4461
- tslib_1.__exportStar(require$$21, exports);
4462
- tslib_1.__exportStar(require$$22, exports);
4463
- tslib_1.__exportStar(require$$23, exports);
4464
- tslib_1.__exportStar(require$$24, exports);
4465
- tslib_1.__exportStar(require$$25, exports);
4466
- tslib_1.__exportStar(require$$26, exports);
4467
- tslib_1.__exportStar(require$$27, exports);
4468
- tslib_1.__exportStar(require$$28, exports);
4469
- tslib_1.__exportStar(require$$29, exports);
4470
- tslib_1.__exportStar(require$$30, exports);
4471
- tslib_1.__exportStar(require$$31, exports);
4472
- tslib_1.__exportStar(require$$32, exports);
4473
- tslib_1.__exportStar(require$$33, exports);
4474
- tslib_1.__exportStar(require$$34, exports);
4475
- tslib_1.__exportStar(require$$35, exports);
4476
- tslib_1.__exportStar(require$$36, exports);
4477
- tslib_1.__exportStar(require$$37, exports);
4478
- tslib_1.__exportStar(require$$38, exports);
4479
- tslib_1.__exportStar(require$$39, exports);
4480
- tslib_1.__exportStar(require$$40, exports);
4481
- tslib_1.__exportStar(require$$41, exports);
4482
- tslib_1.__exportStar(require$$42, exports);
4483
- tslib_1.__exportStar(require$$43, exports);
4484
- tslib_1.__exportStar(require$$44, exports);
4485
-
4486
- } (typescript));
4487
-
4488
4088
  // This Source Code Form is subject to the terms of the Mozilla Public
4489
4089
  // License, v2.0. If a copy of the MPL was not distributed with this
4490
4090
  // file, You can obtain one at http://mozilla.org/MPL/2.0/
@@ -4592,69 +4192,32 @@ function parseMessage(message) {
4592
4192
  async function deserializeDepthFrame({
4593
4193
  topic,
4594
4194
  message,
4595
- callback
4195
+ callback,
4196
+ maxSteroDepth
4596
4197
  }) {
4597
4198
  const {
4598
4199
  receiveTime,
4200
+ encoding,
4599
4201
  width,
4600
4202
  height
4601
4203
  } = parseMessage(message);
4204
+ const worker = wrap(new Worker(new URL("depth-coloring.worker-YB2xphzJ.js", import.meta.url)));
4205
+ const colorizedData = await worker.colorDepht(message, encoding, width, height, maxSteroDepth);
4602
4206
  const foxgloveMessage = {
4603
- timestamp: message.tsDevice ?? receiveTime,
4604
- frame_id: `pointcloud-${topic}-frame`,
4605
- point_stride: 16,
4606
- pose: {
4607
- position: {
4608
- x: 0,
4609
- y: 0,
4610
- z: 0
4611
- },
4612
- orientation: {
4613
- x: 0,
4614
- y: 0,
4615
- z: 1,
4616
- w: 0
4617
- }
4618
- },
4207
+ timestamp: receiveTime,
4208
+ frame_id: `depth-${topic}-frame`,
4619
4209
  width,
4620
4210
  height,
4621
- fields: [{
4622
- name: "x",
4623
- offset: 0,
4624
- type: typescript.NumericType.FLOAT32
4625
- }, {
4626
- name: "y",
4627
- offset: 4,
4628
- type: typescript.NumericType.FLOAT32
4629
- }, {
4630
- name: "z",
4631
- offset: 8,
4632
- type: typescript.NumericType.FLOAT32
4633
- }, {
4634
- name: "red",
4635
- offset: 12,
4636
- type: typescript.NumericType.UINT8
4637
- }, {
4638
- name: "green",
4639
- offset: 13,
4640
- type: typescript.NumericType.UINT8
4641
- }, {
4642
- name: "blue",
4643
- offset: 14,
4644
- type: typescript.NumericType.UINT8
4645
- }, {
4646
- name: "alpha",
4647
- offset: 15,
4648
- type: typescript.NumericType.UINT8
4649
- }],
4650
- data: message.data
4211
+ encoding: "rgb8",
4212
+ step: width * 3,
4213
+ data: colorizedData
4651
4214
  };
4652
4215
  callback({
4653
- topic,
4216
+ topic: topic === "Point Cloud" ? "Depth Stream" : topic,
4654
4217
  receiveTime,
4655
4218
  message: foxgloveMessage,
4656
4219
  sizeInBytes: estimateObjectSize(foxgloveMessage),
4657
- schemaName: "foxglove.PointCloud"
4220
+ schemaName: "foxglove.RawImage"
4658
4221
  });
4659
4222
  }
4660
4223
  function getDistanceFromDepthDataForOffset(depthData, width, height, xOffset, yOffset) {
@@ -4708,4 +4271,4 @@ function getDistanceFromDepthDataForOffset(depthData, width, height, xOffset, yO
4708
4271
  return sum / count;
4709
4272
  }
4710
4273
 
4711
- export { toString as $, AppError as A, getAllPanelIds as B, getConfigsForNestedPanelsInsideTab as C, reorderTabWithinTabPanel as D, moveTabBetweenTabPanels as E, isTabPanelConfig as F, DEFAULT_TAB_PANEL_CONFIG as G, addPanelToTab as H, createAddUpdates as I, filterMap as J, uniq as K, Logger$1 as L, useShallowMemo as M, CurrentLayoutContext as N, MessageOrderTracker as O, AppConfigurationContext as P, __rest as Q, __spreadArray as R, getDistanceFromDepthDataForOffset as S, TAB_PANEL_TYPE as T, parseMessage as U, typescript as V, fromMillis as W, parsePixelFormat as X, deserializeDepthFrame as Y, isSymbol as Z, __assign as _, baseEach as a, keys as a0, getSymbols as a1, stubArray as a2, arrayPush as a3, baseGetAllKeys as a4, getAllKeys as a5, arrayMap as a6, baseUniq as a7, useMustNotChange as a8, useCurrentLayoutActions as a9, useCurrentLayoutSelector as aa, usePanelMosaicId as ab, useSelectedPanels as ac, PANEL_TITLE_CONFIG_KEY as ad, noop as ae, useAppConfiguration as af, useValueChangedDebugLog as ag, useJsonTreeTheme as ah, baseFlatten as b, baseIteratee as c, dist as d, estimateObjectSize as e, baseDifference as f, getTag as g, baseKeys as h, baseIsEqual as i, castPath as j, baseGet as k, hasIn as l, shallowequal$1 as m, getPanelIdsInsideTabPanels as n, getPanelTypeFromId as o, removePanelFromTabPanel as p, getPanelIdForType as q, reportError as r, sendNotification as s, toKey as t, useGuaranteedContext as u, getPathFromNode as v, updateTabPanelLayout as w, getSaveConfigsPayloadForAddedPanel as x, replaceAndRemovePanels as y, inlineTabPanelLayouts as z };
4274
+ export { keys as $, AppError as A, getAllPanelIds as B, getConfigsForNestedPanelsInsideTab as C, reorderTabWithinTabPanel as D, moveTabBetweenTabPanels as E, isTabPanelConfig as F, DEFAULT_TAB_PANEL_CONFIG as G, addPanelToTab as H, createAddUpdates as I, filterMap as J, uniq as K, Logger$1 as L, useShallowMemo as M, CurrentLayoutContext as N, MessageOrderTracker as O, AppConfigurationContext as P, __rest as Q, __spreadArray as R, getDistanceFromDepthDataForOffset as S, TAB_PANEL_TYPE as T, parseMessage as U, fromMillis as V, parsePixelFormat as W, deserializeDepthFrame as X, isSymbol as Y, toString as Z, __assign as _, baseEach as a, getSymbols as a0, stubArray as a1, arrayPush as a2, baseGetAllKeys as a3, getAllKeys as a4, arrayMap as a5, baseUniq as a6, useMustNotChange as a7, useCurrentLayoutActions as a8, useCurrentLayoutSelector as a9, usePanelMosaicId as aa, useSelectedPanels as ab, PANEL_TITLE_CONFIG_KEY as ac, noop as ad, useAppConfiguration as ae, useValueChangedDebugLog as af, useJsonTreeTheme as ag, tslib_es6$1 as ah, baseFlatten as b, baseIteratee as c, dist as d, estimateObjectSize as e, baseDifference as f, getTag as g, baseKeys as h, baseIsEqual as i, castPath as j, baseGet as k, hasIn as l, shallowequal$1 as m, getPanelIdsInsideTabPanels as n, getPanelTypeFromId as o, removePanelFromTabPanel as p, getPanelIdForType as q, reportError as r, sendNotification as s, toKey as t, useGuaranteedContext as u, getPathFromNode as v, updateTabPanelLayout as w, getSaveConfigsPayloadForAddedPanel as x, replaceAndRemovePanels as y, inlineTabPanelLayouts as z };
@@ -0,0 +1,84 @@
1
+ import { e as expose } from './comlink-DHMAu6X7.js';
2
+
3
+ // This Source Code Form is subject to the terms of the Mozilla Public
4
+ // License, v2.0. If a copy of the MPL was not distributed with this
5
+ // file, You can obtain one at http://mozilla.org/MPL/2.0/
6
+
7
+ function colorDepht(message, encoding, width, height, maxSteroDepth) {
8
+ const depthData = parseDepthData(message.data, encoding, width, height);
9
+ const colorizedData = colorizeDepthFrame(depthData, width, height, maxSteroDepth);
10
+ return colorizedData;
11
+ }
12
+ function parseDepthData(data, encoding, width, height) {
13
+ const pixelCount = width * height;
14
+ const depthData = new Float32Array(pixelCount);
15
+ if (encoding === "mono16" || encoding === "16UC1") {
16
+ const view = new DataView(data.buffer, data.byteOffset, data.byteLength);
17
+ for (let i = 0; i < pixelCount; i++) {
18
+ depthData[i] = view.getUint16(i * 2, true) / 1000.0;
19
+ }
20
+ } else if (encoding === "32FC1") {
21
+ const view = new DataView(data.buffer, data.byteOffset, data.byteLength);
22
+ for (let i = 0; i < pixelCount; i++) {
23
+ depthData[i] = view.getFloat32(i * 4, true);
24
+ }
25
+ } else {
26
+ throw new Error(`Unsupported depth encoding: ${encoding}`);
27
+ }
28
+ return depthData;
29
+ }
30
+ expose({
31
+ colorDepht
32
+ });
33
+ function colorizeDepthFrame(depthData, width, height, maxDepth) {
34
+ const pixelCount = width * height;
35
+ const colorizedData = new Uint8Array(pixelCount * 3);
36
+ const colormap = getJetColormap();
37
+ for (let i = 0; i < pixelCount; i++) {
38
+ const clipped = Math.max(0, Math.min(depthData[i] ?? 0, maxDepth));
39
+ const normalized = Math.floor(clipped / maxDepth * 255);
40
+ const color = colormap[normalized];
41
+ colorizedData[i * 3] = color?.[0] ?? 20; // R
42
+ colorizedData[i * 3 + 1] = color?.[1] ?? 20; // G
43
+ colorizedData[i * 3 + 2] = color?.[2] ?? 20; // B
44
+ }
45
+ return colorizedData;
46
+ }
47
+ let cachedColormap = null;
48
+ function getJetColormap() {
49
+ if (cachedColormap) {
50
+ return cachedColormap;
51
+ }
52
+ const colormap = [];
53
+ for (let i = 0; i < 256; i++) {
54
+ const value = i / 255.0;
55
+ let r, g, b;
56
+ if (value < 0.125) {
57
+ r = 0;
58
+ g = 0;
59
+ b = 0.5 + 0.5 * (value / 0.125);
60
+ } else if (value < 0.375) {
61
+ r = 0;
62
+ g = (value - 0.125) / 0.25;
63
+ b = 1;
64
+ } else if (value < 0.625) {
65
+ r = (value - 0.375) / 0.25;
66
+ g = 1;
67
+ b = 1 - (value - 0.375) / 0.25;
68
+ } else if (value < 0.875) {
69
+ r = 1;
70
+ g = 1 - (value - 0.625) / 0.25;
71
+ b = 0;
72
+ } else {
73
+ r = 1 - 0.5 * (value - 0.875) / 0.125;
74
+ g = 0;
75
+ b = 0;
76
+ }
77
+ colormap.push([Math.floor(r * 255), Math.floor(g * 255), Math.floor(b * 255)]);
78
+ }
79
+ colormap[0] = [0, 0, 0];
80
+ cachedColormap = colormap;
81
+ return colormap;
82
+ }
83
+
84
+ export { colorDepht };