grebtsew / FloorplanToBlender3d

Create 3d rooms in blender from floorplans.
GNU General Public License v3.0
396 stars 103 forks source link

Requesting component extraction clarification #26

Open comp-17 opened 2 years ago

comp-17 commented 2 years ago

Hello again,

I can't thank you enough for this wonderful contribution in the form of the repo that reduced the development time considerably. From your assistance on the previous query, I was going through all the files to understand things but I was stuck with the process of scaling and how the z-coordinate is added for height generation. I am not able to understand that part clearly.

Secondly, how we are identifying the connectivity of the individually extracted units?

Thirdly, what information do the shape files hold? Meaning, what does each value represent?

Kindly clarify my queries as it would much helpful for my implementation.

Thank you

grebtsew commented 2 years ago

Hi @comp-17!

It is great to hear that you appreciate the implementation. I hope these answers satisfies.

  1. The floorplan 3d model height is currently controlled via a variable named WALL_HEIGHT defined in const.py. By default the height is 1 for all floorplans. An alternative is to alter the floorplan scale values.
  2. I am not sure I interpret the question correctly. The detections are separated into floor detection, wall detection, room detection, window and doors detection. Each detection is performed on the same image meaning they will share scale and coordinate system. Room detection uses wall detection to determine distinct differences between rooms. Window and doors detection uses both room and wall detection to find small spaces in the floorplan. Windows are found by classifying which small spaces are doors and which are not.
  3. There are 3 types of stored data files. Transform, faces and verts. The transform file is hopefully easy to interpret, it contains metadata for each floorplan. {"position": [0, 0, 0], "scale": [1, 1, 1], "rotation": [0, 0, 90], "shape": [10.37, 5.06, 1], "image_path": "Images/Examples/example.png", "origin_path": "Data/0/", "data_path": "Data/0/"} In newer versions of the implementation, floorplan faces and verts will be shared between transforms if floorplans with the same image is used, data_path describe where the data for the floorplan can be collected. Verts and faces are commonly used to describe 3d models. Verts contains lists of 3d positions for each model part. The faces describe in which order a surface is described by the corresponding verts. A hint can be to look at the blender script to understand how the data is used.

Cheers, @grebtsew

comp-17 commented 2 years ago

Hello @grebtsew,

Hope you are doing well. Thank you for providing detail answers to my questions. I was wondering if the height was actually calculated from the calibrations but, I get it now.

I am very much Looking forward on updates to the implementation.

Thank you!

On Sun, Nov 13, 2022 at 11:34 AM Grebtsew @.***> wrote:

Hi @comp-17 https://github.com/comp-17!

It is great to hear that you appreciate the implementation. I hope these answers satisfies.

  1. The floorplan 3d model height is currently controlled via a variable named WALL_HEIGHT defined in const.py. By default the height is 1 for all floorplans. An alternative is to alter the floorplan scale values.
  2. I am not sure I interpret the question correctly. The detections are separated into floor detection, wall detection, room detection, window and doors detection. Each detection is performed on the same image meaning they will share scale and coordinate system. Room detection uses wall detection to determine distinct differences between rooms. Window and doors detection uses both room and wall detection to find small spaces in the floorplan. Windows are found by classifying which small spaces are doors and which are not.
  3. There are 3 types of stored data files. Transform, faces and verts. The transform file is hopefully easy to interpret, it contains metadata for each floorplan. {"position": [0, 0, 0], "scale": [1, 1, 1], "rotation": [0, 0, 90], "shape": [10.37, 5.06, 1], "image_path": "Images/Examples/example.png", "origin_path": "Data/0/", "data_path": "Data/0/"} In newer versions of the implementation, floorplan faces and verts will be shared between transforms if floorplans with the same image is used, data_path describe where the data for the floorplan can be collected. Verts and faces are commonly used to describe 3d models. Verts contains lists of 3d positions for each model part. The faces describe in which order a surface is described by the corresponding verts. A hint can be to look at the blender script to understand how the data is used.

Cheers, @grebtsew https://github.com/grebtsew

— Reply to this email directly, view it on GitHub https://github.com/grebtsew/FloorplanToBlender3d/issues/26#issuecomment-1312782590, or unsubscribe https://github.com/notifications/unsubscribe-auth/AWCE3C7BV3Y34D5AJPVUOMTWIERCXANCNFSM6AAAAAAR4GQXVI . You are receiving this because you were mentioned.Message ID: @.***>