Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
53 commits
Select commit Hold shift + click to select a range
eb1a860
surfel rendering initial
Try May 26, 2026
01963e7
spatial hashing in progress
Try May 27, 2026
a71d7f3
spatial hashing in progress
Try May 27, 2026
3138a72
Merge branch 'master' into gi-rendering-2
Try May 28, 2026
79f3e05
improve hash functions
Try May 28, 2026
12a028e
irradiance cache first prototype
Try May 31, 2026
706b756
new surfels clustering method
Try Jun 1, 2026
a8b34fd
surfel apply pass initial
Try Jun 1, 2026
55a92ed
surf vote: account for normals
Try Jun 2, 2026
3795e99
tile based irradiance cache
Try Jun 2, 2026
2b0d0b0
tile-based surfels in progress
Try Jun 2, 2026
b01bf0c
bvh of surfels
Try Jun 5, 2026
c5721c9
bvh in progress
Try Jun 5, 2026
fc55332
surfels binning and weight function
Try Jun 6, 2026
6c04c92
surfels in progress
Try Jun 7, 2026
6c779d8
surfel pathtrace initial
Try Jun 7, 2026
ccbe245
cleanup
Try Jun 7, 2026
dd97351
cleanup
Try Jun 7, 2026
49710a5
random generation lib
Try Jun 8, 2026
a28a2a0
optimize surfel pt
Try Jun 8, 2026
5dbfb14
pt adjustment
Try Jun 8, 2026
f22630b
refactor
Try Jun 9, 2026
76d3958
surfel reuse initial
Try Jun 11, 2026
2d55eea
surfel reuse initial
Try Jun 11, 2026
fae3d7b
improve apply pass
Try Jun 12, 2026
a4bd102
optimization
Try Jun 12, 2026
3036acb
surfels in progress
Try Jun 13, 2026
80991f4
improve surfel interpolation
Try Jun 13, 2026
7b9fcce
cleanup
Try Jun 14, 2026
7565fc0
remove surfel bvh
Try Jun 14, 2026
781e642
multipass surfel allocation
Try Jun 15, 2026
71d412f
improve surfel allocation
Try Jun 16, 2026
431e35c
commandline
Try Jun 17, 2026
5847924
gi toggles
Try Jun 17, 2026
acc88da
aggressive prune on high coverage areas
Try Jun 18, 2026
6b11c76
cleanup
Try Jun 18, 2026
98be5e8
Wendland weighting for surfels
Try Jun 20, 2026
b5da82a
blue-noise based allocator initial
Try Jun 23, 2026
0bdace6
progress
Try Jun 24, 2026
2449b02
2-pass surfel allocator initial
Try Jun 25, 2026
bb7c33c
progress
Try Jun 25, 2026
8afbe74
clowd elimination in progress
Try Jun 26, 2026
99c6b30
improve surfel gc
Try Jun 27, 2026
1259109
gc in progress
Try Jun 28, 2026
071a5c0
progress
Try Jun 28, 2026
c73d452
cleanup surfels code
Try Jun 29, 2026
1bd8df0
cleanup
Try Jun 29, 2026
7567851
refactor away frustrum culling and state update
Try Jun 29, 2026
6405bc9
debug counter for surfels
Try Jun 30, 2026
911123a
fixup surfel culling
Try Jun 30, 2026
e821422
simplify surfel gc
Try Jun 30, 2026
3323e94
cleanup
Try Jun 30, 2026
7b6ac35
cleanup
Try Jun 30, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 12 additions & 4 deletions game/commandline.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,12 @@ static bool boolArg(std::string_view v) {
return std::string_view(v)!="0" && std::string_view(v)!="false";
}

static int intArg(std::string_view v) {
if(v=="false")
return 0;
return (std::stoi(std::string(v)));
}

CommandLine::CommandLine(int argc, const char** argv) {
instance = this;
if(argc<1)
Expand Down Expand Up @@ -114,8 +120,8 @@ CommandLine::CommandLine(int argc, const char** argv) {
++i;
if(i<argc) {
try {
aaPresetId = uint32_t(std::stoul(std::string(argv[i])));
aaPresetId = std::clamp(aaPresetId, 0u, uint32_t(AaPreset::PRESETS_COUNT)-1u);
const int arg = std::max(0, intArg(argv[i]));
aaPresetId = std::clamp(uint32_t(arg), 0u, uint32_t(AaPreset::PRESETS_COUNT)-1u);
}
catch (const std::exception& e) {
Log::i("failed to read cmaa2 preset: \"", std::string(argv[i]), "\"");
Expand All @@ -124,8 +130,10 @@ CommandLine::CommandLine(int argc, const char** argv) {
}
else if(arg=="-gi") {
++i;
if(i<argc)
isGi = boolArg(argv[i]);
if(i<argc) {
const int arg = std::max(0, intArg(argv[i]));
isGi = GiMethod(std::clamp(arg, 0, GiMethod::Count-1));
}
}
else if(arg=="-ms") {
++i;
Expand Down
4 changes: 2 additions & 2 deletions game/commandline.h
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ class CommandLine {
bool isValidationMode() const { return isDebug; }
bool isWindowMode() const { return isWindow; }
bool isRayQuery() const { return isRQuery; }
bool isRtGi() const { return isGi; }
GiMethod isRtGi() const { return isGi; }
bool isMeshShading() const { return isMeshSh; }
bool isBindless() const { return isBindlessSh; }
bool isVirtualShadow() const { return isVsm; }
Expand Down Expand Up @@ -74,7 +74,7 @@ class CommandLine {
bool isBindlessSh = true;
bool isVsm = false;
bool isRtSm = false;
bool isGi = false;
GiMethod isGi = GiMethod::None;
bool forceG1 = false;
bool forceG2 = false;
bool forceG2NR = false;
Expand Down
7 changes: 7 additions & 0 deletions game/game/constants.h
Original file line number Diff line number Diff line change
Expand Up @@ -540,3 +540,10 @@ enum class Benchmark : uint8_t {
Normal,
CiTooling
};

enum GiMethod : uint8_t {
None,
Probes, // legacy
IrrC,
Count
};
2 changes: 1 addition & 1 deletion game/gothic.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ Gothic::Gothic() {
auto& gpu = Resources::device().properties();
if(gpu.raytracing.rayQuery) {
opts.doRayQuery = CommandLine::inst().isRayQuery();
opts.doRtGi = opts.doRayQuery && CommandLine::inst().isRtGi();
opts.doGi = CommandLine::inst().isRtGi();
}

if(hasMeshShader()) {
Expand Down
2 changes: 1 addition & 1 deletion game/gothic.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ class Gothic final {

struct Options {
bool doRayQuery = false;
bool doRtGi = false;
GiMethod doGi = GiMethod::None;
bool doMeshShading = false;
bool doBindless = false;
bool doVirtualShadow = false;
Expand Down
Loading
Loading