mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-11-10 23:02:03 +00:00
- fixed some bad setup in SetTextureInternal.
This commit is contained in:
parent
2162ce1f26
commit
abaa1d19ee
1 changed files with 7 additions and 2 deletions
|
@ -160,7 +160,12 @@ bool GLInstance::SetTextureInternal(int picnum, FTexture* tex, int palette, int
|
|||
if (mtex)
|
||||
{
|
||||
auto sampler = (method & DAMETH_CLAMPED) ? (sampleroverride != -1 ? sampleroverride : SamplerClampXY) : SamplerRepeat;
|
||||
if (TextureType == TT_INDEXED) sampler = sampler + SamplerNoFilterRepeat - SamplerRepeat;
|
||||
if (TextureType == TT_INDEXED)
|
||||
{
|
||||
renderState.Flags |= RF_UsePalette;
|
||||
sampler = sampler + SamplerNoFilterRepeat - SamplerRepeat;
|
||||
}
|
||||
else renderState.Flags &= ~RF_UsePalette;
|
||||
|
||||
BindTexture(0, mtex, sampler);
|
||||
if (rep && (rep->scale.x != 1.0f || rep->scale.y != 1.0f || xpanning != 0 || ypanning != 0))
|
||||
|
@ -247,7 +252,7 @@ bool GLInstance::SetTextureInternal(int picnum, FTexture* tex, int palette, int
|
|||
}
|
||||
else return false;
|
||||
|
||||
float al = 0;
|
||||
float al = 0.5f;
|
||||
if (TextureType == TT_HICREPLACE)
|
||||
{
|
||||
al = ((unsigned)picnum < MAXTILES && alphahackarray[picnum] != 0) ? alphahackarray[picnum] * (1.f / 255.f) :
|
||||
|
|
Loading…
Reference in a new issue