protected void populateFlightPaths() { ShapeAttributes attrs = new ShapeAttributes(); attrs.getInteriorColor().set(0.8f, 0.8f, 1.0f, 0.8f); attrs.getOutlineColor().set(1.0f, 1.0f, 0.0f, 1.0f); Airport dept = this.airportIkoIndex.get("KSEA"); for (Airport dest : this.airportTable) { if (dest.equals(dept)) { continue; // the destination and departure must be different } if (dest.iko.length() != 4) { continue; // the destination must be a major airfield } if (!dest.na3.startsWith("US")) { continue; // the destination must be in the United States } if (!dest.use.equals("49")) { continue; // the destination must a Civilian/Public airport } List<Position> positions = new ArrayList<>(); positions.add(dept.pos); Path path = new Path(positions, attrs); path.putUserProperty("dept", dept); path.putUserProperty("dest", dest); this.flightPathLayer.addRenderable(path); } }
positions.add(Position.fromDegrees(Double.parseDouble(xy[1]), Double.parseDouble(xy[0]), 0)); Path path = new Path(positions, attrs); path.setHighlightAttributes(highlightAttrs); path.setAltitudeMode(WorldWind.CLAMP_TO_GROUND);
Position.fromDegrees(50, -40, 1e5) ); Path path = new Path(positions); layer.addRenderable(path); Position.fromDegrees(40, -40, 0) ); path = new Path(positions); Position.fromDegrees(30, -40, 1e5) ); path = new Path(positions); path.setExtrude(true); // extrude the path from the ground to each path position's altitude layer.addRenderable(path); attrs.setInteriorColor(new Color(1, 1, 1, 0.5f)); // 50% transparent white attrs.setOutlineWidth(3); path = new Path(positions, attrs); path.setExtrude(true); // extrude the path from the ground to each path position's altitude layer.addRenderable(path);
Position.fromDegrees(0.0, -100.0, 1e5) ); Path path = new Path(positions); ShapeAttributes sa = new ShapeAttributes(thickenLine); sa.setOutlineImageSource(ImageSource.fromLineStipple(2 /*factor*/, (short) 0xF0F0 /*pattern*/)); Position.fromDegrees(0.0, -90.0, 5e4) ); path = new Path(positions); sa = new ShapeAttributes(thickenLine); sa.setOutlineImageSource(ImageSource.fromLineStipple(4 /*factor*/, (short) 0xF0F0 /*pattern*/)); Position.fromDegrees(0.0, -80.0, 0.0) ); path = new Path(positions); sa = new ShapeAttributes(thickenLine); sa.setOutlineImageSource(ImageSource.fromLineStipple(8 /*factor*/, (short) 0xDFF6 /*pattern*/));