summaryrefslogtreecommitdiff
path: root/src/primitives.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/primitives.cc')
-rw-r--r--src/primitives.cc28
1 files changed, 0 insertions, 28 deletions
diff --git a/src/primitives.cc b/src/primitives.cc
index 4cfb1ce..16c6ab7 100644
--- a/src/primitives.cc
+++ b/src/primitives.cc
@@ -70,9 +70,6 @@ public:
int convexity;
Value points, paths, triangles;
virtual PolySet *render_polyset(render_mode_e mode) const;
-#ifndef REMOVE_DUMP
- virtual QString dump(QString indent) const;
-#endif
};
AbstractNode *PrimitiveModule::evaluate(const Context *ctx, const ModuleInstantiation *inst) const
@@ -529,31 +526,6 @@ sphere_next_r2:
return p;
}
-#ifndef REMOVE_DUMP
-QString PrimitiveNode::dump(QString indent) const
-{
- if (dump_cache.isEmpty()) {
- QString text;
- if (type == CUBE)
- text.sprintf("cube(size = [%g, %g, %g], center = %s);\n", x, y, z, center ? "true" : "false");
- if (type == SPHERE)
- text.sprintf("sphere($fn = %g, $fa = %g, $fs = %g, r = %g);\n", fn, fa, fs, r1);
- if (type == CYLINDER)
- text.sprintf("cylinder($fn = %g, $fa = %g, $fs = %g, h = %g, r1 = %g, r2 = %g, center = %s);\n", fn, fa, fs, h, r1, r2, center ? "true" : "false");
- if (type == POLYHEDRON)
- text.sprintf("polyhedron(points = %s, triangles = %s, convexity = %d);\n", points.dump().toAscii().data(), triangles.dump().toAscii().data(), convexity);
- if (type == SQUARE)
- text.sprintf("square(size = [%g, %g], center = %s);\n", x, y, center ? "true" : "false");
- if (type == CIRCLE)
- text.sprintf("circle($fn = %g, $fa = %g, $fs = %g, r = %g);\n", fn, fa, fs, r1);
- if (type == POLYGON)
- text.sprintf("polygon(points = %s, paths = %s, convexity = %d);\n", points.dump().toAscii().data(), paths.dump().toAscii().data(), convexity);
- ((AbstractNode*)this)->dump_cache = indent + QString("n%1: ").arg(idx) + text;
- }
- return dump_cache;
-}
-#endif
-
std::string PrimitiveNode::toString() const
{
std::stringstream stream;
contact: Jan Huwald // Impressum