The depth bounds test works (#82); faster defaults; textures are on the card before the character bake; one host copy per placed texture
- The depth bounds test (#82 by Kaivyyy, as is): a pipeline that enables it is made from a DEPTH_STENCIL1 stream under its own library name, and the title's OMSetDepthBounds reaches the host list. Before, such draws passed at every depth. On the test machine (RTX 4070) the first room is lit by its lamp for the first time: walls, table, bunks. - Defaults: what shaders wrote is copied back by a thread of its own (stage 2), wide copy-back, card copies from 1 MiB up to 1,024 MB, and 256 lists in the air. About 230 ms a frame where it was about 400. Off: VICTORY_RELAY=0, VICTORY_WIDE_BACK=0, VICTORY_CARD_BUFFERS_MIN_MB=16 VICTORY_CARD_BUFFERS_MB=512, VICTORY_LATE_WAIT_LISTS=128. - Textures picked by index are uploaded while loading and before a draw of the title's decoration bake, which samples them by index and runs once (VICTORY_EARLY_TEXTURES_MS, VICTORY_BAKE_TEXTURES_MS; 0 turns each off). - Placed textures are keyed without the filler words of their description: two views that differed only there each had a host copy (VICTORY_PLACED_FILLER=1 keeps the old key). - VICTORY_TEXTURE_ROOM_PERCENT (90, unchanged) sets how full the card may get before textures picked by index wait. Known: the first room's walls are still missing in some launches, and shaded areas are too dark (the bounce light has no ray-tracing structure to trace yet). Co-Authored-By: Claude Fable 5.2 <[email protected]>
This commit is contained in:
1 parent
a803c87c48
commit
c96b4f2b83
8 files changed
+761
-76
No files matched your search
@@ -151,7 +151,11 @@ fn card_limits() -> (u64, u64) {
|
||||
let mb = |name: &str, default: u64| {
|
||||
std::env::var(name).ok().and_then(|v| v.trim().parse::<u64>().ok()).unwrap_or(default) << 20
|
||||
};
|
||||
(mb("VICTORY_CARD_BUFFERS_MIN_MB", 16).max(1 << 20), mb("VICTORY_CARD_BUFFERS_MB", 512))
|
||||
// From 1 MiB up and 1,024 MB in all by default (it was 16 and 512):
|
||||
// the shader writes of the smaller buffers are then found by the
|
||||
// card's hashes too, and with that the first room's walls were
|
||||
// drawn in every run.
|
||||
(mb("VICTORY_CARD_BUFFERS_MIN_MB", 1).max(1 << 20), mb("VICTORY_CARD_BUFFERS_MB", 1024))
|
||||
})
|
||||
}
|
||||
|
||||
@@ -470,7 +474,12 @@ mod card_tests {
|
||||
/// had not received from bytes the card wrote.
|
||||
pub(crate) fn relay() -> bool {
|
||||
static ON: std::sync::OnceLock<bool> = std::sync::OnceLock::new();
|
||||
*ON.get_or_init(|| std::env::var("VICTORY_RELAY").is_ok_and(|v| v == "1" || v == "2") && !keeps())
|
||||
// On by default (stage 2, `crate::host::relay_exact`); `VICTORY_RELAY=0`
|
||||
// turns it off, `=1` asks for the first stage.
|
||||
// The crate's own tests run without it unless they ask: several of
|
||||
// them look at title memory right after a submission, which the
|
||||
// relay's landing thread may still be writing.
|
||||
*ON.get_or_init(|| std::env::var("VICTORY_RELAY").map_or(!cfg!(test), |v| v == "1" || v == "2") && !keeps())
|
||||
}
|
||||
|
||||
/// The submission being prepared (its number among those started): what
|
||||
@@ -958,7 +967,8 @@ unsafe fn copy_wide(src: *const u8, dst: *mut u8, len: usize) {
|
||||
/// lists only afterwards).
|
||||
pub(crate) fn wide_back() -> bool {
|
||||
static ON: std::sync::OnceLock<bool> = std::sync::OnceLock::new();
|
||||
*ON.get_or_init(|| std::env::var_os("VICTORY_WIDE_BACK").is_some_and(|v| v == "1"))
|
||||
// On by default; `VICTORY_WIDE_BACK=0` turns it off.
|
||||
*ON.get_or_init(|| std::env::var_os("VICTORY_WIDE_BACK").is_none_or(|v| v != "0"))
|
||||
}
|
||||
|
||||
type Job = Box<dyn FnOnce() + Send>;
|
||||
|
||||
Reference in new issue
Block a user