Skip to content

Commit

Permalink
xrRender: Clang is more strict with integer narrowing
Browse files Browse the repository at this point in the history
  • Loading branch information
Zegeri committed Oct 1, 2018
1 parent 5365fe6 commit b177189
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/Layers/xrRender/dxConsoleRender.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ void dxConsoleRender::OnRender(bool bGame)
{
VERIFY(HW.pDevice);

D3DRECT R = {0, 0, Device.dwWidth, Device.dwHeight};
D3DRECT R = {0, 0, static_cast<LONG>(Device.dwWidth), static_cast<LONG>(Device.dwHeight)};
if (bGame)
R.y2 /= 2;

Expand Down
4 changes: 2 additions & 2 deletions src/Layers/xrRenderGL/glState.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -226,8 +226,8 @@ void glState::UpdateSamplerState(u32 stage, u32 name, u32 value)
break;
case D3DSAMP_BORDERCOLOR: /* D3DCOLOR */
{
GLint color[] = {color_get_R(value), color_get_G(value), color_get_B(value), color_get_A(value)};
CHK_GL(glSamplerParameteriv(m_samplerArray[stage], GL_TEXTURE_BORDER_COLOR, color));
GLuint color[] = {color_get_R(value), color_get_G(value), color_get_B(value), color_get_A(value)};
CHK_GL(glSamplerParameterIuiv(m_samplerArray[stage], GL_TEXTURE_BORDER_COLOR, color));
}
break;
case D3DSAMP_MAGFILTER: /* D3DTEXTUREFILTER filter to use for magnification */
Expand Down

0 comments on commit b177189

Please sign in to comment.