PlanePrimitiveShapeConstructor.cpp
Go to the documentation of this file.
2
4#include "ScoreComputer.h"
5#include <GfxTL/NullClass.h>
6
7size_t
12
13unsigned int
18
21 const MiscLib::Vector<Vec3f>&) const
22{
23 return new PlanePrimitiveShape(points[0], points[1], points[2]);
24}
25
28{
29 Plane plane;
30 if (!plane.Init(samples))
31 {
32 return NULL;
33 }
34 return new PlanePrimitiveShape(plane);
35}
36
38PlanePrimitiveShapeConstructor::Deserialize(std::istream* i, bool binary) const
39{
40 Plane plane;
41 plane.Init(binary, i);
42 PlanePrimitiveShape* shape = new PlanePrimitiveShape(plane);
43 return shape;
44}
45
46size_t
class DLL_LINKAGE PlanePrimitiveShape
PrimitiveShape * Deserialize(std::istream *i, bool binary=true) const
PrimitiveShape * Construct(const MiscLib::Vector< Vec3f > &points, const MiscLib::Vector< Vec3f > &normals) const
Definition Plane.h:19
static size_t SerializedSize()
Definition Plane.cpp:259
bool Init(Vec3f p1, Vec3f p2, Vec3f p3)
Definition Plane.cpp:30
PrimtiveShape is a shape primitive in conjunction with a parametrization.