Fix compilation errors in latest texture-related changes

GCC and Clang complain about non-POD type passed to variadic function.
This commit is contained in:
alexey.lysiuk 2014-06-01 10:27:16 +03:00
parent d925279bef
commit a26fbc74f0
6 changed files with 13 additions and 13 deletions

View file

@ -689,7 +689,7 @@ CCMD(listlights)
if (dl->target) if (dl->target)
{ {
FTextureID spr = gl_GetSpriteFrame(dl->target->sprite, dl->target->frame, 0, 0, NULL); FTextureID spr = gl_GetSpriteFrame(dl->target->sprite, dl->target->frame, 0, 0, NULL);
Printf(", frame = %s ", TexMan[spr]->Name); Printf(", frame = %s ", TexMan[spr]->Name.GetChars());
} }

View file

@ -689,7 +689,7 @@ void gl_ParseHardwareShader(FScanner &sc, int deflump)
{ {
if (tex->bWarped != 0) if (tex->bWarped != 0)
{ {
Printf("Cannot combine warping with hardware shader on texture '%s'\n", tex->Name); Printf("Cannot combine warping with hardware shader on texture '%s'\n", tex->Name.GetChars());
return; return;
} }
tex->gl_info.shaderspeed = speed; tex->gl_info.shaderspeed = speed;

View file

@ -177,7 +177,7 @@ int CheckDDPK3(FTexture *tex)
for (const char ** extp=extensions; *extp; extp++) for (const char ** extp=extensions; *extp; extp++)
{ {
checkName.Format(*checklist, tex->Name, *extp); checkName.Format(*checklist, tex->Name.GetChars(), *extp);
int lumpnum = Wads.CheckNumForFullName(checkName); int lumpnum = Wads.CheckNumForFullName(checkName);
if (lumpnum >= 0) return lumpnum; if (lumpnum >= 0) return lumpnum;
} }
@ -358,7 +358,7 @@ int CheckExternalFile(FTexture *tex, bool & hascolorkey)
for (const char ** extp=extensions; *extp; extp++) for (const char ** extp=extensions; *extp; extp++)
{ {
checkName.Format(*checklist, progdir.GetChars(), tex->Name, *extp); checkName.Format(*checklist, progdir.GetChars(), tex->Name.GetChars(), *extp);
if (_access(checkName, 0) == 0) if (_access(checkName, 0) == 0)
{ {
hascolorkey = !!strstr(checkName, "-ck."); hascolorkey = !!strstr(checkName, "-ck.");

View file

@ -1092,7 +1092,7 @@ int FGLTexture::Dump(int i)
{ {
int cnt = 0; int cnt = 0;
int lump = tex->GetSourceLump(); int lump = tex->GetSourceLump();
Printf(PRINT_LOG, "Texture '%s' (Index %d, Lump %d, Name '%s'):\n", tex->Name, i, lump, Wads.GetLumpFullName(lump)); Printf(PRINT_LOG, "Texture '%s' (Index %d, Lump %d, Name '%s'):\n", tex->Name.GetChars(), i, lump, Wads.GetLumpFullName(lump));
if (hirestexture) Printf(PRINT_LOG, "\tHirestexture\n"); if (hirestexture) Printf(PRINT_LOG, "\tHirestexture\n");
if (glpatch) Printf(PRINT_LOG, "\tPatch\n"),cnt++; if (glpatch) Printf(PRINT_LOG, "\tPatch\n"),cnt++;
if (gltexture[0]) Printf(PRINT_LOG, "\tTexture (x:no, y:no )\n"),cnt++; if (gltexture[0]) Printf(PRINT_LOG, "\tTexture (x:no, y:no )\n"),cnt++;

View file

@ -168,7 +168,7 @@ void gl_ParseSkybox(FScanner &sc)
} }
if (facecount != 3 && facecount != 6) if (facecount != 3 && facecount != 6)
{ {
sc.ScriptError("%s: Skybox definition requires either 3 or 6 faces", sb->Name); sc.ScriptError("%s: Skybox definition requires either 3 or 6 faces", sb->Name.GetChars());
} }
sb->SetSize(); sb->SetSize();
TexMan.AddTexture(sb); TexMan.AddTexture(sb);
@ -209,7 +209,7 @@ void gl_ParseVavoomSkybox()
FTexture *tex = TexMan.FindTexture(sc.String, FTexture::TEX_Wall, FTextureManager::TEXMAN_TryAny); FTexture *tex = TexMan.FindTexture(sc.String, FTexture::TEX_Wall, FTextureManager::TEXMAN_TryAny);
if (tex != NULL) if (tex != NULL)
{ {
Printf("Texture '%s' not found in Vavoom skybox '%s'\n", sc.String, sb->Name); Printf("Texture '%s' not found in Vavoom skybox '%s'\n", sc.String, sb->Name.GetChars());
} }
sb->faces[facecount] = tex; sb->faces[facecount] = tex;
sc.MustGetStringName("}"); sc.MustGetStringName("}");
@ -218,7 +218,7 @@ void gl_ParseVavoomSkybox()
} }
if (facecount != 6) if (facecount != 6)
{ {
sc.ScriptError("%s: Skybox definition requires 6 faces", sb->Name); sc.ScriptError("%s: Skybox definition requires 6 faces", sb->Name.GetChars());
} }
sb->SetSize(); sb->SetSize();
TexMan.AddTexture(sb); TexMan.AddTexture(sb);

View file

@ -294,7 +294,7 @@ void FTexture::CreateDefaultBrightmap()
if (GlobalBrightmap.Remap[texbuf[i]] == white) if (GlobalBrightmap.Remap[texbuf[i]] == white)
{ {
// Create a brightmap // Create a brightmap
DPrintf("brightmap created for texture '%s'\n", Name); DPrintf("brightmap created for texture '%s'\n", Name.GetChars());
gl_info.Brightmap = new FBrightmapTexture(this); gl_info.Brightmap = new FBrightmapTexture(this);
gl_info.bBrightmapChecked = 1; gl_info.bBrightmapChecked = 1;
TexMan.AddTexture(gl_info.Brightmap); TexMan.AddTexture(gl_info.Brightmap);
@ -302,7 +302,7 @@ void FTexture::CreateDefaultBrightmap()
} }
} }
// No bright pixels found // No bright pixels found
DPrintf("No bright pixels found in texture '%s'\n", Name); DPrintf("No bright pixels found in texture '%s'\n", Name.GetChars());
gl_info.bBrightmapChecked = 1; gl_info.bBrightmapChecked = 1;
} }
else else
@ -735,13 +735,13 @@ void gl_ParseBrightmap(FScanner &sc, int deflump)
if (bmtex != NULL) if (bmtex != NULL)
{ {
Printf("Multiple brightmap definitions in texture %s\n", tex? tex->Name : "(null)"); Printf("Multiple brightmap definitions in texture %s\n", tex? tex->Name.GetChars() : "(null)");
} }
bmtex = TexMan.FindTexture(sc.String, FTexture::TEX_Any, FTextureManager::TEXMAN_TryAny); bmtex = TexMan.FindTexture(sc.String, FTexture::TEX_Any, FTextureManager::TEXMAN_TryAny);
if (bmtex == NULL) if (bmtex == NULL)
Printf("Brightmap '%s' not found in texture '%s'\n", sc.String, tex? tex->Name : "(null)"); Printf("Brightmap '%s' not found in texture '%s'\n", sc.String, tex? tex->Name.GetChars() : "(null)");
} }
} }
if (!tex) if (!tex)
@ -765,7 +765,7 @@ void gl_ParseBrightmap(FScanner &sc, int deflump)
{ {
if (tex->bWarped != 0) if (tex->bWarped != 0)
{ {
Printf("Cannot combine warping with brightmap on texture '%s'\n", tex->Name); Printf("Cannot combine warping with brightmap on texture '%s'\n", tex->Name.GetChars());
return; return;
} }