mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-04-16 17:13:52 +00:00
refactor: name memory/taxi constants, add camera jitter why-comment
- memory_monitor: extract kOneGB and kFallbackRAM constants from 6 duplicated 1024*1024*1024 expressions; name kFieldPrefixLen for /proc/meminfo "MemAvailable:" offset (was bare 13) - camera: add why-comment on projection matrix jitter — column 2 holds NDC x/y offset for TAA/FSR2 sub-pixel sampling - movement_handler: name kMaxTaxiNodeId (384) with why-comment — WotLK TaxiNodes.dbc has 384 entries, bitmask is 12 × uint32
This commit is contained in:
parent
548828f2ee
commit
7b4fdaa277
3 changed files with 22 additions and 11 deletions
|
|
@ -48,7 +48,10 @@ glm::vec3 Camera::getUp() const {
|
|||
}
|
||||
|
||||
void Camera::setJitter(float jx, float jy) {
|
||||
// Remove old jitter, apply new
|
||||
// Sub-pixel jitter for temporal anti-aliasing (TAA / FSR2).
|
||||
// Column 2 of the projection matrix holds the NDC x/y offset — modifying
|
||||
// [2][0] and [2][1] shifts the entire rendered image by a sub-pixel amount
|
||||
// each frame, giving the upscaler different sample positions to reconstruct.
|
||||
projectionMatrix[2][0] -= jitterOffset.x;
|
||||
projectionMatrix[2][1] -= jitterOffset.y;
|
||||
jitterOffset = glm::vec2(jx, jy);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue