Commit ce545bf2 authored by Andrijana Brkic's avatar Andrijana Brkic

new geometries and ini files, last version of VoronoiBoost

parent e73a2cdf
......@@ -42,11 +42,11 @@
<subroom id="0" closed="0" class="floor">
<polygon caption="wall">
<vertex px="9.2" py="2.8" />
<vertex px="11.2" py="2.8" />
<vertex px="17.2" py="2.8" />
</polygon>
<polygon caption="wall">
<vertex px="9.2" py="6.4" />
<vertex px="11.2" py="6.4" />
<vertex px="17.2" py="6.4" />
</polygon>
</subroom>
</room>
......@@ -98,8 +98,8 @@
<vertex px="5.20" py="-2.0" />
</transition>
<transition id="5" caption="exit" type="emergency" room1_id="2" subroom1_id="0" room2_id="-1" subroom2_id="-1">
<vertex px="11.2" py="2.8" />
<vertex px="11.2" py="6.4" />
<vertex px="17.2" py="2.8" />
<vertex px="17.2" py="6.4" />
</transition>
<transition id="6" caption="exit" type="emergency" room1_id="3" subroom1_id="0" room2_id="-1" subroom2_id="-1">
<vertex px="3.2" py="11.2" />
......@@ -110,4 +110,4 @@
<vertex px="-2.0" py="6.4" />
</transition>
</transitions>
</geometry>
\ No newline at end of file
</geometry>
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<geometry version="0.5" caption="hybrid test" unit="m" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://xsd.jupedsim.org/0.6/jps_geometry.xsd">
<rooms>
<room id="0" caption="hall0">
<subroom id="0" closed="0" class="floor">
<polygon caption="wall">
<vertex px="0.0" py="2.8" />
<vertex px="0.0" py="0.0" />
<vertex px="3.6" py="0.0" />
</polygon>
<polygon caption="wall">
<vertex px="5.2" py="0.0" />
<vertex px="9.2" py="0.0" />
<vertex px="9.2" py="2.8" />
</polygon>
<polygon caption="wall">
<vertex px="9.2" py="6.4" />
<vertex px="9.2" py="9.2" />
<vertex px="5.6" py="9.2" />
</polygon>
<polygon caption="wall">
<vertex px="3.2" py="9.2" />
<vertex px="0.0" py="9.2" />
<vertex px="0.0" py="6.4" />
</polygon>
</subroom>
</room>
<room id="1" caption="hall1">
<subroom id="0" closed="0" class="floor">
<polygon caption="wall">
<vertex px="3.6" py="-2.0" />
<vertex px="3.6" py="0.0" />
</polygon>
<polygon caption="wall">
<vertex px="5.2" py="-2.0" />
<vertex px="5.2" py="0.0" />
</polygon>
</subroom>
</room>
<room id="2" caption="hall2">
<subroom id="0" closed="0" class="floor">
<polygon caption="wall">
<vertex px="9.2" py="2.8" />
<vertex px="11.2" py="3.4" />
<vertex px="13.2" py="2.8" />
</polygon>
<polygon caption="wall">
<vertex px="9.2" py="6.4" />
<vertex px="11.2" py="5.8" />
<vertex px="13.2" py="6.4" />
</polygon>
</subroom>
<!-- <subroom id="1" closed="0" class="floor">
<polygon caption="wall">
<vertex px="11.2" py="2.8" />
<vertex px="13.2" py="2.8" />
</polygon>
<polygon caption="wall">
<vertex px="11.2" py="6.4" />
<vertex px="13.2" py="6.4" />
</polygon>
</subroom>
<crossings>
<crossing id="0" subroom1_id="0" subroom2_id="1">
<vertex py="2.8" px="11.2"/>
<vertex py="6.4" px="11.2"/>
</crossing>
</crossings> -->
</room>
<room id="3" caption="hall3">
<subroom id="0" closed="0" class="floor">
<polygon caption="wall">
<vertex px="3.2" py="9.2" />
<vertex px="3.2" py="11.2" />
</polygon>
<polygon caption="wall">
<vertex px="5.6" py="9.2" />
<vertex px="5.6" py="11.2" />
</polygon>
</subroom>
</room>
<room id="4" caption="hall4">
<subroom id="0" closed="0" class="floor">
<polygon caption="wall">
<vertex px="0.0" py="2.8" />
<vertex px="-2.0" py="2.8" />
</polygon>
<polygon caption="wall">
<vertex px="0.0" py="6.4" />
<vertex px="-2.0" py="6.4" />
</polygon>
</subroom>
</room>
</rooms>
<transitions>
<transition id="0" caption="exit" type="emergency" room1_id="0" subroom1_id="0" room2_id="1" subroom2_id="0">
<vertex px="3.6" py="0.0" />
<vertex px="5.2" py="0.0" />
</transition>
<transition id="1" caption="exit" type="emergency" room1_id="0" subroom1_id="0" room2_id="2" subroom2_id="0">
<vertex px="9.2" py="2.8" />
<vertex px="9.2" py="6.4" />
</transition>
<transition id="2" caption="exit" type="emergency" room1_id="0" subroom1_id="0" room2_id="3" subroom2_id="0">
<vertex px="3.2" py="9.2" />
<vertex px="5.6" py="9.2" />
</transition>
<transition id="3" caption="exit" type="emergency" room1_id="0" subroom1_id="0" room2_id="4" subroom2_id="0">
<vertex px="0.0" py="2.8" />
<vertex px="0.0" py="6.4" />
</transition>
<transition id="4" caption="exit" type="emergency" room1_id="1" subroom1_id="0" room2_id="-1" subroom2_id="-1">
<vertex px="3.6" py="-2.0" />
<vertex px="5.20" py="-2.0" />
</transition>
<transition id="5" caption="exit" type="emergency" room1_id="2" subroom1_id="0" room2_id="-1" subroom2_id="-1">
<vertex px="13.2" py="2.8" />
<vertex px="13.2" py="6.4" />
</transition>
<transition id="6" caption="exit" type="emergency" room1_id="3" subroom1_id="0" room2_id="-1" subroom2_id="-1">
<vertex px="3.2" py="11.2" />
<vertex px="5.6" py="11.2" />
</transition>
<transition id="7" caption="exit" type="emergency" room1_id="4" subroom1_id="0" room2_id="-1" subroom2_id="-1">
<vertex px="-2.0" py="2.8" />
<vertex px="-2.0" py="6.4" />
</transition>
</transitions>
</geometry>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<geometry version="0.5" caption="hybrid test" unit="m" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://xsd.jupedsim.org/0.6/jps_geometry.xsd">
<rooms>
<room id="0" caption="hall0">
<subroom id="0" closed="0" class="floor">
<polygon caption="wall">
<vertex px="0.0" py="2.8" />
<vertex px="0.0" py="0.0" />
<vertex px="3.6" py="0.0" />
</polygon>
<polygon caption="wall">
<vertex px="5.2" py="0.0" />
<vertex px="9.2" py="0.0" />
<vertex px="9.2" py="3.2" />
</polygon>
<polygon caption="wall">
<vertex px="9.2" py="6.0" />
<vertex px="9.2" py="9.2" />
<vertex px="5.6" py="9.2" />
</polygon>
<polygon caption="wall">
<vertex px="3.2" py="9.2" />
<vertex px="0.0" py="9.2" />
<vertex px="0.0" py="6.4" />
</polygon>
</subroom>
</room>
<room id="1" caption="hall1">
<subroom id="0" closed="0" class="floor">
<polygon caption="wall">
<vertex px="3.6" py="-2.0" />
<vertex px="3.6" py="0.0" />
</polygon>
<polygon caption="wall">
<vertex px="5.2" py="-2.0" />
<vertex px="5.2" py="0.0" />
</polygon>
</subroom>
</room>
<room id="2" caption="hall2">
<subroom id="0" closed="0" class="floor">
<polygon caption="wall">
<vertex px="9.2" py="6.0" />
<vertex px="10.2" py="6.8" />
<vertex px="11.9" py="6.8"/>
<vertex px="13.0" py="5.8" />
</polygon>
<polygon caption="wall">
<vertex px="9.2" py="3.2" />
<vertex px="10.2" py="2.4" />
<vertex px="11.9" py="2.4" />
<vertex px="13.0" py="3.4" />
</polygon>
</subroom>
<!-- <subroom id="1" closed="0" class="floor">
<polygon caption="wall">
<vertex px="11.2" py="2.8" />
<vertex px="13.2" py="2.8" />
</polygon>
<polygon caption="wall">
<vertex px="11.2" py="6.4" />
<vertex px="13.2" py="6.4" />
</polygon>
</subroom>
<crossings>
<crossing id="0" subroom1_id="0" subroom2_id="1">
<vertex py="2.8" px="11.2"/>
<vertex py="6.4" px="11.2"/>
</crossing>
</crossings> -->
</room>
<room id="3" caption="hall3">
<subroom id="0" closed="0" class="floor">
<polygon caption="wall">
<vertex px="3.2" py="9.2" />
<vertex px="3.2" py="11.2" />
</polygon>
<polygon caption="wall">
<vertex px="5.6" py="9.2" />
<vertex px="5.6" py="11.2" />
</polygon>
</subroom>
</room>
<room id="4" caption="hall4">
<subroom id="0" closed="0" class="floor">
<polygon caption="wall">
<vertex px="0.0" py="2.8" />
<vertex px="-2.0" py="2.8" />
</polygon>
<polygon caption="wall">
<vertex px="0.0" py="6.4" />
<vertex px="-2.0" py="6.4" />
</polygon>
</subroom>
</room>
</rooms>
<transitions>
<transition id="0" caption="exit" type="emergency" room1_id="0" subroom1_id="0" room2_id="1" subroom2_id="0">
<vertex px="3.6" py="0.0" />
<vertex px="5.2" py="0.0" />
</transition>
<transition id="1" caption="exit" type="emergency" room1_id="0" subroom1_id="0" room2_id="2" subroom2_id="0">
<vertex px="9.2" py="3.2" />
<vertex px="9.2" py="6.0" />
</transition>
<transition id="2" caption="exit" type="emergency" room1_id="0" subroom1_id="0" room2_id="3" subroom2_id="0">
<vertex px="3.2" py="9.2" />
<vertex px="5.6" py="9.2" />
</transition>
<transition id="3" caption="exit" type="emergency" room1_id="0" subroom1_id="0" room2_id="4" subroom2_id="0">
<vertex px="0.0" py="2.8" />
<vertex px="0.0" py="6.4" />
</transition>
<transition id="4" caption="exit" type="emergency" room1_id="1" subroom1_id="0" room2_id="-1" subroom2_id="-1">
<vertex px="3.6" py="-2.0" />
<vertex px="5.20" py="-2.0" />
</transition>
<transition id="5" caption="exit" type="emergency" room1_id="2" subroom1_id="0" room2_id="-1" subroom2_id="-1">
<vertex px="13.0" py="3.4" />
<vertex px="13.0" py="5.8" />
</transition>
<transition id="6" caption="exit" type="emergency" room1_id="3" subroom1_id="0" room2_id="-1" subroom2_id="-1">
<vertex px="3.2" py="11.2" />
<vertex px="5.6" py="11.2" />
</transition>
<transition id="7" caption="exit" type="emergency" room1_id="4" subroom1_id="0" room2_id="-1" subroom2_id="-1">
<vertex px="-2.0" py="2.8" />
<vertex px="-2.0" py="6.4" />
</transition>
</transitions>
</geometry>
\ No newline at end of file
......@@ -119,7 +119,7 @@ bool ComputeBestPositionVoronoiBoost(AgentsSource* src, std::vector<Pedestrian*>
for (iter_ped = peds.begin(); iter_ped != peds.end(); )
{
Pedestrian* ped = (*iter_ped);
radius = ped->GetEllipse().GetBmax(); //max radius of the curren pedestrian
radius = ped->GetEllipse().GetBmax(); //max radius of the current pedestrian
if(existing_peds.size() == 0 )
{
......@@ -202,7 +202,7 @@ bool ComputeBestPositionVoronoiBoost(AgentsSource* src, std::vector<Pedestrian*>
double dis = 0;
VoronoiBestVertexMax(discrete_positions, vd, subroom, factor, chosen_it, dis, radius);
if( dis > 2*radius*factor*2*radius*factor)// be careful with the factor!! radius*factor, 2 on purpose instead of 4
if( dis > 4*radius*factor*radius*factor)// be careful with the factor!! radius*factor, 2,3,4?
{
Point pos( chosen_it->x()/factor, chosen_it->y()/factor ); //check!
ped->SetPos(pos , true);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment