mirror of
https://github.com/ZDoom/Raze.git
synced 2025-05-30 00:41:24 +00:00
- moved the hires texture replacement logic into a backend callback.
This way it can be handled transparently to the calling code. Fonts do not work yet, though.
This commit is contained in:
parent
8c241afc40
commit
ed599d0f05
12 changed files with 85 additions and 94 deletions
|
@ -586,11 +586,13 @@ private:
|
|||
public:
|
||||
void SetMaterial(FGameTexture* tex, EUpscaleFlags upscalemask, int scaleflags, int clampmode, int translation, int overrideshader)
|
||||
{
|
||||
if (sysCallbacks.PreBindTexture && !sysCallbacks.PreBindTexture(this, tex, upscalemask, clampmode, translation, overrideshader))
|
||||
if (!sysCallbacks.PreBindTexture || !sysCallbacks.PreBindTexture(this, tex, upscalemask, scaleflags, clampmode, translation, overrideshader))
|
||||
{
|
||||
if (shouldUpscale(tex, upscalemask)) scaleflags |= CTF_Upscale;
|
||||
}
|
||||
SetMaterial(FMaterial::ValidateTexture(tex, scaleflags), clampmode, translation, overrideshader);
|
||||
auto mat = FMaterial::ValidateTexture(tex, scaleflags);
|
||||
assert(mat);
|
||||
SetMaterial(mat, clampmode, translation, overrideshader);
|
||||
}
|
||||
|
||||
void SetClipSplit(float bottom, float top)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue