diff options
| author | salmonik <salmonik@tuta.io> | 2026-11-04 11:25:50 +0100 |
|---|---|---|
| committer | salmonik <salmonik@tuta.io> | 2026-11-04 11:25:50 +0100 |
| commit | 5153c37de890c42c8da97a0bcf0df724ef25f7f7 (patch) | |
| tree | d0f159154ea1101af3d3972de9fded550d3c2f52 /src/world.cpp | |
| parent | World tint: tint map-static props through IStudioRender (diff) | |
| download | hl2h-5153c37de890c42c8da97a0bcf0df724ef25f7f7.tar.gz hl2h-5153c37de890c42c8da97a0bcf0df724ef25f7f7.zip | |
World tint: include props/ materials; log static studio draws
Static props commonly use brush-style props/... materials
(props/woodcrate001a is LightmappedGeneric), so the models/props-only filter
missed them. Include the props/ prefix.
Also log the first static prop studio draws and a 500-draw summary so we can
see whether the engine draws props through DrawModelStaticProp at all.
Diffstat (limited to '')
| -rw-r--r-- | src/world.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/world.cpp b/src/world.cpp index 38d302f..0de86c6 100644 --- a/src/world.cpp +++ b/src/world.cpp | |||
| @@ -58,7 +58,11 @@ Tint g_applied{false, 255, 255, 255, 255, 255, 255, 255, 255, 255}; | |||
| 58 | // map prop lives under models/props*, which keeps NPC/player/weapon materials | 58 | // map prop lives under models/props*, which keeps NPC/player/weapon materials |
| 59 | // out of the prop pass. | 59 | // out of the prop pass. |
| 60 | bool is_prop_material(const char *name) { | 60 | bool is_prop_material(const char *name) { |
| 61 | return name && strncmp(name, "models/props", 12) == 0; | 61 | // Static props often use the brush-style "props/..." materials (e.g. |
| 62 | // props/woodcrate001a, LightmappedGeneric), while dynamic props use | ||
| 63 | // models/props_junk/... . | ||
| 64 | return name && (strncmp(name, "models/props", 12) == 0 || | ||
| 65 | strncmp(name, "props/", 6) == 0); | ||
| 62 | } | 66 | } |
| 63 | 67 | ||
| 64 | struct MatCalls { | 68 | struct MatCalls { |
