Commit Graph

19 Commits

Author SHA1 Message Date
63a569f904 Merge pull request #2339 from syfyra/fix/studio-stats-labels-i18n
studio: show the EU strings the page already defines (STUDIO-EU-STRINGS)
2026-12-01 16:19:43 +01:00
72f278dd56 Merge pull request #2335 from syfyra/feat/studio-model-details
studio: list the shown model's size, meshes, materials and textures (STUDIO-MODEL-DETAILS)
2026-12-01 16:19:06 +01:00
25cf1aa4ec Merge pull request #2250 from kirigayakazima/codex/studio-dds-cube-face
studio: select cube faces for DDS previews and texels
2026-11-29 03:16:26 +01:00
21bdf6b60d Merge pull request #1138 from Okachamie/studio-model-load-progress
viewer: keep the loading bar visible for the current model
2026-11-29 03:15:35 +01:00
ce8afe3c2a Merge pull request #1490 from xel1uz/fix/studio-reset-camera
studio: reset the camera to the current model's fitted view
2026-11-29 03:15:21 +01:00
3c9a09f12a studio: show the EU strings the page already defines (STUDIO-EU-STRINGS)
viewer/studio.html has an RU/EU switch and an I18N table, but several
of its entries were never applied, so the EU page kept Russian text: the
five stats labels (Модель, Категория, Полигонов, Вершин, Размер файла),
the reset-camera button, the texture gallery heading, the "Все" category
chip, the texture count, and the empty-list messages for models and
textures. The "show all" button and the texture load error had no
entries at all.

Apply them: applyTranslations sets the labels (each is the text node in
front of its value, so the markup stays as it is), the button, the
heading, the chip and the count; the lists, which re-render on a switch,
read their messages from I18N. Two entries are added for the "show all"
button and the load error. The category names and the model download
alert are left for later.

Tested: new test in tests/test_viewer_studio.cjs (fails before the
change, passes after); the existing studio tests pass.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-26 15:05:05 +01:00
d83cee900c studio: list the shown model's size, meshes, materials and textures (STUDIO-MODEL-DETAILS)
The studio's stats panel gave a model's triangles, vertices and file
size. Checking an export needs the next layer too: how big the model is,
how many meshes and materials it has, and which textures each material
uses at what size. Add that to the panel, read from the loaded glTF
alone:

- the bounding-box size in metres (glTF units), three significant
  digits, so a ring and a building both read sensibly;
- meshes / materials / textures (GLTFLoader makes one mesh per glTF
  primitive; a texture used in two slots counts once);
- a collapsible list of the materials, each with the meshes using it
  and its texture slots with their sizes. A material with neither a
  texture nor vertex colours is marked "no texture", the flat-colour
  look of a texture the export lost.

In clay and normals mode the list keeps the model's own materials.
Names are escaped, the new labels follow the RU/EU switch, and a failed
or stale download leaves the shown model's details in place.

Tested: three new node tests in tests/test_viewer_studio.cjs (fail
before the change, pass after); in a browser with tools/gallery.py and
a synthetic .glb (two meshes sharing a textured material, an untextured
one, a vertex-coloured one).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-26 15:00:26 +01:00
42cc70344c studio: select cube faces for DDS previews and texels 2026-11-26 18:18:00 +08:00
515fc75c0d studio: go back to the shown model's row when a download fails (STUDIO-FAILED-LOAD-SELECTION)
After a failed download the list kept the failed model selected, while the
viewport and the statistics still showed the previous one. Remember the model
that is shown and select its row again, without rebuilding the list.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-25 21:37:36 +01:00
662f8c3df4 studio: reset the camera to the current model's fitted view 2026-11-25 02:35:34 +01:00
442c348843 viewer: keep the loading bar visible for the current model 2026-11-24 13:52:03 -05:00
9280ce0370 viewer/studio: escape texture preview URL and format in texture grid cards 2026-11-24 20:25:01 +08:00
e59eb29bec Studio: show dimensions for single-plane DDS textures (BUILD-3940) 2026-11-24 01:02:13 +03:00
2a3b3b554b studio: a texture preview that fails to load no longer fires its error handler forever (#6529)
Squash-merged after diff review of PR #6529
2026-11-23 12:52:27 -06:00
b9466fda20 Studio: keep large model categories paginated (#6793)
Squash-merged after diff review of PR #6793 - Studio: keep large model categories paginated
2026-11-23 09:52:24 -06:00
aa4ed4c2d5 Studio: inspect original half-float DDS texel values (#6896)
Squash-merged after diff review of PR #6896 - Studio: inspect original half-float DDS texel values
2026-11-23 09:46:54 -06:00
f487e2a9d1 studio: dispose the previous model's geometry, materials and textures
Signed-off-by: Maxime Mansiet <AirKyzzZ@users.noreply.github.com>
2026-11-22 23:26:17 +01:00
c6ad43620a studio: show only the latest model a click asked for
Signed-off-by: Maxime Mansiet <AirKyzzZ@users.noreply.github.com>
2026-11-22 23:23:55 +01:00
e616e64480 studio: render model and texture names as text, not HTML
Signed-off-by: Maxime Mansiet <AirKyzzZ@users.noreply.github.com>
2026-11-22 23:22:39 +01:00