added floorplan support for object-sizing
added floorplan support for different wall-heights minor fixes/changes
This commit is contained in:
@@ -334,6 +334,7 @@ namespace Floorplan {
|
||||
obstacle->SetAttribute("x2", line->to.x);
|
||||
obstacle->SetAttribute("y2", line->to.y);
|
||||
obstacle->SetAttribute("thickness", line->thickness_m);
|
||||
if (line->height_m != 0) {obstacle->SetAttribute("height", line->height_m);}
|
||||
obstacles->InsertEndChild(obstacle);
|
||||
}
|
||||
|
||||
@@ -344,7 +345,7 @@ namespace Floorplan {
|
||||
obstacle->SetAttribute("cx", circle->center.x);
|
||||
obstacle->SetAttribute("cy", circle->center.y);
|
||||
obstacle->SetAttribute("radius", circle->radius);
|
||||
obstacle->SetAttribute("height", circle->height);
|
||||
if (circle->height != 0) {obstacle->SetAttribute("height", circle->height);}
|
||||
obstacles->InsertEndChild(obstacle);
|
||||
}
|
||||
|
||||
@@ -369,9 +370,12 @@ namespace Floorplan {
|
||||
obstacle->SetAttribute("x", obj->pos.x);
|
||||
obstacle->SetAttribute("y", obj->pos.y);
|
||||
obstacle->SetAttribute("z", obj->pos.z);
|
||||
obstacle->SetAttribute("rx", obj->rot.x);
|
||||
obstacle->SetAttribute("ry", obj->rot.y);
|
||||
obstacle->SetAttribute("rz", obj->rot.z);
|
||||
if (obj->rot.x != 0) {obstacle->SetAttribute("rx", obj->rot.x);}
|
||||
if (obj->rot.y != 0) {obstacle->SetAttribute("ry", obj->rot.y);}
|
||||
if (obj->rot.z != 0) {obstacle->SetAttribute("rz", obj->rot.z);}
|
||||
if (obj->scale.x != 1) {obstacle->SetAttribute("sx", obj->scale.x);}
|
||||
if (obj->scale.y != 1) {obstacle->SetAttribute("sy", obj->scale.y);}
|
||||
if (obj->scale.z != 1) {obstacle->SetAttribute("sz", obj->scale.z);}
|
||||
obstacles->InsertEndChild(obstacle);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user