victory-gta6: this fork's changes on top of VIctory main (ffe310e)
World rendering, lighting, frame-rate and memory work for Grand Theft Auto VI (Xbox Series X profile) on one Windows PC with an NVIDIA RTX 4070. The README describes the state, the changes and the credits. Based on VIctory by Marvisak and contributors (GPL-3.0-or-later); XCL by ivall and contributors was used as a reference. No game files are included. Co-Authored-By: Claude Fable 5.2 <[email protected]>
This commit is contained in:
1 parent
45c6e80601
commit
6fa814fba5
61 files changed
+32259
-1274
No files matched your search
@@ -75,7 +75,7 @@ extern "system" fn query(this: This, iid: *const Iid, out: *mut This) -> HRESULT
|
||||
extern "system" fn release(this: This) -> u32 {
|
||||
object::release_boxed::<Fence>(this)
|
||||
}
|
||||
extern "system" fn completed(this: This) -> u64 {
|
||||
pub(crate) extern "system" fn completed(this: This) -> u64 {
|
||||
fence(this).value.load(Ordering::Acquire)
|
||||
}
|
||||
extern "system" fn set_event_on_completion(this: This, value: u64, event: *mut c_void) -> HRESULT {
|
||||
@@ -88,6 +88,19 @@ extern "system" fn set_event_on_completion(this: This, value: u64, event: *mut c
|
||||
return S_OK;
|
||||
}
|
||||
if event.is_null() {
|
||||
// With submissions sent to the card and not waited for
|
||||
// (`crate::host::late`) the signal may be behind them: they are
|
||||
// settled, which sets it.
|
||||
#[cfg(windows)]
|
||||
if crate::host::late() {
|
||||
drop(waiters);
|
||||
crate::host::settle_for_fence();
|
||||
if fence.value.load(Ordering::Acquire) >= value {
|
||||
return S_OK;
|
||||
}
|
||||
tracing::warn!(value, "blocking fence wait not implemented");
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
// shortcut: a null event means "block until reached"; nothing can
|
||||
// reach it while no GPU work runs, so fail instead of hanging.
|
||||
tracing::warn!(value, "blocking fence wait not implemented");
|
||||
@@ -96,7 +109,8 @@ extern "system" fn set_event_on_completion(this: This, value: u64, event: *mut c
|
||||
waiters.push((value, event as usize));
|
||||
S_OK
|
||||
}
|
||||
pub(crate) extern "system" fn signal(this: This, value: u64) -> HRESULT {
|
||||
/// Moves the fence to `value` and sets the events that waited for it.
|
||||
pub(crate) fn set(this: This, value: u64) {
|
||||
let fence = fence(this);
|
||||
let mut waiters = fence.waiters.lock().unwrap_or_else(|e| e.into_inner());
|
||||
fence.value.store(value, Ordering::Release);
|
||||
@@ -107,6 +121,12 @@ pub(crate) extern "system" fn signal(this: This, value: u64) -> HRESULT {
|
||||
}
|
||||
!reached
|
||||
});
|
||||
}
|
||||
pub(crate) extern "system" fn signal(this: This, value: u64) -> HRESULT {
|
||||
set(this, value);
|
||||
// A queue may have waited for it: what it held runs now.
|
||||
#[cfg(windows)]
|
||||
crate::queue::release_held(false);
|
||||
S_OK
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user