Repository navigation
Allow up to three compressed texture mip levels to be omitted - #1418
Open
givethesourceplox wants to merge 2 commits into
Open
givethesourceplox wants to merge 2 commits into
givethesourceplox wants to merge 2 commits into
Conversation
Texture upload, view and copy remapping subset of fc815c3 (PR seedds#1319 by JioChoi). Kept as a separate prerequisite commit so the multi-level extension is independently reviewable. Pool, raw-residency and diagnostic changes are excluded.
Aeonitis
pushed a commit
to Aeonitis/nxnative
that referenced
this pull request
Nov 6, 2026
…er and shader chain, the branch's host services, movie clock, packing and Ocarina of Time additions Upstream reached about 60 fps in Kokiri Forest with its own versions of most of the branch's merged PRs, so where both changed the same code upstream's is kept: - The shader chain is upstream's (translator, lock, dmsh tools, Ryujinx sources), plus the branch's bracket-depth flattening (dmsh_depth.py, test_dmsh_depth.py); chain c732699d4fdb. Not carried: the LDSM subgroup fence (seedds#1376, needs a translator rebuild; upstream's HMMA/LDSM rework reports clean movies) and the shared raw-memory lookups (seedds#1405, superseded by upstream's last-entry lookups). - The renderer (dm/gfx/nvn, dm/gfx/msl) and its tests are upstream's. Not carried: seedds#1390-seedds#1394, seedds#1404, seedds#1408, seedds#1409, seedds#1417, seedds#1418, seedds#1420, seedds#1427, seedds#1320, seedds#1331, seedds#1332, seedds#1368, seedds#1285 renderer parts, pool_skip_retired, and the branch's warning fixes and prewarm progress there. They stay on oot-integration. - Ocarina of Time's profile is upstream's, with the branch's 12 movie compute rows in pso_manifest.tsv, PLAN.md and PR-AUDIT.md. - shader_split.py is upstream's plus the BAHS record check (test_split_bahs_records.py). - Host: upstream's EventFd, PlayReport send, audio lock and vibration answers; the branch's service sessions (hle_sf, hle_prepo), sync waits, AV1 movie clock and parallel decode, diag_abort frame fix and focus control are kept. - Scripts: shader.noindex, tmp.noindex, notes outside the shader key, bench and regress changes. Checked: the Mac host builds (GAME=0400486024DEC000); host unit tests pass; the Python tool tests pass on Python 3.13 except test_dmsh_pool_arrays, test_nro_pack, test_nsp_dump and test_nsp_incremental, which fail on upstream main as well. Not run: the full shader build on this chain, gameplay.
This was referenced Nov 7, 2026
2 tasks done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What and why
Extend the optional compressed-texture quality path from #1319 to omit one, two or three finest mip levels.
DM_NVN_TEX_MIP_SKIP=<pixels>sets the width-and-height threshold; newDM_NVN_TEX_MIP_LEVELS=1..3selects the reduction while always retaining at least one level. The feature remains off by default.Keep the original coarser mip contents during upload, translate guest mip levels for views/copies/readbacks/sparse clamps, and refuse copies of removed levels. Recognize reduced textures only when both dimensions and mip count match an eligible compressed chain, avoiding accidental remapping of unrelated size differences. Compressed
IMAGEresources retain read-only usage; shader-written textures and uncompressed render formats remain unchanged. Zero-block accounting indexes the retained host levels.This deliberately trades close-up texture detail and original texture-size queries for reduced texture storage. It changes texture quality, not internal render resolution, and does not claim to fix the complete GPU or thermal bottleneck.
Dependency: the texture upload/view/copy portion of #1319, originating in fc815c3, is included as the separate prerequisite commit 4b13851. Credit for that one-level path belongs to #1319 (JioChoi). The next commit contains this multi-level extension, stricter recognition and fixture. Pool thresholds, raw-residency policy and other #1319 changes are excluded. The read-only compressed-image correction and SDK-26 MetalFX declaration prerequisite overlap #1404.
Reference finding.
Checked
Apple M1 Pro, macOS 26.5.2, Xcode 26.5:
check_t_texture_quality: 18 checks in each of four processes, all pass with Metal API validation: reduction off, and levels 1, 2 and 3 at threshold 512. A five-level BC1 texture has different data in each mip; GPU readback verifies retained contents and dimensions. Also checks guest-to-host mip mapping, removed-level copy refusal, minimum one retained mip, and unchanged small/uncompressed/shader-written/volume textures.git diff --checkpasses.No standalone Ocarina gameplay, isolated memory/FPS/thermal measurement or iPhone result is claimed for this branch. The local harness has only DK, MKW and Ocarina, no stored baselines and no DK/Ocarina smoke routes on this base. Cross-game runtime behavior, sparse streaming and explicit view/copy workloads still need broader coverage; the fixture verifies uploads and level-selection semantics.
Docs