Skip to content

bugfix(texture): Fix Generals missing texture and vegetation at lowest texture resolution#3013

Merged
xezon merged 1 commit into
TheSuperHackers:mainfrom
Mr-Sheerlock:fix/Black-terrain-textures-generals
Jul 26, 2026
Merged

bugfix(texture): Fix Generals missing texture and vegetation at lowest texture resolution#3013
xezon merged 1 commit into
TheSuperHackers:mainfrom
Mr-Sheerlock:fix/Black-terrain-textures-generals

Conversation

@Mr-Sheerlock

Copy link
Copy Markdown

In General's DDSFileClass the ReductionFactor was being set to 0 because it was compared with WW3D::Get_Texture_Min_Dimension() which is different from its meaning and use. Hence, this adjustment was removed.

Also note that this results in a difference with retail where the vegetation and assets weren't being reduced properly at the lowest setting. I confirmed that the vegetation now looks similar to Zero hour's lowest setting (as opposed to higher detail even at lowest setting in retail generals). I also didn't notice a regression at higher resolutions.

Retail Generals

retail_generals_shell

Fixed Generals

fixed_generals_shell

…t texture resolution

Removed the adjustment of reduction factor due to comparison with texture_min_dimension.
@greptile-apps

greptile-apps Bot commented Jul 25, 2026

Copy link
Copy Markdown

Greptile Summary

Removes the incorrect DDS mip-reduction clamp in the Generals-specific WW3D implementation, allowing the existing texture-loading pipeline to apply the requested reduction and preserve textures and vegetation at the lowest texture setting.

Confidence Score: 5/5

The PR appears safe to merge with no actionable defects identified.

The main compressed-texture loading path already bounds the requested reduction against the available mip levels and minimum dimensions before constructing DDSFileClass, so removing the constructor’s incorrect secondary clamp restores the intended low-resolution behavior without exposing an invalid reduction on current paths.

Important Files Changed

Filename Overview
Generals/Code/Libraries/Source/WWVegas/WW3D2/ddsfile.cpp Removes a redundant, semantically incorrect comparison between mip-level count and minimum texture dimension; existing caller-side reduction validation preserves valid mip bounds.

Reviews (1): Last reviewed commit: "bugfix(texture): Fix Generals missing te..." | Re-trigger Greptile

@xezon xezon added Bug Something is not working right, typically is user facing Critical Severity: Minor < Major < Critical < Blocker Gen Relates to Generals ThisProject The issue was introduced by this project, or this task is specific to this project Rendering Is Rendering related labels Jul 25, 2026

@xezon xezon 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.

Nice find. Would have been implicitly fixed on game merge :-)

@Mr-Sheerlock

Copy link
Copy Markdown
Author

Sure! If you'd like me to complete the merge of the file please do tell.

@xezon
xezon merged commit 7d20de6 into TheSuperHackers:main Jul 26, 2026
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Bug Something is not working right, typically is user facing Critical Severity: Minor < Major < Critical < Blocker Gen Relates to Generals Rendering Is Rendering related ThisProject The issue was introduced by this project, or this task is specific to this project

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Black terrain, textures and missing vegetation when setting lowest texture resolution in Generals

2 participants