Build 8534
SVN-
Generale
game.h: fix calc_smoothratio_demo() to take into account differences between timerGetClockRate() and TICRATE when calculating the refresh frequency to interpolate between
Nickname SVN e nomi Git sono unificati per persona.
game.h: fix calc_smoothratio_demo() to take into account differences between timerGetClockRate() and TICRATE when calculating the refresh frequency to interpolate between
polymost.cpp: fix buffer overflow issue in uploadpalswap() & correct the code to initialize an extra row of black pixels
clockticks.hpp: Fix issue where higher precision comparisons would cause unexpected behaviour with game loop code due to ototalclock being incremented rather than set to totalclock (causing a lack of subtick precision and potential doubled up/dropped game updates).
Provide compareHighPrecision() for any code that needs higher precision comparisons.
kenbuild/src/game.cpp: Fix compilation issue due to removal of sqr() from pragmas.h in r7597
Change some clocks to support sub-tick precision using a new class, ClockTicks.
Using that higher precision, interpolate at a higher granularity. Further, truncate the target interpolation time to vertical blank boundaries to avoid producing temporal artifacts. Fix issues caused by interpolation calculations being handled differently in multiple places (and fix cases where smoothratios were being thrown away only to be redone without checking all proper conditions). Ensure ClockTicks changes do not break other targets (EKenBuild, VoidSW), but note any interpolation there is not similarly updated.
timer.cpp: fix order of operations issue with timerUpdate()
sounds.cpp: fix infinite loop caused by removal of "else" in r7939
Fix issue with indexed colour textures where in the case that tiles entered the texcache while !waloff[picnum] & were later (re)loaded, the earlier pth pointing to the tilesheet containing the blank tile would never be properly replaced with an updated gl texture.
gameexec.cpp: allow G_ShowView() to execute regardless of the state of g_screenCapture.
This fixes skyboxes not rendering in TILE_SAVESHOT.
tiles.cpp: backup & restore picsiz, walock, & waloff alongside other per tile arrays in artClearMapArt() and artSetupMapArt()
This fixes an issue with viewscreens as tiles that are setup game-side after a map is loaded could have their sizes reset to 0 while not being properly cleared from walock/waloff
engine.cpp: make renderSetTarget() more robust so that passing an xsiz or ysiz <= 0 is not accepted and can't cause a segmentation fault
polymer.cpp: fix issue where assert could fail due to HUD model sprites having an owner >= MAXSPRITES
polymost.cpp: Fix issue where tiles whose dimensions had grown would not have their sizes updated in GL and could fail to update their texture data
Fix mixing offscreenrendering (render targets) and mirrors. Don't allow recursing beyond 1 level of mirroring through multiple levels of render targets.
Fix rendering skyboxes to a tile by altering renderSetTarget() & renderRestoreTarget() to set & reset xdim & ydim so that G_ShowView() can render while a render target is set,
and additionally modifying G_SetupCamTile() to call EVENT_DISPLAYROOMSCAMERATILE after calling renderSetTarget()
Fix edge case where mirrors & TROR could interact and render over skyboxes in the classic software renderer
Fix parallel build by switching to generating .obj files from .glsl files and treat the shader source as an externed global resolved at link time.
Additionally, remove the no longer necessary shader generated headers folder from .gitignore
osdfuncs.cpp: fix OSD background sometimes not rendering with the correct gl state
Fix 32-bit Polymost issues by enabling SSE instructions and setting GCC to use SSE floating point math exclusively.
Additionally, enable SSE2 to better match 64-bit builds and use -malign-double for the potential performance benefit.
polymost.cpp: Fix polymost_domost() issue with COMBINE_STRIPS where in certain cases, merging with the viewport nodes caused accidental reading of sentinel node values.
Additional debug code is included for visualizing the state of the vsp data structure. Further, fix issue in drawpoly where it would access out of bounds of dpxy if fewer than 3 vertices were passed in and fix issue where multiple calls to polymost_setVisibility() were repeatedly setting the visibility factor to the same value.
winlayer.cpp: fix videoBeginDrawing() to return an intptr_t to mirrorBuffer when inpreparemirror
Fix TROR & skyboxes to work with mirrors in Software & Polymost
game.cpp: fix issue where tilt angle was not being reset to 0 at times when it should have been disabled
Fix latency issue introduced by G_FPSLimit() handling of videoNextPage() that was causing frames to be delayed presentation until after the next frame is prepared.
videoNextPage() is now called immediately after preparing the frame for drawing, outside of G_FPSLimit() but on the condition that its return value is true.
engine.cpp: fix sprite sorting/adjustment issue introduced in r7612 that caused sprites with the same y value at the end of the sorted array to not be adjusted properly
polymost.cpp: Fix issue where state would not be reset properly in polymost_drawmaskwall() when rendering translucent maskwalls with no texture
polymost.cpp: fix polymost_dorotatesprite() alpha test/blend issue introduced in r7619
polymost.cpp: fix issue where floors & ceilings with DAMETH_MASKPROPS were not being blended
engine.cpp: fix bug in killsprite where sprites were not being removed properly after sorting changes