@spatialwalk/avatarkit 1.0.0-beta.96 → 1.0.0-beta.97

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/CHANGELOG.md CHANGED
@@ -5,6 +5,24 @@ All notable changes to this project will be documented in this file.
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
6
6
  and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
7
 
8
+ ## [1.0.0-beta.97]
9
+
10
+ ### ⚡ Breaking Changes
11
+
12
+ - **`transform` renamed to `avatarTransform`** — `avatarView.transform` is now `avatarView.avatarTransform`. Aligned naming across Web, Android, and iOS SDKs.
13
+
14
+ ### ✨ Features
15
+
16
+ - **Avatar transform from character settings** — Avatar automatically applies position and scale from character settings. User-set `avatarTransform` stacks on top of the base values.
17
+
18
+ ### 🐛 Bugfixes
19
+
20
+ - **Rendering quality improvement** — Improved color accuracy for avatar rendering.
21
+
22
+ ### 📝 Documentation
23
+
24
+ - **send() byte alignment** — Documented PCM S16LE byte alignment requirement for `send()`.
25
+
8
26
  ## [1.0.0-beta.96]
9
27
 
10
28
  ### 🐛 Bugfixes
package/README.md CHANGED
@@ -282,7 +282,9 @@ button.addEventListener('click', async () => {
282
282
  })
283
283
 
284
284
  // 7. Send audio data (SDK mode, must be mono PCM16 format matching configured sample rate)
285
- // audioData: ArrayBuffer or Uint8Array containing PCM16 audio samples
285
+ // audioData: ArrayBuffer or Uint8Array containing PCM16 (S16LE) audio samples
286
+ // ⚠️ Byte length MUST be even (2 bytes per sample). Odd-length data will cause server-side
287
+ // validation error and WebSocket disconnect.
286
288
  // - PCM files: Can be directly read as ArrayBuffer
287
289
  // - WAV files: Extract PCM data from WAV format (may require resampling)
288
290
  // - MP3 files: Decode first (e.g., using AudioContext.decodeAudioData()), then convert to PCM16
@@ -590,10 +592,10 @@ avatarView.onFirstRendering = () => {
590
592
 
591
593
  // Get or set avatar transform (position and scale)
592
594
  // Get current transform
593
- const currentTransform = avatarView.transform // { x: number, y: number, scale: number }
595
+ const currentTransform = avatarView.avatarTransform // { x: number, y: number, scale: number }
594
596
 
595
597
  // Set transform
596
- avatarView.transform = { x, y, scale }
598
+ avatarView.avatarTransform = { x, y, scale }
597
599
  // - x: Horizontal offset in normalized coordinates (-1 to 1, where -1 = left edge, 0 = center, 1 = right edge)
598
600
  // - y: Vertical offset in normalized coordinates (-1 to 1, where -1 = bottom edge, 0 = center, 1 = top edge)
599
601
  // - scale: Scale factor (1.0 = original size, 2.0 = double size, 0.5 = half size)
@@ -728,16 +730,16 @@ avatarView.controller.onError = (error: AvatarError) => {} // Includes error.cod
728
730
  ```typescript
729
731
  // Get or set avatar transform (position and scale in canvas)
730
732
  // Get current transform
731
- const currentTransform = avatarView.transform // { x: number, y: number, scale: number }
733
+ const currentTransform = avatarView.avatarTransform // { x: number, y: number, scale: number }
732
734
 
733
735
  // Set transform
734
- avatarView.transform = { x, y, scale }
736
+ avatarView.avatarTransform = { x, y, scale }
735
737
  // - x: Horizontal offset in normalized coordinates (-1 to 1, where -1 = left edge, 0 = center, 1 = right edge)
736
738
  // - y: Vertical offset in normalized coordinates (-1 to 1, where -1 = bottom edge, 0 = center, 1 = top edge)
737
739
  // - scale: Scale factor (1.0 = original size, 2.0 = double size, 0.5 = half size)
738
740
  // Example:
739
- avatarView.transform = { x: 0, y: 0, scale: 1.0 } // Center, original size
740
- avatarView.transform = { x: 0.5, y: 0, scale: 2.0 } // Right half, double size
741
+ avatarView.avatarTransform = { x: 0, y: 0, scale: 1.0 } // Center, original size
742
+ avatarView.avatarTransform = { x: 0.5, y: 0, scale: 2.0 } // Right half, double size
741
743
  ```
742
744
 
743
745
  **Important Notes:**
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@spatialwalk/avatarkit",
3
3
  "type": "module",
4
- "version": "1.0.0-beta.96",
4
+ "version": "1.0.0-beta.97",
5
5
  "packageManager": "pnpm@10.18.2",
6
6
  "description": "AvatarKit SDK - 3D Gaussian Splatting Avatar Rendering SDK",
7
7
  "author": "AvatarKit Team",