Fixup comment

This commit is contained in:
Corentin Wallez 2018-04-13 11:51:59 -04:00
parent ac49ed0779
commit 9ce29d1104
1 changed files with 2 additions and 1 deletions

View File

@ -129,7 +129,8 @@ namespace backend { namespace opengl {
break; break;
case PushConstantType::Float: case PushConstantType::Float:
float value; float value;
// Use a memcpy to avoid strict-aliasing warnings. // Use a memcpy to avoid strict-aliasing warnings, even if it is still
// technically undefined behavior.
memcpy(&value, &mValues[stage][constant], sizeof(value)); memcpy(&value, &mValues[stage][constant], sizeof(value));
glUniform1f(location, value); glUniform1f(location, value);
break; break;