Browse Source

Added normals to Plane primitive.

pull/279/head
Vladimír Vondruš 14 years ago
parent
commit
5cee018ec1
  1. 7
      src/Primitives/Plane.cpp
  2. 2
      src/Primitives/Plane.h

7
src/Primitives/Plane.cpp

@ -24,6 +24,11 @@ Plane::Plane(): MeshData(Mesh::Primitive::TriangleStrip, nullptr, {new vector<Ve
{1.0f, 1.0f, 0.0f}, {1.0f, 1.0f, 0.0f},
{-1.0f, -1.0f, 0.0f}, {-1.0f, -1.0f, 0.0f},
{-1.0f, 1.0f, 0.0f} {-1.0f, 1.0f, 0.0f}
}}, {}, {}) {} }}, {new vector<Vector3>{
{0.0f, 0.0f, 1.0f},
{0.0f, 0.0f, 1.0f},
{0.0f, 0.0f, 1.0f},
{0.0f, 0.0f, 1.0f}
}}, {}) {}
}} }}

2
src/Primitives/Plane.h

@ -26,7 +26,7 @@ namespace Magnum { namespace Primitives {
/** /**
@brief %Plane primitive @brief %Plane primitive
2x2 plane orthogonal to Z axis. 2x2 plane with normals in positive Z direction.
*/ */
class Plane: public Trade::MeshData { class Plane: public Trade::MeshData {
public: public:

Loading…
Cancel
Save