@d5techs/3dgs-lib 1.4.44 → 1.4.46

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/App.d.ts CHANGED
@@ -187,6 +187,7 @@ export declare class App {
187
187
  }): Promise<void>;
188
188
  clearSkybox(): void;
189
189
  isSkyboxActive(): boolean;
190
+ setSkyboxAlignToGround(value: boolean): void;
190
191
  getTransformGizmo(): import(".").TransformGizmo;
191
192
  getViewportGizmo(): import(".").ViewportGizmo;
192
193
  setViewportGizmoVisible(visible: boolean): void;
@@ -81,6 +81,8 @@ export declare class OrbitControls {
81
81
  * 将球坐标写入相机位置(内部方法,不处理阻尼)
82
82
  */
83
83
  private applySpherical;
84
+ get modelCenter(): [number, number, number];
85
+ get modelRadius(): number;
84
86
  /**
85
87
  * 旋转速度缩放:当 target 远离模型时降低旋转灵敏度,
86
88
  * 使模型在屏幕上的视觉运动速度保持一致。
@@ -8,14 +8,16 @@ export declare class SkyboxRenderer {
8
8
  private cubeTexture;
9
9
  private cubeBindGroup;
10
10
  private frameReady;
11
+ alignToGround: boolean;
11
12
  constructor(device: GPUDevice, format: GPUTextureFormat, depthFormat: GPUTextureFormat);
12
13
  get isActive(): boolean;
13
14
  loadCubemap(faceUrls: [string, string, string, string, string, string]): Promise<void>;
14
15
  /**
15
- * Write uniforms BEFORE beginFrame(). No matrix inversion needed —
16
- * we extract the view rotation transpose and inverse projection scalars directly.
16
+ * Write uniforms BEFORE beginFrame().
17
+ * pitchOffset: radians to rotate sampling direction around world X axis,
18
+ * used to align skybox horizon with model ground plane.
17
19
  */
18
- prepareFrame(viewMatrix: Float32Array, projectionMatrix: Float32Array): void;
20
+ prepareFrame(viewMatrix: Float32Array, projectionMatrix: Float32Array, pitchOffset?: number): void;
19
21
  draw(pass: GPURenderPassEncoder): void;
20
22
  clear(): void;
21
23
  destroy(): void;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@d5techs/3dgs-lib",
3
- "version": "1.4.44",
3
+ "version": "1.4.46",
4
4
  "description": "可扩展的 WebGPU 3D 渲染引擎",
5
5
  "type": "module",
6
6
  "main": "./dist/3dgs-lib.cjs",