From 799ea753a4bac97c46aa82728524ac9fdd7dc5fc Mon Sep 17 00:00:00 2001 From: dfattal Date: Fri, 31 Jul 2026 07:31:18 +0800 Subject: [PATCH] =?UTF-8?q?avatar(zones):=20request=20the=20opt-in=20zone?= =?UTF-8?q?=20edge=20feather=20=E2=80=94=20plugin=20v2.10.0=20(unity#238)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Runtime display-zones spec v3 (runtime#800/#803/#804) made zone edges HARD by default; the avatar's tiger-zone-vs-bubble-band transition wants the old soft look, so it now opts in explicitly: - SeedLaunchZone: SetZoneFeather(0, 16px) after seeding the zone rect (and zone 1 in the DISPLAYXR_MULTI_ZONE=1 test split). App-side provider state, survives session restarts; EntryPointNotFound-guarded for older DLLs. - com.displayxr.unity -> #upm/v2.10.0 (adds DisplayXRProvider.SetZoneFeather; displayxr-unity#239). Cosmetic only: the published hardware wish stays binary; pre-v3 runtimes ignore the request. HW-eyeballed by David on the win box against the post-#804 dev runtime: soft 16px zone-vs-band edge, runtime log shows "zone feather mask ... (composite-only, wish stays binary)" + mode=2. Co-Authored-By: Claude Fable 5 --- samples/desktop-avatar/Assets/TigerSpeechBubble.cs | 13 +++++++++++++ samples/desktop-avatar/Packages/manifest.json | 2 +- samples/desktop-avatar/Packages/packages-lock.json | 4 ++-- 3 files changed, 16 insertions(+), 3 deletions(-) diff --git a/samples/desktop-avatar/Assets/TigerSpeechBubble.cs b/samples/desktop-avatar/Assets/TigerSpeechBubble.cs index d50f2b8..ca9a549 100644 --- a/samples/desktop-avatar/Assets/TigerSpeechBubble.cs +++ b/samples/desktop-avatar/Assets/TigerSpeechBubble.cs @@ -65,6 +65,9 @@ public class TigerSpeechBubble : MonoBehaviour // fresh install / partner starts here, not at the avatar 0.25 / 1000x1500). // Per-user changes still persist on top via PlayerPrefs. private const float kDefaultBubbleBandFraction = 0.33f; + // Cosmetic edge feather radius (client-window px) for the 3D zone's edge — + // the zone-vs-band transition (unity#238; opt-in since runtime spec v3). + private const float kZoneEdgeFeatherPx = 16f; // ProjectSettings born-windowed default (840x1448) — fallback when Screen.* is // not yet populated at SubsystemRegistration time. private const int kDefaultPanelW = 840; @@ -132,10 +135,20 @@ private static void SeedLaunchZone() // zone-sized. DisplayXR.DisplayXRProvider.SetZoneRect(0, splitY, z0w, panelH - splitY); + // Soft zone-vs-band edge (unity#238): zone edges are HARD by default + // since runtime display-zones spec v3 (runtime#800) — the avatar wants + // its tiger zone feathered into the bubble band, so it opts in with an + // explicit radius (the pre-v3 implicit look was 16 px). Cosmetic only: + // the hardware wish stays binary; pre-v3 runtimes ignore the request. + try { DisplayXR.DisplayXRProvider.SetZoneFeather(0, kZoneEdgeFeatherPx); } + catch (System.EntryPointNotFoundException) { } // older plugin DLL + if (s_MultiZone) { DisplayXR.DisplayXRProvider.SetZoneCount(2); DisplayXR.DisplayXRProvider.SetZone(1, 2, panelW / 2, splitY, panelW - panelW / 2, panelH - splitY); + try { DisplayXR.DisplayXRProvider.SetZoneFeather(1, kZoneEdgeFeatherPx); } + catch (System.EntryPointNotFoundException) { } Debug.Log($"[TigerSpeechBubble] MULTI-ZONE: zone0=bottom-left(0,{splitY},{panelW / 2},{panelH - splitY}) " + $"zone1=bottom-right({panelW / 2},{splitY},{panelW - panelW / 2},{panelH - splitY})"); } diff --git a/samples/desktop-avatar/Packages/manifest.json b/samples/desktop-avatar/Packages/manifest.json index 42327d7..c09f77c 100644 --- a/samples/desktop-avatar/Packages/manifest.json +++ b/samples/desktop-avatar/Packages/manifest.json @@ -1,6 +1,6 @@ { "dependencies": { - "com.displayxr.unity": "https://github.com/DisplayXR/displayxr-unity.git#upm/v2.9.1", + "com.displayxr.unity": "https://github.com/DisplayXR/displayxr-unity.git#upm/v2.10.0", "com.unity.multiplayer.center": "1.0.1", "com.unity.render-pipelines.universal": "17.0.4", "com.unity.ugui": "2.0.0", diff --git a/samples/desktop-avatar/Packages/packages-lock.json b/samples/desktop-avatar/Packages/packages-lock.json index 406c300..ca8d7bf 100644 --- a/samples/desktop-avatar/Packages/packages-lock.json +++ b/samples/desktop-avatar/Packages/packages-lock.json @@ -1,13 +1,13 @@ { "dependencies": { "com.displayxr.unity": { - "version": "https://github.com/DisplayXR/displayxr-unity.git#upm/v2.9.1", + "version": "https://github.com/DisplayXR/displayxr-unity.git#upm/v2.10.0", "depth": 0, "source": "git", "dependencies": { "com.unity.xr.management": "4.4.0" }, - "hash": "416bf4e8018e71afb626d6c8b423cd258b16bd56" + "hash": "3c4ca06f3eeb87bf3236d13c50597986d8cc7353" }, "com.unity.burst": { "version": "1.8.28",