implement getComponentBounds for Rail Button to get 3d wireframe
This commit is contained in:
parent
657c407ba5
commit
a1f2dc35fc
@ -281,7 +281,16 @@ public class RailButton extends ExternalComponent implements LineInstanceable {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Collection<Coordinate> getComponentBounds() {
|
public Collection<Coordinate> getComponentBounds() {
|
||||||
|
final double r = outerDiameter_m / 2.0;
|
||||||
ArrayList<Coordinate> set = new ArrayList<Coordinate>();
|
ArrayList<Coordinate> set = new ArrayList<Coordinate>();
|
||||||
|
set.add(new Coordinate(r, totalHeight_m, r));
|
||||||
|
set.add(new Coordinate(r, totalHeight_m, -r));
|
||||||
|
set.add(new Coordinate(r, 0, r));
|
||||||
|
set.add(new Coordinate(r, 0, -r));
|
||||||
|
set.add(new Coordinate(-r, 0, r));
|
||||||
|
set.add(new Coordinate(-r, 0, -r));
|
||||||
|
set.add(new Coordinate(-r, totalHeight_m, r));
|
||||||
|
set.add(new Coordinate(-r, totalHeight_m, -r));
|
||||||
return set;
|
return set;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user