How to find coordinates of a rotated room in a floor plan?

1 visualización (últimos 30 días)
CHINTALA NIRMAL SRINIVAS
CHINTALA NIRMAL SRINIVAS el 22 de Jun. de 2020
Comentada: Matt J el 22 de Jun. de 2020
I am new to this platform. So please help me in clarifying my doubt. Actually I had a floorplan in which I need to identify roomc oordinates. I use regionprops() to get the bounding boxes around it and got the coordinates of the rooms. But what if the floor plan is rotated with some angle, then regionprops() is not giving correct coordinates. Could anyone please help me? Also I want to close all the doors in the floorplan image so that I could identify all the rooms. I do not know how to close the doors if the floor plan is rotated.Can somebody please help me?
I could not close all the doors.

Respuestas (1)

Matt J
Matt J el 22 de Jun. de 2020
Editada: Matt J el 22 de Jun. de 2020
Use imerode to get rid of everything except the thicker lines demarcating the walls. Then use houghlines to fit line segments to each of the walls. Once you have the equations for the lines you can compute the rotation angle.
  2 comentarios
CHINTALA NIRMAL SRINIVAS
CHINTALA NIRMAL SRINIVAS el 22 de Jun. de 2020
Actually I had a standard code given by superior to get the coordinates. But it is giving incorrect output for rotated floor plans. I am trying to figure out where it is going wrong. It is unable to close all the doors. But I don't understand why as I do not have much knowledge about the functions in matlab. Could you please tell me where it is going wrong?I am here attached the zip folder of it. Kindly help me to solve this issue.
Matt J
Matt J el 22 de Jun. de 2020
I think my suggestion would be much simpler.

Iniciar sesión para comentar.

Categorías

Más información sobre 3-D Scene Control en Help Center y File Exchange.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by