mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-11-11 07:11:39 +00:00
Fixes a crash when disabling high-res texture replacements.
git-svn-id: https://svn.eduke32.com/eduke32@1226 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
ee105f1883
commit
6fe53806c7
2 changed files with 4 additions and 4 deletions
|
@ -2628,7 +2628,7 @@ static void polymer_getbuildmaterial(_prmaterial* material, int16_t tile
|
|||
detailpth = NULL;
|
||||
detailpth = gltexcache(tilenum, DETAILPAL, 0);
|
||||
|
||||
if (detailpth && (detailpth->hicr->palnum == DETAILPAL))
|
||||
if (detailpth && detailpth->hicr && (detailpth->hicr->palnum == DETAILPAL))
|
||||
{
|
||||
material->detailmap = detailpth->glpic;
|
||||
|
||||
|
@ -2666,7 +2666,7 @@ static void polymer_getbuildmaterial(_prmaterial* material, int16_t tile
|
|||
glowpth = NULL;
|
||||
glowpth = gltexcache(tilenum, GLOWPAL, 0);
|
||||
|
||||
if (glowpth && (glowpth->hicr->palnum == GLOWPAL))
|
||||
if (glowpth && glowpth->hicr && (glowpth->hicr->palnum == GLOWPAL))
|
||||
material->glowmap = glowpth->glpic;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -2151,7 +2151,7 @@ void drawpoly(double *dpx, double *dpy, int32_t n, int32_t method)
|
|||
hicfindsubst(globalpicnum, DETAILPAL, 0))
|
||||
detailpth = gltexcache(globalpicnum, DETAILPAL, method&(~3));
|
||||
|
||||
if (detailpth && (detailpth->hicr->palnum == DETAILPAL))
|
||||
if (detailpth && detailpth->hicr && (detailpth->hicr->palnum == DETAILPAL))
|
||||
{
|
||||
bglActiveTextureARB(++texunits);
|
||||
|
||||
|
@ -2197,7 +2197,7 @@ void drawpoly(double *dpx, double *dpy, int32_t n, int32_t method)
|
|||
hicfindsubst(globalpicnum, GLOWPAL, 0))
|
||||
glowpth = gltexcache(globalpicnum, GLOWPAL, method&(~3));
|
||||
|
||||
if (glowpth && (glowpth->hicr->palnum == GLOWPAL))
|
||||
if (glowpth && glowpth->hicr && (glowpth->hicr->palnum == GLOWPAL))
|
||||
{
|
||||
bglActiveTextureARB(++texunits);
|
||||
|
||||
|
|
Loading…
Reference in a new issue