mirror of
https://github.com/a-b-street/abstreet.git
synced 2024-12-01 02:33:54 +03:00
make sure polygon area is positive. the building classification was
multiplying negatives and winding up with quite a few people...
This commit is contained in:
parent
1c39de50f7
commit
aad5796e0b
@ -39,16 +39,16 @@ data/input/seattle/parcels_urbansim.txt,db63d7d606e8702d12f9399e87e6a00f,https:/
|
|||||||
data/input/seattle/popdat.bin,1aa2569c7e5a5a4773d7ca706d60432d,https://www.dropbox.com/s/0lwlep06spt0itv/popdat.bin.zip?dl=0
|
data/input/seattle/popdat.bin,1aa2569c7e5a5a4773d7ca706d60432d,https://www.dropbox.com/s/0lwlep06spt0itv/popdat.bin.zip?dl=0
|
||||||
data/input/seattle/trips_2014.csv,d4a8e733045b28c0385fb81359d6df03,https://www.dropbox.com/s/5ppravwmk6bf20d/trips_2014.csv.zip?dl=0
|
data/input/seattle/trips_2014.csv,d4a8e733045b28c0385fb81359d6df03,https://www.dropbox.com/s/5ppravwmk6bf20d/trips_2014.csv.zip?dl=0
|
||||||
data/system/cities/seattle.bin,d9f86e7387d3b013952acdfe4cfb09a5,https://www.dropbox.com/s/jmgjhzwp33r5ugu/seattle.bin.zip?dl=0
|
data/system/cities/seattle.bin,d9f86e7387d3b013952acdfe4cfb09a5,https://www.dropbox.com/s/jmgjhzwp33r5ugu/seattle.bin.zip?dl=0
|
||||||
data/system/maps/ballard.bin,6fc29602bff4407c10436bb60b050be0,https://www.dropbox.com/s/e2metljvxl9py7k/ballard.bin.zip?dl=0
|
data/system/maps/ballard.bin,33399d8581e959e56accee655adafbd0,https://www.dropbox.com/s/p8cp9m0q8qptoj7/ballard.bin.zip?dl=0
|
||||||
data/system/maps/berlin_center.bin,7d9f6a384592983ea35636d769081ff6,https://www.dropbox.com/s/agn1fllnm0cfgtm/berlin_center.bin.zip?dl=0
|
data/system/maps/berlin_center.bin,de351262c6f79d80a306f4576931bd11,https://www.dropbox.com/s/96vf3s6n3335ocp/berlin_center.bin.zip?dl=0
|
||||||
data/system/maps/downtown.bin,eb15eb3420ed1024b4bde181ba96fc23,https://www.dropbox.com/s/kl3nbdg1uhmvgei/downtown.bin.zip?dl=0
|
data/system/maps/downtown.bin,18d6180c933ca5c6a8b881935789bffa,https://www.dropbox.com/s/u2rc63ar95qjbza/downtown.bin.zip?dl=0
|
||||||
data/system/maps/huge_krakow.bin,d0b7d128741a31e90492e5538bd832fa,https://www.dropbox.com/s/nooaloak250gfuo/huge_krakow.bin.zip?dl=0
|
data/system/maps/huge_krakow.bin,b49e3d9f801c1ff62a1b4f55cbf0a77b,https://www.dropbox.com/s/4pq6akxr53qvn1v/huge_krakow.bin.zip?dl=0
|
||||||
data/system/maps/huge_seattle.bin,99b51d5ff218b654baa6fc6462cf986a,https://www.dropbox.com/s/zteq2rbeytpinpn/huge_seattle.bin.zip?dl=0
|
data/system/maps/huge_seattle.bin,545372e1db83cc175f1b9a0e5226c9b2,https://www.dropbox.com/s/wvlckocfgbtgsh4/huge_seattle.bin.zip?dl=0
|
||||||
data/system/maps/lakeslice.bin,b991b07413b0697b9b26088fd34a0b2a,https://www.dropbox.com/s/rc7edmgmfe62uvt/lakeslice.bin.zip?dl=0
|
data/system/maps/lakeslice.bin,7fe76927dd154051a9e3dfa5e5842954,https://www.dropbox.com/s/lbo4y418e2qo2it/lakeslice.bin.zip?dl=0
|
||||||
data/system/maps/montlake.bin,1232e900355ba1cb9837e2790c16870c,https://www.dropbox.com/s/f28ivdxynz2j2u5/montlake.bin.zip?dl=0
|
data/system/maps/montlake.bin,1232e900355ba1cb9837e2790c16870c,https://www.dropbox.com/s/f28ivdxynz2j2u5/montlake.bin.zip?dl=0
|
||||||
data/system/maps/south_seattle.bin,88fea2cc82b3ad188a1e9b46d201c2ea,https://www.dropbox.com/s/x36tl83sez2ykf7/south_seattle.bin.zip?dl=0
|
data/system/maps/south_seattle.bin,bb701fcf4abe9330cfb58121d3e5bad7,https://www.dropbox.com/s/4svs757s9w2slyi/south_seattle.bin.zip?dl=0
|
||||||
data/system/maps/udistrict.bin,47aeddfd03df656ad604f165f317d8cf,https://www.dropbox.com/s/zjdoknrmx8x2o85/udistrict.bin.zip?dl=0
|
data/system/maps/udistrict.bin,0dbd16d4b45a2efbf9d98d89054231bc,https://www.dropbox.com/s/1651xn91s8ihr2n/udistrict.bin.zip?dl=0
|
||||||
data/system/maps/west_seattle.bin,6623562f4e977a47a0da2c3463f879dc,https://www.dropbox.com/s/s6zcn5lxwzg44om/west_seattle.bin.zip?dl=0
|
data/system/maps/west_seattle.bin,57411a6e8a0ed843c96d35cf929af6ff,https://www.dropbox.com/s/iulfhcgsn4atduk/west_seattle.bin.zip?dl=0
|
||||||
data/system/prebaked_results/lakeslice/weekday.bin,32af0ac87f7a50508d0136c5a8b07c56,https://www.dropbox.com/s/4zj2kxfggdrdbsg/weekday.bin.zip?dl=0
|
data/system/prebaked_results/lakeslice/weekday.bin,32af0ac87f7a50508d0136c5a8b07c56,https://www.dropbox.com/s/4zj2kxfggdrdbsg/weekday.bin.zip?dl=0
|
||||||
data/system/prebaked_results/montlake/car vs bike contention.bin,1fac82d6dcd567874fd6e0b106956dd9,https://www.dropbox.com/s/jefg0ikjy9dsrdd/car%20vs%20bike%20contention.bin.zip?dl=0
|
data/system/prebaked_results/montlake/car vs bike contention.bin,1fac82d6dcd567874fd6e0b106956dd9,https://www.dropbox.com/s/jefg0ikjy9dsrdd/car%20vs%20bike%20contention.bin.zip?dl=0
|
||||||
data/system/prebaked_results/montlake/weekday.bin,34399bff9bf2d36ddb9e5639ebc81bb5,https://www.dropbox.com/s/6rik3r01yach76v/weekday.bin.zip?dl=0
|
data/system/prebaked_results/montlake/weekday.bin,34399bff9bf2d36ddb9e5639ebc81bb5,https://www.dropbox.com/s/6rik3r01yach76v/weekday.bin.zip?dl=0
|
||||||
|
@ -283,7 +283,8 @@ impl Polygon {
|
|||||||
|
|
||||||
// Usually m^2, unless the polygon is in screen-space
|
// Usually m^2, unless the polygon is in screen-space
|
||||||
pub fn area(&self) -> f64 {
|
pub fn area(&self) -> f64 {
|
||||||
to_geo(&self.points()).area()
|
// Polygon orientation messes this up sometimes
|
||||||
|
to_geo(&self.points()).area().abs()
|
||||||
}
|
}
|
||||||
|
|
||||||
// Doesn't handle multiple crossings in and out.
|
// Doesn't handle multiple crossings in and out.
|
||||||
|
Loading…
Reference in New Issue
Block a user