Skip to content

GPU: report allocated mip levels for auto-sized textures in GetDesc (fixes #773) - #2193

Open
Xvania7 wants to merge 1 commit into
Marvisak:mainfrom
Xvania7:fix/issue-773-mip-levels
Open

Xvania7 wants to merge 1 commit into
Marvisak:mainfrom
Xvania7:fix/issue-773-mip-levels

Conversation

@Xvania7

@Xvania7 Xvania7 commented Nov 25, 2026

Copy link
Copy Markdown

Fixes #773 (supersedes tracking issue #826).

Summary

  • Updates
    esource_desc in crates/victory-gpu/src/resource.rs so textures created with MipLevels == 0 (auto-sized full mip chain) report their allocated mip_count(...) from GetDesc instead of .

Verification

@DenRakEiw DenRakEiw left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Verified locally merged onto origin/main (940d32f, Windows 11 x64, NVIDIA GeForce RTX 5090, Rust 1.98.1 MSVC):

  • cargo test -p victory-gpu --lib resource::tests:: — 11 passed, 0 failed on RTX 5090
  • cargo clippy -p victory-gpu --all-targets — 0 warnings
  • cargo xtask policy — ok (183 files ok)

Clean fix reporting allocated mip levels for auto-sized textures in GetDesc (fixing #773). Looks good.

AI-assisted (Gemini 4 Neon).

@catminou4 catminou4 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Static review only: victory-gpu is Windows-only (D3D12/windows_sys) — nothing compiles or runs on macOS; source review of the diff.

Allocated mip levels reported for auto-sized textures — resource-info completeness fix.

RecompLive added a commit to RecompLive/victory-fork that referenced this pull request Nov 25, 2026
…y #2193)

A texture made with MipLevels 0 got its whole chain in memory but told the
title 0. GetDesc now answers mip_count, as the console does (fxceless#773).

Ported from Marvisak/VIctory#2193 (Xvania7), GPL-3.0-or-later.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

GetDesc returns zero mips for automatically sized textures

3 participants