diff --git a/src/Magnum/MeshTools/Compile.h b/src/Magnum/MeshTools/Compile.h index 9699d35ec..cd975994f 100644 --- a/src/Magnum/MeshTools/Compile.h +++ b/src/Magnum/MeshTools/Compile.h @@ -58,7 +58,9 @@ enum class CompileFlag: UnsignedByte { * If the mesh is @ref MeshPrimitive::Triangles, generates normals using * @ref MeshTools::generateFlatNormals(). If the mesh is not a triangle * mesh or doesn't have 3D positions, this flag does nothing. If the mesh - * already has its own normals, these get replaced. + * already has its own normals, these get replaced. If + * @ref CompileFlag::GenerateSmoothNormals is specified together with this + * flag, this flag gets a priority. */ GenerateFlatNormals = 1 << 0, diff --git a/src/Magnum/MeshTools/Test/CompileGLTest.cpp b/src/Magnum/MeshTools/Test/CompileGLTest.cpp index 504fd7bc0..d54cebb60 100644 --- a/src/Magnum/MeshTools/Test/CompileGLTest.cpp +++ b/src/Magnum/MeshTools/Test/CompileGLTest.cpp @@ -122,6 +122,7 @@ constexpr struct { {"positions + normals + texcoords", Flag::Normals|Flag::TextureCoordinates2D}, {"positions + normals + texcoords + colors", Flag::Normals|Flag::TextureCoordinates2D|Flag::Colors}, {"positions + gen flat normals", Flag::GeneratedFlatNormals}, + {"positions + gen both smooth and flat normals", Flag::GeneratedSmoothNormals|Flag::GeneratedFlatNormals}, {"positions + normals, gen flat normals", Flag::Normals|Flag::GeneratedFlatNormals}, {"positions + gen flat normals + colors", Flag::GeneratedFlatNormals|Flag::Colors}, {"positions + gen flat normals + texcoords", Flag::GeneratedFlatNormals|Flag::TextureCoordinates2D},