Normand Briere
2019-09-22 e96132853038f55cdb6e27f116852cff0e813f00
Spline.java
....@@ -19,9 +19,9 @@
1919 return spline;
2020 }
2121
22
- protected void deepCopySelf(Object3D other)
22
+ protected void deepCopyNode(Object3D other)
2323 {
24
- super.deepCopySelf(other);
24
+ super.deepCopyNode(other);
2525 Spline spline = (Spline)other;
2626 spline.type = type;
2727 int count = ctrlPnts.size();
....@@ -157,11 +157,13 @@
157157 Point prev = new Point(0, 0);
158158 Point curr = new Point(0, 0);
159159 Rectangle dummy = new Rectangle();
160
- calcHotSpot(sample, info, prev, dummy);
160
+ calcHotSpot(sample, //info,
161
+ prev, dummy);
161162 for (double t = 0.1; t < 1.01; t += 0.1)
162163 {
163164 solve(t, a, b, c, d, sample);
164
- calcHotSpot(sample, info, curr, dummy);
165
+ calcHotSpot(sample, //info,
166
+ curr, dummy);
165167 info.g.drawLine(prev.x, prev.y, curr.x, curr.y);
166168 info.g.drawLine(prev.x, prev.y + 1, curr.x, curr.y + 1);
167169 info.g.drawLine(prev.x + 1, prev.y, curr.x + 1, curr.y);
....@@ -181,7 +183,7 @@
181183 for (int i=0; i < count; i++)
182184 {
183185 cVector p = (cVector)ctrlPnts.elementAt(i);
184
- Rectangle spot = calcHotSpot(p, info);
186
+ Rectangle spot = calcHotSpot(p); //, info);
185187 info.g.fillRect(spot.x, spot.y, spot.width, spot.height);
186188 }
187189
....@@ -197,7 +199,7 @@
197199 for (int i=0; i < nPoints; i++)
198200 {
199201 cVector p = (cVector)ctrlPnts.elementAt(i);
200
- Rectangle r = calcHotSpot(p, info);
202
+ Rectangle r = calcHotSpot(p); //, info);
201203 if (r.contains(info.x, info.y))
202204 {
203205 hitSomething = true;
....@@ -235,7 +237,8 @@
235237 for (double t = 0; t < 1.001; t += 0.01)
236238 {
237239 solve(t, a, b, c, d, sample);
238
- calcHotSpot(sample, info, pnt, rect);
240
+ calcHotSpot(sample, //info,
241
+ pnt, rect);
239242 if (!rect.contains(info.x, info.y))
240243 continue;
241244 hitSomething = true;