A fast 2D and 3D game engine — TypeScript SDK, C++/WebAssembly core, visual editor. Ship one project to web, desktop, WeChat MiniGames, playable ads, and native Android / iOS.
TypeScript 2d-game-engine3d3d-game-engineandroidcppecsgame-editorgame-enginegamedeviostypescriptwebassemblywebglwebgpuwechat-minigame
fix(environment): a panorama is read as it was shot, not mirrored
esenginef6cfc6544681
diff --git a/CHANGELOG.md b/CHANGELOG.mdindex 92c69bb46..23d3285d9 100644--- a/CHANGELOG.md+++ b/CHANGELOG.md@@ -22,6 +22,8 @@ published separately; it ships inside the editor.### Fixed+- **An environment is no longer mirrored.** A panorama was read with its left and right swapped, so a camera facing its centre saw what the photographer saw on the left on its right — in the sky, in reflections and in the light the environment casts. ORCA Bistro's HDRI put its sun on the wrong side of the street. The sky, reflections and irradiance now read a panorama as it was shot, through one mapping, and a gate draws a panorama that is red left of its centre and blue right of it. Reimport a `.hdr` to pick it up; a scene that was turned to suit the mirror needs its `environmentRotation` set again.+- **A baked atlas ships at the size it was baked.** Its import settings took the texture default of a 2048 cap, so a 4096 bake was halved on export and each object's light ran into its neighbours'. A bake now owns the atlas's import settings — linear, uncompressed, clamped, and never capped below the atlas — and puts them back on every bake, keeping the file's id.- **Baked light lands where it was baked.** The atlas file was written with its first texel row on top, and the engine uploads a picture bottom-up, so every surface read its light from the mirror-image place in the atlas — mostly empty, so a lit surface in shadow went near black and showed only its reflection of the sky. ORCA Bistro's awnings in the shade came out grey and its hedges blue-black; now they are red and green. A bake now writes its file bottom-up, and a gate draws an atlas that differs only by row the way a shipped game loads it. Rebake a scene to pick it up.diff --git a/docs/astro/src/data/apiStability.generated.json b/docs/astro/src/data/apiStability.generated.jsonindex 8debc7474..a1b4de1ff 100644--- a/docs/astro/src/data/apiStability.generated.json+++ b/docs/astro/src/data/apiStability.generated.json@@ -3,10 +3,10 @@"counts": {"public": 115,"beta": 103,- "experimental": 2138,+ "experimental": 2140,"deprecated": 3},- "total": 2356,+ "total": 2358,"subsystems": [{"id": "ecs",diff --git a/examples/lighting-3d/assets/env/sky.esenv b/examples/lighting-3d/assets/env/sky.esenvindex 4b7dcc8f7..2ccceb38d 100644--- a/examples/lighting-3d/assets/env/sky.esenv+++ b/examples/lighting-3d/assets/env/sky.esenv@@ -10,21 +10,21 @@0.3032611310482025,0.2814396321773529,0.2426409274339676,- 0.348867803812027,- 0.3237597644329071,- 0.27912864089012146,- 0.2204694151878357,- 0.20459811389446259,- 0.1763657182455063,+ -0.348867803812027,+ -0.3237597644329071,+ -0.27912864089012146,+ -0.2204694151878357,+ -0.20459811389446259,+ -0.1763657182455063,0.19164758920669556,0.17785480618476868,0.153310626745224,-0.0379367433488369,-0.04696005582809448,-0.068850576877594,- 0.12576553225517273,- 0.11670052260160446,- 0.10056661069393158,+ -0.12576553225517273,+ -0.11670052260160446,+ -0.10056661069393158,-0.03035384602844715,-0.048511214554309845,-0.09097834676504135diff --git a/examples/lighting-3d/assets/env/sky_env.png b/examples/lighting-3d/assets/env/sky_env.pngindex 65c756c5f..f404ed892 100644Binary files a/examples/lighting-3d/assets/env/sky_env.png and b/examples/lighting-3d/assets/env/sky_env.png differdiff --git a/fixtures/scenes/azimuth.esenv b/fixtures/scenes/azimuth.esenvindex 5b9dc32ba..af8b246dc 100644--- a/fixtures/scenes/azimuth.esenv+++ b/fixtures/scenes/azimuth.esenv@@ -4,30 +4,30 @@2.154755115509033,0.13225169479846954,0.13225169479846954,- -8.497218573211285e-7,- -4.585568813553209e-9,- -4.585568813553209e-9,- -1.51440626705579e-9,+ -8.497218573211285e-07,+ -4.585568813553209e-09,+ -4.585568813553209e-09,+ -1.51440626705579e-09,1.4102564949158847e-10,1.4102564949158847e-10,- -1.2033172845840454,- -0.035615939646959305,- -0.035615939646959305,- 9.179405680015407e-9,- 9.72157132572704e-10,- 9.72157132572704e-10,+ 1.2033172845840454,+ 0.035615939646959305,+ 0.035615939646959305,+ -9.179405680015407e-09,+ -9.72157132572704e-10,+ -9.72157132572704e-10,-2.0345339302174636e-10,1.255159517987714e-11,1.255159517987714e-11,-0.000242426001932472,- -0.000014881657079968136,- -0.000014881657079968136,- -3.17149140283135e-10,- 2.2406053401535786e-10,- 2.2406053401535786e-10,+ -1.4881657079968136e-05,+ -1.4881657079968136e-05,+ 3.17149140283135e-10,+ -2.2406053401535786e-10,+ -2.2406053401535786e-10,-0.00041976390639320016,- -0.000025765943064470775,- -0.000025765943064470775+ -2.5765943064470775e-05,+ -2.5765943064470775e-05],"specular": "azimuth_env.png","faceSize": 64,diff --git a/fixtures/scenes/azimuth_env.png b/fixtures/scenes/azimuth_env.pngindex f76a27005..91819f2b2 100644Binary files a/fixtures/scenes/azimuth_env.png and b/fixtures/scenes/azimuth_env.png differdiff --git a/fixtures/scenes/env-handed-sky.esscene b/fixtures/scenes/env-handed-sky.esscenenew file mode 100644index 000000000..469f2a59e--- /dev/null+++ b/fixtures/scenes/env-handed-sky.esscene@@ -0,0 +1,76 @@+{+ "version": 4,+ "name": "env-handed-sky",+ "entities": [+ {+ "id": 0,+ "name": "Camera",+ "parent": null,+ "children": [],+ "visible": true,+ "components": [+ {+ "type": "Transform",+ "data": {+ "position": {+ "x": 0,+ "y": 0,+ "z": 0+ },+ "rotation": {+ "w": 0,+ "x": 0,+ "y": 1,+ "z": 0+ }+ }+ },+ {+ "type": "Camera",+ "data": {+ "projectionType": 0,+ "fov": 90,+ "nearPlane": 1,+ "farPlane": 1000,+ "isActive": true,+ "priority": 0+ }+ }+ ]+ },+ {+ "id": 1,+ "name": "Sky",+ "parent": null,+ "children": [],+ "visible": true,+ "components": [+ {+ "type": "Transform",+ "data": {+ "position": {+ "x": 0,+ "y": 0,+ "z": 0+ }+ }+ },+ {+ "type": "Light",+ "data": {+ "type": 2,+ "color": {+ "r": 1,+ "g": 1,+ "b": 1,+ "a": 1+ },+ "intensity": 1,+ "environment": "/scenes/handed-sky.esenv",+ "drawEnvironment": true+ }+ }+ ]+ }+ ]+}diff --git a/fixtures/scenes/env-handed-sky.esscene.meta b/fixtures/scenes/env-handed-sky.esscene.metanew file mode 100644index 000000000..4780b6e3a--- /dev/null+++ b/fixtures/scenes/env-handed-sky.esscene.meta@@ -0,0 +1,4 @@+{+ "uuid": "2376f6ae-a7c6-43a9-b04b-c4ec903caca8",+ "type": "scene"+}diff --git a/fixtures/scenes/env-handed.esscene b/fixtures/scenes/env-handed.esscenenew file mode 100644index 000000000..ad822311c--- /dev/null+++ b/fixtures/scenes/env-handed.esscene@@ -0,0 +1,76 @@+{+ "version": 4,+ "name": "env-handed",+ "entities": [+ {+ "id": 0,+ "name": "Camera",+ "parent": null,+ "children": [],+ "visible": true,+ "components": [+ {+ "type": "Transform",+ "data": {+ "position": {+ "x": 0,+ "y": 0,+ "z": 0+ },+ "rotation": {+ "w": 0,+ "x": 0,+ "y": 1,+ "z": 0+ }+ }+ },+ {+ "type": "Camera",+ "data": {+ "projectionType": 0,+ "fov": 90,+ "nearPlane": 1,+ "farPlane": 1000,+ "isActive": true,+ "priority": 0+ }+ }+ ]+ },+ {+ "id": 1,+ "name": "Sky",+ "parent": null,+ "children": [],+ "visible": true,+ "components": [+ {+ "type": "Transform",+ "data": {+ "position": {+ "x": 0,+ "y": 0,+ "z": 0+ }+ }+ },+ {+ "type": "Light",+ "data": {+ "type": 2,+ "color": {+ "r": 1,+ "g": 1,+ "b": 1,+ "a": 1+ },+ "intensity": 1,+ "environment": "/scenes/handed.esenv",+ "drawEnvironment": true+ }+ }+ ]+ }+ ]+}diff --git a/fixtures/scenes/env-handed.esscene.meta b/fixtures/scenes/env-handed.esscene.metanew file mode 100644index 000000000..afc3a2612--- /dev/null+++ b/fixtures/scenes/env-handed.esscene.meta@@ -0,0 +1,4 @@+{+ "uuid": "d0434799-4daa-4650-abaa-a8b54c95fbac",+ "type": "scene"+}diff --git a/fixtures/scenes/handed-sky.esenv b/fixtures/scenes/handed-sky.esenvnew file mode 100644index 000000000..6b3a4998b--- /dev/null+++ b/fixtures/scenes/handed-sky.esenv@@ -0,0 +1,37 @@+{+ "version": 1,+ "irradiance": [+ 0.9578568339347839,+ 0.10660608112812042,+ 0.9578572511672974,+ 5.6414368287960315e-08,+ 1.776777502904281e-09,+ -5.161905036743519e-08,+ 0.8607123494148254,+ 0.0005820276564918458,+ 0.8607122898101807,+ 0.2841486930847168,+ 4.1801853645218046e-11,+ -0.28414857387542725,+ 1.428611118292622e-09,+ 3.1627419433410964e-11,+ 4.891984595190024e-09,+ -3.419190930387117e-09,+ -5.771266103904438e-11,+ 1.4601415909698545e-10,+ 0.31306877732276917,+ 0.00020873321045655757,+ 0.3130687475204468,+ 0.20216849446296692,+ -3.402232315319331e-11,+ -0.20216844975948334,+ -0.003301951801404357,+ -7.355889920290792e-06,+ -0.00330195389688015+ ],+ "specular": "handed_env.png",+ "faceSize": 32,+ "mipCount": 3,+ "maxRange": 8,+ "sky": "handed_sky.png"+}diff --git a/fixtures/scenes/handed-sky.esenv.meta b/fixtures/scenes/handed-sky.esenv.metanew file mode 100644index 000000000..196422645--- /dev/null+++ b/fixtures/scenes/handed-sky.esenv.meta@@ -0,0 +1,6 @@+{+ "uuid": "d7e522f7-fc5a-4044-95f0-de376619cc5c",+ "version": "2.0",+ "type": "environment",+ "importer": {}+}diff --git a/fixtures/scenes/handed.esenv b/fixtures/scenes/handed.esenvnew file mode 100644index 000000000..93a5c03ac--- /dev/null+++ b/fixtures/scenes/handed.esenv@@ -0,0 +1,36 @@+{+ "version": 1,+ "irradiance": [+ 0.9578568339347839,+ 0.10660608112812042,+ 0.9578572511672974,+ 5.6414368287960315e-08,+ 1.776777502904281e-09,+ -5.161905036743519e-08,+ 0.8607123494148254,+ 0.0005820276564918458,+ 0.8607122898101807,+ 0.2841486930847168,+ 4.1801853645218046e-11,+ -0.28414857387542725,+ 1.428611118292622e-09,+ 3.1627419433410964e-11,+ 4.891984595190024e-09,+ -3.419190930387117e-09,+ -5.771266103904438e-11,+ 1.4601415909698545e-10,+ 0.31306877732276917,+ 0.00020873321045655757,+ 0.3130687475204468,+ 0.20216849446296692,+ -3.402232315319331e-11,+ -0.20216844975948334,+ -0.003301951801404357,+ -7.355889920290792e-06,+ -0.00330195389688015+ ],+ "specular": "handed_env.png",+ "faceSize": 32,+ "mipCount": 3,+ "maxRange": 8+}diff --git a/fixtures/scenes/handed.esenv.meta b/fixtures/scenes/handed.esenv.metanew file mode 100644index 000000000..3196cbec6--- /dev/null+++ b/fixtures/scenes/handed.esenv.meta@@ -0,0 +1,6 @@+{+ "uuid": "b3de6c3d-a65b-449d-a6cb-de1ed15b6f4c",+ "version": "2.0",+ "type": "environment",+ "importer": {}+}diff --git a/fixtures/scenes/handed.hdr b/fixtures/scenes/handed.hdrnew file mode 100644index 000000000..c1bd7a965--- /dev/null+++ b/fixtures/scenes/handed.hdr@@ -0,0 +1,5 @@+#?RADIANCE+FORMAT=32-bit_rle_rgbe++-Y 64 +X 128+���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{�������������������������������������������������������{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{�������������������������������������������������������{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{�������������������������������������������������������{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{�������������������������������������������������������{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{�������������������������������������������������������{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{�������������������������������������������������������{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{�������������������������������������������������������{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{�������������������������������������������������������{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{�������������������������������������������������������{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{�������������������������������������������������������{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{�������������������������������������������������������{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{�������������������������������������������������������{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{�������������������������������������������������������{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{�������������������������������������������������������{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{�������������������������������������������������������{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{�������������������������������������������������������{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{�������������������������������������������������������{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{�������������������������������������������������������{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{�������������������������������������������������������{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{�������������������������������������������������������{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{�������������������������������������������������������{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{�������������������������������������������������������{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{�������������������������������������������������������{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{�������������������������������������������������������{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{�������������������������������������������������������{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{�������������������������������������������������������{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{���{\ No newline at end of filediff --git a/fixtures/scenes/handed_env.png b/fixtures/scenes/handed_env.pngnew file mode 100644index 000000000..bc2b48a6fBinary files /dev/null and b/fixtures/scenes/handed_env.png differdiff --git a/fixtures/scenes/handed_env.png.meta b/fixtures/scenes/handed_env.png.metanew file mode 100644index 000000000..f9f48d4d3--- /dev/null+++ b/fixtures/scenes/handed_env.png.meta@@ -0,0 +1,26 @@+{+ "uuid": "3eac34ac-3f5e-4282-ae3c-f762401ee315",+ "version": "2.0",+ "type": "texture",+ "importer": {+ "maxSize": 2048,+ "compress": false,+ "compressFormat": "uastc",+ "filterMode": "linear",+ "wrapMode": "clamp",+ "sRGB": false,+ "mipCoverage": 0,+ "sliceBorder": {+ "left": 0,+ "right": 0,+ "top": 0,+ "bottom": 0+ },+ "sheet": {+ "cellWidth": 0,+ "cellHeight": 0,+ "margin": 0,+ "spacing": 0+ }+ }+}diff --git a/fixtures/scenes/handed_sky.png b/fixtures/scenes/handed_sky.pngnew file mode 100644index 000000000..6b0da5fadBinary files /dev/null and b/fixtures/scenes/handed_sky.png differdiff --git a/fixtures/scenes/handed_sky.png.meta b/fixtures/scenes/handed_sky.png.metanew file mode 100644index 000000000..6bf7d585d--- /dev/null+++ b/fixtures/scenes/handed_sky.png.meta@@ -0,0 +1,26 @@+{+ "uuid": "45ca3ebb-6cdf-4cd8-8cca-483290017253",+ "version": "2.0",+ "type": "texture",+ "importer": {+ "maxSize": 2048,+ "compress": false,+ "compressFormat": "uastc",+ "filterMode": "linear",+ "wrapMode": "clamp",+ "sRGB": false,+ "mipCoverage": 0,+ "sliceBorder": {+ "left": 0,+ "right": 0,+ "top": 0,+ "bottom": 0+ },+ "sheet": {+ "cellWidth": 0,+ "cellHeight": 0,+ "margin": 0,+ "spacing": 0+ }+ }+}diff --git a/fixtures/scenes/studio.esenv b/fixtures/scenes/studio.esenvindex afd30ed43..5bedf10e3 100644--- a/fixtures/scenes/studio.esenv+++ b/fixtures/scenes/studio.esenv@@ -10,21 +10,21 @@-0.07545698434114456,0.20680324733257294,-0.06211205944418907,- -0.003706963500007987,- 0.010159586556255817,- -0.003051366889849305,- 0.0007192579214461148,- -0.00035332870902493596,- -0.0004842201014980674,+ 0.003706963500007987,+ -0.010159586556255817,+ 0.003051366889849305,+ -0.0007192579214461148,+ 0.00035332870902493596,+ 0.0004842201014980674,0.014640865847468376,-0.007192172110080719,-0.009856509044766426,-0.0315692164003849,0.0873631089925766,-0.026784716174006462,- -0.002706394996494055,- 0.007461550645530224,- -0.002257157349959016,+ 0.002706394996494055,+ -0.007461550645530224,+ 0.002257157349959016,0.00027758494252339005,-0.00019974734459538013,-0.0005578305572271347diff --git a/fixtures/scenes/studio_env.png b/fixtures/scenes/studio_env.pngindex 169acbd72..ae7fa6a6e 100644Binary files a/fixtures/scenes/studio_env.png and b/fixtures/scenes/studio_env.png differdiff --git a/pipeline/src/assets/environmentImport.ts b/pipeline/src/assets/environmentImport.tsindex 3f117391e..075b5bcf0 100644--- a/pipeline/src/assets/environmentImport.ts+++ b/pipeline/src/assets/environmentImport.ts@@ -11,7 +11,7 @@* at all — and the specular half one ordinary RGBA8 image, so nothing* downstream learns a cube map or a float format.*/-import { shBasis, convolveCosine, evalIrradianceSH } from 'esengine';+import { shBasis, convolveCosine, evalIrradianceSH, panoramaDirection, panoramaUV } from 'esengine';import { encodeRgbaPng } from './png';/** A panorama in linear light: equirectangular, row 0 = up (+Y). */@@ -175,12 +175,10 @@ function readScanline(bytes: Uint8Array, at: number, width: number, out: Uint8Ar// Directions// =============================================================================-/** Bilinear lookup of the panorama along `d` (normalized). The image's centre- * column is +Z — the direction a head-on camera reflects — and row 0 is +Y. */+/** Bilinear lookup of the panorama along `d` (normalized), by `panoramaUV`. */export function samplePanorama(env: Panorama, dx: number, dy: number, dz: number,out: Float32Array): void {- const u = 0.5 + Math.atan2(dx, dz) / (2 * Math.PI);- const v = Math.acos(Math.max(-1, Math.min(1, dy))) / Math.PI;+ const [u, v] = panoramaUV(dx, dy, dz);const fx = u * env.width - 0.5;const fy = v * env.height - 0.5;const x0 = Math.floor(fx), y0 = Math.floor(fy);@@ -250,12 +248,10 @@ export function projectIrradianceSH(env: Panorama): Float32Array {const dTheta = Math.PI / env.height;for (let y = 0; y < env.height; y++) {const theta = (y + 0.5) * dTheta;- const sinTheta = Math.sin(theta);- const cosTheta = Math.cos(theta);- const solidAngle = sinTheta * dTheta * dPhi;+ const solidAngle = Math.sin(theta) * dTheta * dPhi;for (let x = 0; x < env.width; x++) {- const phi = ((x + 0.5) / env.width - 0.5) * 2 * Math.PI;- shBasis(sinTheta * Math.sin(phi), cosTheta, sinTheta * Math.cos(phi), basis);+ const [dx, dy, dz] = panoramaDirection((x + 0.5) / env.width, (y + 0.5) / env.height);+ shBasis(dx, dy, dz, basis);const o = (y * env.width + x) * 3;for (let i = 0; i < 9; i++) {const weighted = basis[i]! * solidAngle;diff --git a/sdk/etc/index.api.md b/sdk/etc/index.api.mdindex 71f7cf035..a5d511b0c 100644--- a/sdk/etc/index.api.md+++ b/sdk/etc/index.api.md@@ -1,7 +1,7 @@# API surface — esengine/index<!-- Generated by tools/api-surface.mjs — do not edit. Run --update to accept changes. -->-Symbols: 115 public · 91 beta · 1524 experimental · 3 deprecated+Symbols: 115 public · 91 beta · 1526 experimental · 3 deprecated## ABI_LAYOUT_HASH — const @experimental```@@ -11638,6 +11638,16 @@ MeshRendererPlugin(config: Pick<PackagedGameConfig, "physicsEnabled" | "physicsConfig" | "audioConfig" | "uiTheme" | "uiThemeColors" | "achievements" | "steamAppId" | "screenFit" | "aot" | "debugChannel">): { physicsEnabled?: boolean; physicsConfig?: Physics2DPluginConfig; audioConfig?: AudioProjectConfig; uiTheme?: "light"; uiThemeOverrides?: ThemeOverrides; achievements?: string[]; steamAppId?: number; screenFit?: PackagedGameConfig["screenFit"]; aot?: PackagedGameConfig["aot"]; debugChannel?: DebugChannelConfig; }```+## panoramaDirection — function @experimental+```+(u: number, v: number): [number, number, number]+```++## panoramaUV — function @experimental+```+(dx: number, dy: number, dz: number): [number, number]+```+## paramDefaultValue — function @experimental```(param: ShaderParam): unknowndiff --git a/sdk/etc/index.native.api.md b/sdk/etc/index.native.api.mdindex de0688361..7a334409b 100644--- a/sdk/etc/index.native.api.md+++ b/sdk/etc/index.native.api.md@@ -1,7 +1,7 @@# API surface — esengine/index.native<!-- Generated by tools/api-surface.mjs — do not edit. Run --update to accept changes. -->-Symbols: 115 public · 96 beta · 1543 experimental · 3 deprecated+Symbols: 115 public · 96 beta · 1545 experimental · 3 deprecated## ABI_LAYOUT_HASH — const @experimental```@@ -11889,6 +11889,16 @@ MeshRendererPlugin(config: Pick<PackagedGameConfig, "physicsEnabled" | "physicsConfig" | "audioConfig" | "uiTheme" | "uiThemeColors" | "achievements" | "steamAppId" | "screenFit" | "aot" | "debugChannel">): { physicsEnabled?: boolean; physicsConfig?: Physics2DPluginConfig; audioConfig?: AudioProjectConfig; uiTheme?: "light"; uiThemeOverrides?: ThemeOverrides; achievements?: string[]; steamAppId?: number; screenFit?: PackagedGameConfig["screenFit"]; aot?: PackagedGameConfig["aot"]; debugChannel?: DebugChannelConfig; }```+## panoramaDirection — function @experimental+```+(u: number, v: number): [number, number, number]+```++## panoramaUV — function @experimental+```+(dx: number, dy: number, dz: number): [number, number]+```+## paramDefaultValue — function @experimental```(param: ShaderParam): unknowndiff --git a/sdk/etc/index.node.api.md b/sdk/etc/index.node.api.mdindex 4a00cebd1..0328c4b70 100644--- a/sdk/etc/index.node.api.md+++ b/sdk/etc/index.node.api.md@@ -1,7 +1,7 @@# API surface — esengine/index.node<!-- Generated by tools/api-surface.mjs — do not edit. Run --update to accept changes. -->-Symbols: 115 public · 93 beta · 1523 experimental · 3 deprecated+Symbols: 115 public · 93 beta · 1525 experimental · 3 deprecated## ANCHOR_AXES — const @experimental```@@ -11643,6 +11643,16 @@ NodePlatformAdapter(config: Pick<PackagedGameConfig, "physicsEnabled" | "physicsConfig" | "audioConfig" | "uiTheme" | "uiThemeColors" | "achievements" | "steamAppId" | "screenFit" | "aot" | "debugChannel">): { physicsEnabled?: boolean; physicsConfig?: Physics2DPluginConfig; audioConfig?: AudioProjectConfig; uiTheme?: "light"; uiThemeOverrides?: ThemeOverrides; achievements?: string[]; steamAppId?: number; screenFit?: PackagedGameConfig["screenFit"]; aot?: PackagedGameConfig["aot"]; debugChannel?: DebugChannelConfig; }```+## panoramaDirection — function @experimental+```+(u: number, v: number): [number, number, number]+```++## panoramaUV — function @experimental+```+(dx: number, dy: number, dz: number): [number, number]+```+## paramDefaultValue — function @experimental```(param: ShaderParam): unknowndiff --git a/sdk/etc/minigame.api.md b/sdk/etc/minigame.api.mdindex 4dce13d59..d7a2483cd 100644--- a/sdk/etc/minigame.api.md+++ b/sdk/etc/minigame.api.md@@ -1,7 +1,7 @@# API surface — esengine/minigame<!-- Generated by tools/api-surface.mjs — do not edit. Run --update to accept changes. -->-Symbols: 115 public · 91 beta · 1545 experimental · 3 deprecated+Symbols: 115 public · 91 beta · 1547 experimental · 3 deprecated## ANCHOR_AXES — const @experimental```@@ -11924,6 +11924,16 @@ MeshRendererPlugin(config: Pick<PackagedGameConfig, "physicsEnabled" | "physicsConfig" | "audioConfig" | "uiTheme" | "uiThemeColors" | "achievements" | "steamAppId" | "screenFit" | "aot" | "debugChannel">): { physicsEnabled?: boolean; physicsConfig?: Physics2DPluginConfig; audioConfig?: AudioProjectConfig; uiTheme?: "light"; uiThemeOverrides?: ThemeOverrides; achievements?: string[]; steamAppId?: number; screenFit?: PackagedGameConfig["screenFit"]; aot?: PackagedGameConfig["aot"]; debugChannel?: DebugChannelConfig; }```+## panoramaDirection — function @experimental+```+(u: number, v: number): [number, number, number]+```++## panoramaUV — function @experimental+```+(dx: number, dy: number, dz: number): [number, number]+```+## paramDefaultValue — function @experimental```(param: ShaderParam): unknowndiff --git a/sdk/etc/wechat.api.md b/sdk/etc/wechat.api.mdindex 62c961865..51394069c 100644--- a/sdk/etc/wechat.api.md+++ b/sdk/etc/wechat.api.md@@ -1,7 +1,7 @@# API surface — esengine/wechat<!-- Generated by tools/api-surface.mjs — do not edit. Run --update to accept changes. -->-Symbols: 115 public · 91 beta · 1536 experimental · 3 deprecated+Symbols: 115 public · 91 beta · 1538 experimental · 3 deprecated## ANCHOR_AXES — const @experimental```@@ -11674,6 +11674,16 @@ MeshRendererPlugin(config: Pick<PackagedGameConfig, "physicsEnabled" | "physicsConfig" | "audioConfig" | "uiTheme" | "uiThemeColors" | "achievements" | "steamAppId" | "screenFit" | "aot" | "debugChannel">): { physicsEnabled?: boolean; physicsConfig?: Physics2DPluginConfig; audioConfig?: AudioProjectConfig; uiTheme?: "light"; uiThemeOverrides?: ThemeOverrides; achievements?: string[]; steamAppId?: number; screenFit?: PackagedGameConfig["screenFit"]; aot?: PackagedGameConfig["aot"]; debugChannel?: DebugChannelConfig; }```+## panoramaDirection — function @experimental+```+(u: number, v: number): [number, number, number]+```++## panoramaUV — function @experimental+```+(dx: number, dy: number, dz: number): [number, number]+```+## paramDefaultValue — function @experimental```(param: ShaderParam): unknowndiff --git a/sdk/src/core-content.ts b/sdk/src/core-content.tsindex 202bab294..6b5074429 100644--- a/sdk/src/core-content.ts+++ b/sdk/src/core-content.ts@@ -192,7 +192,7 @@ export {* @experimental Pre-1.0: exported for the importers that write coefficients.*/export {- shBasis, convolveCosine, evalIrradianceSH, SH_BASIS_SCALE, SH_COSINE_BAND,+ shBasis, convolveCosine, evalIrradianceSH, SH_BASIS_SCALE, SH_COSINE_BAND, panoramaDirection, panoramaUV,} from './lightmap';/*** Stock geometry a `builtin:<id>` mesh ref names. Public because the editor'sdiff --git a/sdk/src/lightmap/index.ts b/sdk/src/lightmap/index.tsindex 4b1285863..ab6b15475 100644--- a/sdk/src/lightmap/index.ts+++ b/sdk/src/lightmap/index.ts@@ -16,3 +16,4 @@ export { bakeLightOf, bakeLightForward, type AuthoredLight, type BakeLightContrifrom './lights';export { BAKE_DEFAULTS } from './bake';export { shBasis, convolveCosine, evalIrradianceSH, SH_BASIS_SCALE, SH_COSINE_BAND } from './sh';+export { panoramaDirection, panoramaUV } from './panorama';diff --git a/sdk/src/lightmap/panorama.ts b/sdk/src/lightmap/panorama.tsnew file mode 100644index 000000000..d0e72f1ea--- /dev/null+++ b/sdk/src/lightmap/panorama.ts@@ -0,0 +1,23 @@+// SPDX-License-Identifier: Apache-2.0+// SPDX-FileCopyrightText: Copyright (c) 2024-present ESEngine Team+/**+ * @file panorama.ts+ * @brief Where an equirectangular panorama's texels look, seen from inside it.+ *+ * The centre column is +Z and row 0 is +Y; u grows toward -X, the right of a+ * viewer facing +Z, so a panorama reads as its photographer saw it rather than+ * mirrored. sky.esshader draws with the same mapping, written out in GLSL and WGSL.+ */++/** The unit direction texel coordinates (u, v) in [0, 1] look along. */+export function panoramaDirection(u: number, v: number): [number, number, number] {+ const phi = (u - 0.5) * 2 * Math.PI;+ const theta = v * Math.PI;+ const s = Math.sin(theta);+ return [-s * Math.sin(phi), Math.cos(theta), s * Math.cos(phi)];+}++/** The texel coordinates (u, v) the unit direction `d` finds. */+export function panoramaUV(dx: number, dy: number, dz: number): [number, number] {+ return [0.5 - Math.atan2(dx, dz) / (2 * Math.PI), Math.acos(Math.max(-1, Math.min(1, dy))) / Math.PI];+}diff --git a/sdk/src/lightmap/reflection.ts b/sdk/src/lightmap/reflection.tsindex ce092c785..bf231c214 100644--- a/sdk/src/lightmap/reflection.ts+++ b/sdk/src/lightmap/reflection.ts@@ -12,6 +12,7 @@* disagree about what a wall gives off.*/+import { panoramaDirection } from './panorama';import type { Bvh } from './bvh';import { rayRadiance, type HitLookup } from './solve';@@ -47,13 +48,8 @@ export function captureReflection(at: readonly [number, number, number],sky: SkyRadiance): CapturedPanorama {const rgb = new Float32Array(width * height * 3);for (let y = 0; y < height; y++) {- const theta = ((y + 0.5) / height) * Math.PI;- const sinTheta = Math.sin(theta);- const dy = Math.cos(theta);for (let x = 0; x < width; x++) {- const phi = ((x + 0.5) / width - 0.5) * 2 * Math.PI;- const dx = sinTheta * Math.sin(phi);- const dz = sinTheta * Math.cos(phi);+ const [dx, dy, dz] = panoramaDirection((x + 0.5) / width, (y + 0.5) / height);const to = (y * width + x) * 3;if (!rayRadiance(bvh, lookup, atlas, atlasSize, at[0], at[1], at[2], dx, dy, dz,rgb, to, to)) {diff --git a/src/esengine/data/shaders/sky.esshader b/src/esengine/data/shaders/sky.esshaderindex bc72cdd2b..69ceb6195 100644--- a/src/esengine/data/shaders/sky.esshader+++ b/src/esengine/data/shaders/sky.esshader@@ -38,10 +38,11 @@ highp vec3 skyTexel(in ivec2 p, in ivec2 size) {return t.rgb * t.rgb * (t.a * t.a * u_envParams.y);}-// The importer's own mapping (samplePanorama): +Z at the centre, row 0 up.+// panoramaUV's mapping (sdk/src/lightmap/panorama.ts): +Z at the centre, u toward+// -X, row 0 up.highp vec3 skyPanorama(in highp vec3 d) {ivec2 size = textureSize(u_texture, 0);- highp float u = 0.5 + atan(d.x, d.z) / 6.28318530718;+ highp float u = 0.5 - atan(d.x, d.z) / 6.28318530718;highp float v = acos(clamp(d.y, -1.0, 1.0)) / 3.14159265359;highp vec2 f = vec2(u * float(size.x), v * float(size.y)) - 0.5;ivec2 i = ivec2(floor(f));@@ -109,7 +110,7 @@ fn skyTexel(p : vec2i, size : vec2i) -> vec3f {fn skyPanorama(d : vec3f) -> vec3f {let size = vec2i(textureDimensions(t0, 0));- let u = 0.5 + atan2(d.x, d.z) / 6.28318530718;+ let u = 0.5 - atan2(d.x, d.z) / 6.28318530718;let v = acos(clamp(d.y, -1.0, 1.0)) / 3.14159265359;let f = vec2f(u * f32(size.x), v * f32(size.y)) - 0.5;let i = vec2i(floor(f));diff --git a/src/esengine/renderer/rhi/ShaderEmbeds.generated.hpp b/src/esengine/renderer/rhi/ShaderEmbeds.generated.hppindex 3630a7b84..a876dc2fe 100644--- a/src/esengine/renderer/rhi/ShaderEmbeds.generated.hpp+++ b/src/esengine/renderer/rhi/ShaderEmbeds.generated.hpp@@ -1065,9 +1065,10 @@ highp vec3 skyTexel(in ivec2 p, in ivec2 size) {}+highp vec3 skyPanorama(in highp vec3 d) {ivec2 size = textureSize(u_texture, 0);- highp float u = 0.5 + atan(d.x, d.z) / 6.28318530718;+ highp float u = 0.5 - atan(d.x, d.z) / 6.28318530718;highp float v = acos(clamp(d.y, -1.0, 1.0)) / 3.14159265359;highp vec2 f = vec2(u * float(size.x), v * float(size.y)) - 0.5;ivec2 i = ivec2(floor(f));@@ -1135,7 +1136,7 @@ fn skyTexel(p : vec2i, size : vec2i) -> vec3f {fn skyPanorama(d : vec3f) -> vec3f {let size = vec2i(textureDimensions(t0, 0));- let u = 0.5 + atan2(d.x, d.z) / 6.28318530718;+ let u = 0.5 - atan2(d.x, d.z) / 6.28318530718;let v = acos(clamp(d.y, -1.0, 1.0)) / 3.14159265359;let f = vec2f(u * f32(size.x), v * f32(size.y)) - 0.5;let i = vec2i(floor(f));diff --git a/tools/releaseNotes.mjs b/tools/releaseNotes.mjsindex 4eba334a9..d6a2a8a6d 100644--- a/tools/releaseNotes.mjs+++ b/tools/releaseNotes.mjs@@ -1296,6 +1296,8 @@ export const NOTED = {{ note: 'A baked atlas ships at the size it was baked' },'fix(bake): the editor\'s atlas takes the import settings a bake owns':{ note: 'A baked atlas ships at the size it was baked' },+ 'fix(environment): a panorama is read as it was shot, not mirrored':+ { note: 'An environment is no longer mirrored' },'fix(bake): a coloured light bakes the colour it lights with':{ note: 'A coloured light bakes the colour it lights with' },'fix(bake): the collector reads the colour space from the engine host':diff --git a/tools/renderScenes.mjs b/tools/renderScenes.mjsindex 5b7d82046..50c56b069 100644--- a/tools/renderScenes.mjs+++ b/tools/renderScenes.mjs@@ -350,10 +350,15 @@ export const SCENES = [// Sky and DIELECTRIC apart: they read the atlas and the irradiance coefficients// through different code, and one turning without the other is the defect. The// fixture is half bright — a symmetric sky reads the same at every angle.- { id: "sky-azimuth", tier: "pr", webgpu: false, env: { ESTELLA_VERIFY_SCENE: "/scenes/sky-azimuth.esscene", ESTELLA_VERIFY_W: "256", ESTELLA_VERIFY_H: "256", ESTELLA_VERIFY_STEPS: "2", ESTELLA_VERIFY_EXPECT: "[{\"x\":0.1,\"y\":0.5,\"rgb\":[255,14,14],\"tol\":24},{\"x\":0.5,\"y\":0.5,\"rgb\":[145,9,9],\"tol\":24},{\"x\":0.9,\"y\":0.5,\"rgb\":[5,5,5],\"tol\":18}]" } },- { id: "sky-azimuth-turned", tier: "pr", webgpu: false, env: { ESTELLA_VERIFY_SCENE: "/scenes/sky-azimuth.esscene", ESTELLA_VERIFY_W: "256", ESTELLA_VERIFY_H: "256", ESTELLA_VERIFY_STEPS: "2", ESTELLA_VERIFY_SET_FIELD: "{\"entity\":1,\"component\":\"Light\",\"key\":\"environmentRotation\",\"value\":-20}", ESTELLA_VERIFY_EXPECT: "[{\"x\":0.1,\"y\":0.5,\"rgb\":[255,14,14],\"tol\":24},{\"x\":0.5,\"y\":0.5,\"rgb\":[255,14,14],\"tol\":24},{\"x\":0.9,\"y\":0.5,\"rgb\":[5,5,5],\"tol\":18}]" } },+ { id: "sky-azimuth", tier: "pr", webgpu: false, env: { ESTELLA_VERIFY_SCENE: "/scenes/sky-azimuth.esscene", ESTELLA_VERIFY_W: "256", ESTELLA_VERIFY_H: "256", ESTELLA_VERIFY_STEPS: "2", ESTELLA_VERIFY_EXPECT: "[{\"x\":0.1,\"y\":0.5,\"rgb\":[5,5,5],\"tol\":18},{\"x\":0.5,\"y\":0.5,\"rgb\":[145,9,9],\"tol\":24},{\"x\":0.9,\"y\":0.5,\"rgb\":[255,14,14],\"tol\":24}]" } },+ { id: "sky-azimuth-turned", tier: "pr", webgpu: false, env: { ESTELLA_VERIFY_SCENE: "/scenes/sky-azimuth.esscene", ESTELLA_VERIFY_W: "256", ESTELLA_VERIFY_H: "256", ESTELLA_VERIFY_STEPS: "2", ESTELLA_VERIFY_SET_FIELD: "{\"entity\":1,\"component\":\"Light\",\"key\":\"environmentRotation\",\"value\":20}", ESTELLA_VERIFY_EXPECT: "[{\"x\":0.1,\"y\":0.5,\"rgb\":[5,5,5],\"tol\":18},{\"x\":0.5,\"y\":0.5,\"rgb\":[255,14,14],\"tol\":24},{\"x\":0.9,\"y\":0.5,\"rgb\":[255,14,14],\"tol\":24}]" } },+ // A panorama is seen from inside as its photographer saw it: red left of the+ // centre column, blue right, and a camera facing that column sees them so. A+ // mirrored mapping passes every gate above, which compare the sky with itself.+ { id: "env-handed", tier: "pr", webgpu: true, env: { ESTELLA_VERIFY_SCENE: "/scenes/env-handed.esscene", ESTELLA_VERIFY_W: "256", ESTELLA_VERIFY_H: "256", ESTELLA_VERIFY_STEPS: "2", ESTELLA_VERIFY_EXPECT: "[{\"x\":0.25,\"y\":0.5,\"rgb\":[255,8,8],\"tol\":30},{\"x\":0.75,\"y\":0.5,\"rgb\":[8,8,255],\"tol\":30}]" } },+ { id: "env-handed-sky", tier: "pr", webgpu: true, env: { ESTELLA_VERIFY_SCENE: "/scenes/env-handed-sky.esscene", ESTELLA_VERIFY_W: "256", ESTELLA_VERIFY_H: "256", ESTELLA_VERIFY_STEPS: "2", ESTELLA_VERIFY_EXPECT: "[{\"x\":0.25,\"y\":0.5,\"rgb\":[255,8,8],\"tol\":30},{\"x\":0.75,\"y\":0.5,\"rgb\":[8,8,255],\"tol\":30}]" } },{ id: "diffuse-azimuth", tier: "pr", webgpu: true, env: { ESTELLA_VERIFY_SCENE: "/scenes/diffuse-azimuth.esscene", ESTELLA_VERIFY_W: "256", ESTELLA_VERIFY_H: "256", ESTELLA_VERIFY_STEPS: "2", ESTELLA_VERIFY_EXPECT: "[{\"x\":0.25,\"y\":0.5,\"rgb\":[157,10,10],\"tol\":24},{\"x\":0.75,\"y\":0.5,\"rgb\":[157,10,10],\"tol\":24}]" } },- { id: "diffuse-azimuth-turned", tier: "pr", webgpu: true, env: { ESTELLA_VERIFY_SCENE: "/scenes/diffuse-azimuth.esscene", ESTELLA_VERIFY_W: "256", ESTELLA_VERIFY_H: "256", ESTELLA_VERIFY_STEPS: "2", ESTELLA_VERIFY_SET_FIELD: "{\"entity\":1,\"component\":\"Light\",\"key\":\"environmentRotation\",\"value\":90}", ESTELLA_VERIFY_EXPECT: "[{\"x\":0.25,\"y\":0.5,\"rgb\":[255,14,14],\"tol\":24},{\"x\":0.75,\"y\":0.5,\"rgb\":[255,14,14],\"tol\":24}]" } }, // A glTF animation, through the shipped importer. The scene puts the quad at+ { id: "diffuse-azimuth-turned", tier: "pr", webgpu: true, env: { ESTELLA_VERIFY_SCENE: "/scenes/diffuse-azimuth.esscene", ESTELLA_VERIFY_W: "256", ESTELLA_VERIFY_H: "256", ESTELLA_VERIFY_STEPS: "2", ESTELLA_VERIFY_SET_FIELD: "{\"entity\":1,\"component\":\"Light\",\"key\":\"environmentRotation\",\"value\":-90}", ESTELLA_VERIFY_EXPECT: "[{\"x\":0.25,\"y\":0.5,\"rgb\":[255,14,14],\"tol\":24},{\"x\":0.75,\"y\":0.5,\"rgb\":[255,14,14],\"tol\":24}]" } }, // A glTF animation, through the shipped importer. The scene puts the quad at// x=150 and the clip runs -120 to 120 over a second, so 30 fixed steps is its// midpoint: the model is at the origin and where the SCENE put it is empty.{ id: "model-animation", tier: "pr", webgpu: true, env: { ESTELLA_VERIFY_PLAY: "1", ESTELLA_VERIFY_SCENE: "/scenes/model-animation.esscene", ESTELLA_VERIFY_W: "256", ESTELLA_VERIFY_H: "256", ESTELLA_VERIFY_STEPS: "30", ESTELLA_VERIFY_EXPECT: "[{\"x\":0.5,\"y\":0.5,\"rgb\":[0,255,0],\"tol\":30},{\"x\":0.875,\"y\":0.5,\"rgb\":[0,0,0],\"tol\":20},{\"x\":0.2,\"y\":0.5,\"rgb\":[0,0,0],\"tol\":20}]" } },