mirror of
https://github.com/memononen/nanovg
synced 2026-09-26 16:19:07 +03:00
Merge pull request #405 from Joshua-Ashton/master
Fix MSVC 2017 compiler warning
This commit is contained in:
commit
e3033362e5
1 changed files with 7 additions and 0 deletions
|
|
@ -945,10 +945,17 @@ static int glnvg__convertPaint(GLNVGcontext* gl, GLNVGfragUniforms* frag, NVGpai
|
|||
}
|
||||
frag->type = NSVG_SHADER_FILLIMG;
|
||||
|
||||
#if NANOVG_GL_USE_UNIFORMBUFFER
|
||||
if (tex->type == NVG_TEXTURE_RGBA)
|
||||
frag->texType = (tex->flags & NVG_IMAGE_PREMULTIPLIED) ? 0 : 1;
|
||||
else
|
||||
frag->texType = 2;
|
||||
#else
|
||||
if (tex->type == NVG_TEXTURE_RGBA)
|
||||
frag->texType = (tex->flags & NVG_IMAGE_PREMULTIPLIED) ? 0.0f : 1.0f;
|
||||
else
|
||||
frag->texType = 2.0f;
|
||||
#endif
|
||||
// printf("frag->texType = %d\n", frag->texType);
|
||||
} else {
|
||||
frag->type = NSVG_SHADER_FILLGRAD;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue