Adaptive Music v0.8.0 release candidate
Validate and generate manual release / package (push) Waiting to run
Validate and generate manual release / package (push) Waiting to run
This commit is contained in:
1 parent
8c07a468a4
commit
95b0427aa1
48 files changed
+3631
-313
No files matched your search
+51
-31
@@ -1,4 +1,4 @@
|
||||
# Adaptive Music architecture — 0.7.2
|
||||
# Adaptive Music architecture — 0.8.0
|
||||
|
||||
Adaptive Music is an independent project by CheddahBoxMB for Foundry v14.371 and
|
||||
MA 2.10.6, with no system dependency or additional required process. The expanded
|
||||
@@ -18,9 +18,12 @@ reads account-authorized music providers. The official pinned Sendspin SDK gener
|
||||
one X25519 identity for the campaign, GM user and MA origin. Its identity, pairing
|
||||
storage, catalog key and name are encrypted in local IndexedDB with a non-extractable
|
||||
AES-GCM key. The key is stored in the same browser; this does not protect against
|
||||
trusted-origin scripts or theft of the complete browser profile. The token is never
|
||||
persisted. Failed attempts retain private inputs in tab memory; changing the MA
|
||||
origin never reuses its token or identity.
|
||||
trusted-origin scripts or theft of the complete browser profile. A GM can opt in
|
||||
to a separate encrypted device record with the MA token, address, receiver name
|
||||
and reconnect preference. Receiver records exclude credentials. Both records are
|
||||
scoped to the Foundry origin, world and user. Without opt-in, failed attempts
|
||||
retain private input in tab memory. A different MA origin uses separate credentials
|
||||
and receiver identity.
|
||||
|
||||
The logged-in GM account can retain an AES-GCM envelope containing the last
|
||||
successfully connected MA address and receiver name in a Foundry User Setting.
|
||||
@@ -32,6 +35,9 @@ Connect audio first authenticates the `/ws` API session, then authenticates
|
||||
`/sendspin` using that token and the SDK-generated client ID. MA 2.10.6 associates
|
||||
this new web receiver with already-authenticated API sessions for the token. The
|
||||
same API session must therefore survive pairing, catalog reads and playback.
|
||||
MA 2.10.6 associates all API sessions carrying the same restricted token with the
|
||||
last Sendspin browser receiver to connect using it. Concurrent receivers need
|
||||
separate tokens. Loss of receiver access stops automation without retargeting.
|
||||
`sendspin/pair_web_player` pairs only this identity to the calling account. Noise
|
||||
activation and clock synchronization precede exact ID/name/provider/topology checks.
|
||||
During startup, a successful null queue lookup is retried briefly on the same
|
||||
@@ -45,18 +51,22 @@ account-authorized playlist tracks become opaque HMAC references bound to the st
|
||||
catalog key and campaign. New references use a separate key derived from the MA
|
||||
token, MA origin and campaign so the same authorized catalog resolves on another
|
||||
browser. A browser with its original receiver vault still resolves legacy IDs.
|
||||
Saving that scene again writes the new reference. Scene/world flags hold opaque
|
||||
references. Live connections still depend on the active GM browser and its audio
|
||||
context. Disconnect stops the session and clears the in-memory token.
|
||||
Saving that scene again writes the new reference. Scene and world flags hold opaque references. The active GM browser and its audio
|
||||
context host the live connection. Disconnect ends that session and pauses automatic
|
||||
reconnection.
|
||||
|
||||
## Audio and listeners
|
||||
|
||||
The pinned official SDK negotiates PCM, performs Noise and time synchronization,
|
||||
and decodes audio. A bounded Web Audio scheduler accepts the normal approximately
|
||||
four-second stream-ahead window (six-second ceiling, 512 nodes and 2 MiB of decoded
|
||||
buffers). Timestamped partial clears trim only affected audio. Full clears and ends
|
||||
stop the stream. A software gain and output meter feed the GM speakers and a single
|
||||
MediaStreamDestination track for listener distribution.
|
||||
and decodes audio. A bounded Web Audio timeline anchors a packet run to the local
|
||||
audio clock and advances it by each rendered chunk’s length. The browser converts
|
||||
sample rates from each AudioBuffer’s input rate. A 120 ms startup cushion and
|
||||
bounded 0.1% rate correction absorb jitter and drift. The queue allows eight
|
||||
seconds of server lead, up to 768 active nodes and 8 MiB of decoded audio. It
|
||||
counts source timestamp gaps and overlaps separately from late drops and local
|
||||
underruns. Timestamped partial clears trim only invalid audio. Separate
|
||||
transition and volume gains feed the GM output and one MediaStreamDestination
|
||||
track for listener distribution.
|
||||
|
||||
User document public keys authenticate ephemeral ECDH/AES-GCM invitation delivery.
|
||||
Private keys stay in memory. Invitations are bound to world, sender, recipient,
|
||||
@@ -66,13 +76,13 @@ never PCM over that socket. Firefox’s session-level SDP direction default is
|
||||
correctly overridden by the sole audio media direction. Offers remain recvonly;
|
||||
answers remain sendonly. Video, data and injected sender media are rejected.
|
||||
|
||||
Up to eight listeners negotiate automatically. Invitations renew after 20 minutes
|
||||
and expire after 30. Failed negotiation times out after 20 seconds; disconnected
|
||||
peers are revoked after 10 seconds and the 15-second reconciliation loop can issue
|
||||
fresh invitations. One user gesture unlocks browser audio when required. A stable
|
||||
HTMLAudioElement pumps the incoming remote track; Web Audio provides an optional
|
||||
activated playback path. Default ICE has no public STUN/TURN service. WAN delivery
|
||||
requires a viable existing ICE route and is not inferred from local tests.
|
||||
Up to eight listeners negotiate automatically. A signaling invitation expires
|
||||
after 30 minutes. Established DTLS-SRTP media continues while its listener and GM
|
||||
remain authorized. Failed negotiation times out after 20 seconds and a disconnected
|
||||
peer is dropped after 10 seconds. The reconciliation loop can invite the listener
|
||||
again. One user gesture unlocks browser audio when required. A stable
|
||||
HTMLAudioElement plays the incoming track, with an optional activated Web Audio
|
||||
path. Default ICE uses no public STUN/TURN service.
|
||||
|
||||
## Transitions and recovery
|
||||
|
||||
@@ -88,20 +98,30 @@ whole-second position and state, scoped to campaign/session/fence/generation for
|
||||
to 12 hours. Ambiguous writes latch closed and stop automation; they are not retried.
|
||||
MA Sendspin lacks native pause in 2.10.6, so pause retains a logical stopped-queue
|
||||
snapshot and resume explicitly seeks its item. A paused restore rebuilds without
|
||||
briefly playing. This logical pause state is memory-only.
|
||||
briefly playing. A finished static queue can be interrupted and rebuilt in an
|
||||
idle state for replay. The Playback panel can set MA's dedicated queue repeat
|
||||
mode. Logical pause state is memory-only.
|
||||
|
||||
Reconnecting to a remembered owned receiver can attach to its existing queue
|
||||
without replacing it. Automation remains paused for explicit resumption when that
|
||||
queue is nonempty. Crash/reload cannot guarantee restoration of an interrupted
|
||||
ambient stack or logical pause position. No crossfade or independent simultaneous
|
||||
layers is implemented with the single upstream queue. Native playback uses only
|
||||
explicitly owned playlists; effects and AmbientSound remain untouched.
|
||||
Reconnecting to a remembered receiver can preserve its existing queue. When the
|
||||
trusted device auto-reconnects with a populated queue, the next music intent
|
||||
or explicit return to scene music takes control. Crash or reload can lose the
|
||||
ambient interruption stack and logical pause. Adaptive Music provides sequential
|
||||
fade-out and fade-in using its one MA queue. True overlap between arbitrary
|
||||
scene playlists would require two independently managed streams at once.
|
||||
|
||||
Scene Configuration and the Playlists sidebar use Foundry render hooks. The
|
||||
director displays virtual catalog items for assignment and saves only opaque
|
||||
references into scene flags. No Foundry Playlist document is created for an MA
|
||||
item. The module cedes a scene with a configured native soundtrack to Foundry.
|
||||
Only explicitly owned native fallback playlists can be managed by Adaptive Music.
|
||||
Positional audio and other native effects stay under Foundry’s control.
|
||||
|
||||
## Verification boundary
|
||||
|
||||
The installed v0.7.0 module was tested in a logged-in Foundry v14.371 development
|
||||
world through the private Nginx route. The GM connected to MA and two players
|
||||
received audio using Foundry’s module socket for signaling. The test also exercised
|
||||
real combat hooks, ordered ambient restoration, and User document permissions.
|
||||
Earlier browser tests used a Playwright source overlay. The original Mac path,
|
||||
physical-device audibility, invitation renewal and WAN behavior remain unverified.
|
||||
world through the private Nginx route. The v0.8.0 browser preview used validated
|
||||
ZIP assets with the real development world, MA and two listeners. It exercised
|
||||
Foundry module-socket signaling, scene and combat hooks, ordered ambient
|
||||
restoration, real playback controls and User document permissions. Exact server
|
||||
installation of v0.8.0, the original Mac path, physical-device audibility and
|
||||
WAN behavior await verification.
|
||||
Reference in new issue
Block a user