summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJaron Kent-Dobias <jaron@kent-dobias.com>2022-09-16 17:34:09 +0200
committerJaron Kent-Dobias <jaron@kent-dobias.com>2022-09-16 17:34:09 +0200
commit2d833ad2bf32632a2230ce1ebe28dc8207898ad7 (patch)
treea5eeba5b7a59751154562ee54f092a52faeb5d96
parent8964a534e576c62221e8ca2e9b1445f43292735e (diff)
downloadcode-2d833ad2bf32632a2230ce1ebe28dc8207898ad7.tar.gz
code-2d833ad2bf32632a2230ce1ebe28dc8207898ad7.tar.bz2
code-2d833ad2bf32632a2230ce1ebe28dc8207898ad7.zip
Returned to initializing to zero.
-rw-r--r--rbmp.cpp4
1 files changed, 1 insertions, 3 deletions
diff --git a/rbmp.cpp b/rbmp.cpp
index 1c30528..c34dce4 100644
--- a/rbmp.cpp
+++ b/rbmp.cpp
@@ -34,7 +34,7 @@ public:
double oldX;
double X;
- HalfEdge(const Edge& e) : edge(e) {}
+ HalfEdge(const Edge& e) : edge(e), oldX(0) {}
void setVertices(Vertex& vt, Vertex& vh) {
tail = &vt;
head = &vh;
@@ -85,8 +85,6 @@ public:
Vertex& blueVertex = vertices[M + (i % (2 * n)) / 2 + n * (((i + 2 * n) / 4) / n)];
edges[i].setVertices(redVertex, blueVertex);
edges[i].weight = r.variate<double, std::exponential_distribution>(1);
- edges[i].halfedges[0].oldX = r.variate<double, std::normal_distribution>(0, 1);
- edges[i].halfedges[1].oldX = r.variate<double, std::normal_distribution>(0, 1);
}
}