On 9/18/07, oneproofdk <[EMAIL PROTECTED]> wrote:
> I'm looking for help on how to "describe" a physical room in a xml
>  file - so I can draw it in a flex container later.
>
>  The task is to be able to describe any room for, where there can be x
>  walls and x angles.
>
>  One room can be very simple, has 4 walls, no funny angles etc.
>  Se illustration here : http://koalit.dk/flex/room0.jpg
>  So I need only to store 2 values (I guess)
>  <wall name="A" length="5000"/>
>  <wall name="B" length="6500"/>
>
>  But what when the rooms suddenly has multiple walls and angles:
>  http://koalit.dk/flex/room1.jpg - http://koalit.dk/flex/room2.jpg -
>  http://koalit.dk/flex/room3.jpg

Perhaps I'm oversimplifying the problem, but I would think that you
could solve this by using pairs of x,y coordinates for each line
(wall), couldn't you?

For example, room 3 might look like

<wall id="A" x1="0" y1="0" x2="0" y2="5000">
<wall id="B" x1="0" y1="5000" x2="4000" y2="5000">
<wall id="C" x1="4000" y1="5000" x2="4000" y2="1500">
<wall id="D" x1="0" y1="0" x2="3500" y2="0">
<wall id="E" x1="3500" y1="0" x2="4000" y2="1500"> (The angled wall)

Just a thought.

Adam

Reply via email to