17
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-10-17 13:19:20 +02:00
Commit Graph

17 Commits

Author SHA1 Message Date
maj00r
61b3ec6f3f parse windows.h before any import reaches betterRenderer
Six module interfaces carry windows.h in their fragment, and a fragment's
include guard does not cross the boundary, so a unit that imported first
and included the SDK afterwards parsed it twice: clang reports it as
conflicting redeclarations of BroadcastSystemMessageEx and mismatched
uuids all through the SDK. Same shape as the basic_filebuf failure, one
level further out - the header arrives through d3d12.h, not directly.

Thirty units get a guarded windows.h ahead of everything; on Linux it is
a no-op. Vendored single-header libraries are left alone, and the block
goes after a BOM rather than before it.
2026-09-10 15:40:52 +02:00
maj00r
02c6e6895e cover the units that are not module units
The template-header propagation only walked files with a module
declaration, so EU07.cpp, windows.cpp, export_e3d_standalone.cpp and
every betterRenderer source were outside it - including the file with
main(). They reach cParser and friends through eu07.simcore and
instantiate their templates without the headers those bodies name.

Adds audit_modules.py, which checks the whole tree for the seven classes
this migration hit; all seven are clean now.
2026-09-10 02:04:06 +02:00
maj00r
26501b0fd7 hoist standard includes above everything else
Ordering them before the imports in the same file was not enough: a
project header on line 1 can import a module several levels down whose
global module fragment already pulled in the same standard header, and
that include guard does not cross the module boundary. Putting them
first means the guard is set before anything can import.

Skips vendored single-header libraries and anything inside an #if.
2026-09-10 01:02:17 +02:00
maj00r
cfd1c1f318 repair the include reordering
The previous pass dropped imports into the middle of HR_RETURN's
line continuations, breaking nvrenderer_d3d12.cpp, and its scan gave up
on the first line of any file with a BOM - which is why nvtexture.cpp
still had five includes sitting after its imports. Rewritten to skip
macro continuations, tolerate a BOM, and insert only immediately before
the first import.
2026-09-10 00:52:06 +02:00
maj00r
1455583ab6 put every include before every import
A header first pulled in through an imported module's global module
fragment leaves no include guard in the importing unit - macros do not
cross a module boundary - so a later textual include parses it again and
MSVC rejects the redefinition. Redoes the betterRenderer sweep with
placement that stays out of #if blocks, which is where the previous one
dropped <fstream> and broke nvrenderer_d3d12.cpp.
2026-09-10 00:40:32 +02:00
maj00r
2695c8e525 include what you use in betterRenderer
Its sources reached the standard library through the project headers they
included; those are imports now. 178 headers across 56 files, plus 18 C
library headers elsewhere for memcpy/printf and friends. MSVC's STL does
not supply these transitively the way libstdc++ does.
2026-09-10 00:26:55 +02:00
maj00r
7667d8d4d3 build betterRenderer against the modules
Verified locally now that Vulkan and DXC are installed: all 31 targets
compile. glm has to come from eu07.glm only - having it both as a plain
include and as an import made every overload ambiguous. nvrenderer.h is
self-sufficient, since register.cpp includes nothing else. Fixes the
vcpkg triplet, which was pinned to x64-windows.
2026-09-09 23:45:53 +02:00
maj00r
06f6c6035b let betterRenderer import the modules
The module file set moves to its own eu07_modules library: a target can
only consume C++20 modules by linking the target that owns them, and
betterRenderer is a separate add_library. Its project includes become
imports.

CXX_EXTENSIONS must match across the two - a BMI built with -std=c++20
is refused by a unit compiled with -std=gnu++20.
2026-09-09 23:30:34 +02:00
docentYT
ec1dfae953 Replace starts_with and ends_with with string class methods 2026-05-01 17:31:11 +02:00
docentYT
b59ccb6de5 Better Split implementation and remove of unused overloads 2026-05-01 01:55:46 +02:00
jerrrrycho
9f43dca48b refactor: create paths namespace instead of global variables 2026-03-15 11:55:30 +01:00
0715437108 Fix include directives 2026-03-14 20:51:11 +01:00
copilot-swe-agent[bot]
4b1913438d Fix #includes in betterRenderer and ci_shadervalidator after file reorganization
Co-authored-by: Hirek193 <23196899+Hirek193@users.noreply.github.com>
2026-03-14 19:26:52 +00:00
Wls50
ff50fdf110 add refraction support for materials; two pass rain shader 2025-12-04 21:43:51 +01:00
Wls50
90538c8878 initial rain material optimizations 2025-12-04 21:43:44 +01:00
Wls50
596ff9d5c2 squash commits from internal:
use gfx queue when loading dynamic textures
fix possible timeout in light culling
exclude lods & transparencies from lod test
add cpu-side submodel structure for ray testing
2025-11-16 19:00:38 +01:00
a39d972126 Some renaming 2025-04-15 01:32:56 +02:00