mirror of
https://github.com/ZDoom/gzdoom-gles.git
synced 2024-11-29 07:22:07 +00:00
Fixed a few compilation warnings
src/gl/renderer/gl_renderer.cpp:775:39: warning: comparison of two values with different enumeration types ('F2DDrawer::ETextureDrawMode' and 'TexMode') [-Wenum-compare] src/gl/renderer/gl_renderer.cpp:776:39: warning: comparison of two values with different enumeration types ('F2DDrawer::ETextureDrawMode' and 'TexMode') [-Wenum-compare] src/gl/renderer/gl_renderer.cpp:777:39: warning: comparison of two values with different enumeration types ('F2DDrawer::ETextureDrawMode' and 'TexMode') [-Wenum-compare] src/gl/renderer/gl_renderer.cpp:778:45: warning: comparison of two values with different enumeration types ('F2DDrawer::ETextureDrawMode' and 'TexMode') [-Wenum-compare] src/gl/renderer/gl_renderer.cpp:779:40: warning: comparison of two values with different enumeration types ('F2DDrawer::ETextureDrawMode' and 'TexMode') [-Wenum-compare] src/gl/renderer/gl_renderer.cpp:780:45: warning: comparison of two values with different enumeration types ('F2DDrawer::ETextureDrawMode' and 'TexMode') [-Wenum-compare] src/v_draw.cpp:1144:51: warning: '&' within '|' [-Wbitwise-op-parentheses] src/textures/texture.cpp:1050:20: warning: comparison of integers of different signs: 'int' and 'unsigned long' [-Wsign-compare] src\intermission\intermission.cpp(80): warning C4101: 'lumpnum': unreferenced local variable
This commit is contained in:
parent
018f5b8d05
commit
8cd3cf04e7
4 changed files with 8 additions and 10 deletions
|
@ -778,12 +778,12 @@ void FGLRenderer::Draw2D(F2DDrawer *drawer)
|
|||
gl_RenderState.BlendFunc(sb, db);
|
||||
|
||||
// Rather than adding remapping code, let's enforce that the constants here are equal.
|
||||
static_assert(F2DDrawer::DTM_Normal == TM_MODULATE, "DTM_Normal != TM_MODULATE");
|
||||
static_assert(F2DDrawer::DTM_Opaque == TM_OPAQUE, "DTM_Opaque != TM_OPAQUE");
|
||||
static_assert(F2DDrawer::DTM_Invert == TM_INVERSE, "DTM_Invert != TM_INVERSE");
|
||||
static_assert(F2DDrawer::DTM_InvertOpaque == TM_INVERTOPAQUE, "DTM_InvertOpaque != TM_INVERTOPAQUE");
|
||||
static_assert(F2DDrawer::DTM_Stencil == TM_MASK, "DTM_Stencil != TM_MASK");
|
||||
static_assert(F2DDrawer::DTM_AlphaTexture == TM_REDTOALPHA, "DTM_AlphaTexture != TM_REDTOALPHA");
|
||||
static_assert(int(F2DDrawer::DTM_Normal) == int(TM_MODULATE), "DTM_Normal != TM_MODULATE");
|
||||
static_assert(int(F2DDrawer::DTM_Opaque) == int(TM_OPAQUE), "DTM_Opaque != TM_OPAQUE");
|
||||
static_assert(int(F2DDrawer::DTM_Invert) == int(TM_INVERSE), "DTM_Invert != TM_INVERSE");
|
||||
static_assert(int(F2DDrawer::DTM_InvertOpaque) == int(TM_INVERTOPAQUE), "DTM_InvertOpaque != TM_INVERTOPAQUE");
|
||||
static_assert(int(F2DDrawer::DTM_Stencil) == int(TM_MASK), "DTM_Stencil != TM_MASK");
|
||||
static_assert(int(F2DDrawer::DTM_AlphaTexture) == int(TM_REDTOALPHA), "DTM_AlphaTexture != TM_REDTOALPHA");
|
||||
gl_RenderState.SetTextureMode(cmd.mDrawMode);
|
||||
if (cmd.mFlags & F2DDrawer::DTF_Scissor)
|
||||
{
|
||||
|
|
|
@ -77,8 +77,6 @@ CVAR(Bool, nointerscrollabort, false, CVAR_ARCHIVE | CVAR_GLOBALCONFIG);
|
|||
|
||||
void DIntermissionScreen::Init(FIntermissionAction *desc, bool first)
|
||||
{
|
||||
int lumpnum;
|
||||
|
||||
if (desc->mCdTrack == 0 || !S_ChangeCDMusic (desc->mCdTrack, desc->mCdId))
|
||||
{
|
||||
if (desc->mMusic.IsEmpty())
|
||||
|
|
|
@ -1047,7 +1047,7 @@ void FTexture::AddAutoMaterials()
|
|||
if (dot > slash) searchname.Truncate(dot);
|
||||
}
|
||||
|
||||
for (int i = 0; i < countof(autosearchpaths); i++)
|
||||
for (size_t i = 0; i < countof(autosearchpaths); i++)
|
||||
{
|
||||
auto &layer = autosearchpaths[i];
|
||||
if (this->*(layer.pointer) == nullptr) // only if no explicit assignment had been done.
|
||||
|
|
|
@ -1141,7 +1141,7 @@ void DFrameBuffer::DoDim(PalEntry color, float amount, int x1, int y1, int w, in
|
|||
{
|
||||
amount = 1;
|
||||
}
|
||||
m2DDrawer.AddColorOnlyQuad(x1, y1, w, h, color.d & 0xffffff | (int(amount * 255) << 24), style);
|
||||
m2DDrawer.AddColorOnlyQuad(x1, y1, w, h, (color.d & 0xffffff) | (int(amount * 255) << 24), style);
|
||||
}
|
||||
|
||||
void DFrameBuffer::Dim(PalEntry color, float damount, int x1, int y1, int w, int h, FRenderStyle *style)
|
||||
|
|
Loading…
Reference in a new issue