summaryrefslogtreecommitdiff
path: root/src/projection.cc
diff options
context:
space:
mode:
authorMarius Kintel <marius@kintel.net>2012-03-27 22:05:00 (GMT)
committerMarius Kintel <marius@kintel.net>2012-03-27 22:05:58 (GMT)
commit327310f190bbd81c7b71b568d5bf72bb900cc9db (patch)
tree9399bb490ecafe9f0c7fd209c680311d829eb631 /src/projection.cc
parent4394c7a030ce7a08c95bd1af2e8c38ffcf972439 (diff)
Rewrote the Value class to be based on boost::variant - this should reduce memory footprint and improve performance
Diffstat (limited to 'src/projection.cc')
-rw-r--r--src/projection.cc6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/projection.cc b/src/projection.cc
index d3e7e94..1fcf639 100644
--- a/src/projection.cc
+++ b/src/projection.cc
@@ -58,10 +58,10 @@ AbstractNode *ProjectionModule::evaluate(const Context *ctx, const ModuleInstant
Value convexity = c.lookup_variable("convexity", true);
Value cut = c.lookup_variable("cut", true);
- node->convexity = (int)convexity.num;
+ node->convexity = (int)convexity.toDouble();
- if (cut.type == Value::BOOL)
- node->cut_mode = cut.b;
+ if (cut.type() == Value::BOOL)
+ node->cut_mode = cut.toBool();
std::vector<AbstractNode *> evaluatednodes = inst->evaluateChildren();
node->children.insert(node->children.end(), evaluatednodes.begin(), evaluatednodes.end());
contact: Jan Huwald // Impressum