SurroundRoom Plugin

This topic has been viewed 8684 times and has 17 replies
Thread status: Active
Questions about extending features and developing plug-ins [img]http://www.sweethome3d.com/images/flags/en_small.gif[/img]
User avatar
Ollie_Jess
Posts: 13
Joined: Sun Apr 10, 2022 3:53 am
Country: México

SurroundRoom Plugin

Post by Ollie_Jess »

Hello SH3D community!
I developed a plugin that surrounds a room with a piece of furniture, externally or internally, in 3 different ways. Both the room and the furniture must be selected at the same time on the plan.

This is the direct download and is also on SourceForge (please download the version 1.1 instead of 1.0, due to compatibility problems).

These are the steps for surround a room with the plugin:

Step 1.- Select the object and the room.
Image


Step 2.- Select “Tools” in the principal menu and select “Surround room…”
Image


Step 3.- Customize the way in which the room will be surrounded.
Image


Result:
Image


----------------------------------------------------------------------
This is another example using the plugin:

Step 3.- Select “Surround internally”
Image


Result:
Image


Hope you like the plugin!
User avatar
Keet
Posts: 1807
Joined: Fri Apr 08, 2022 7:13 am
Country: Netherlands

Re: SurroundRoom Plugin

Post by Keet »

Nice!
Does it also work with an room created from curved walls?
Dodecagon.nl
1300+ 3D models, manuals, and projects
User avatar
dorin
Posts: 824
Joined: Thu Apr 24, 2014 9:14 am
Country: Vatra Dornei, Suceava, Romania

Re: SurroundRoom Plugin

Post by dorin »

@Ollie
It's a good start! Keep going!
@Keet
I've test it and NO, not this time. Maybe in the future.

@Me
While this plugin act as a multiplier what if it will be added as feature to the current Multiplier?
Could be BUT not before to have a more performant (customizable) polyline in the main program.
What's in my mind:
The Art Off Illusion (java) have the option to draw objects (or extrude) along a curved line especially to make pipes.
Could be a good source of inspiration.
A computer program does what you tell it to do, not what you want it to do. Murphy's Law
When all else fails, read the instructions. Murphy's Law
If you don't like "AS IS", DIY. Dorin's law
JonnyD
Posts: 36
Joined: Sat Jun 01, 2019 2:58 pm

Re: SurroundRoom Plugin

Post by JonnyD »

I’m afraid the plugin just presents a warning that no room is selected for me - even when it is.
User avatar
dorin
Posts: 824
Joined: Thu Apr 24, 2014 9:14 am
Country: Vatra Dornei, Suceava, Romania

Re: SurroundRoom Plugin

Post by dorin »

@Ollie
JonnyD is right, but don't despair. I've encountered the same problem at the beginning and Emmanuel have helped me.
Now it's my turn.
You have to verify first if the home have more levels.
Study of case:

Code: Select all

Level selectedLevel = getHome().getSelectedLevel();

-New file; draw a room; add an flower and select both. Run the plugin => OK.

Code: Select all

selectedLevel = null

-On the same file add a level and then delete it.

Code: Select all

selectedLevel != null
Run the plugin => Not OK.

So, in my Select/Hide Special plugin I've use something like this:

Code: Select all

if (selectedLevel == null || selectedLevel.isVisible()) {
   userView = new SelectHideView();
   contentPanel = userView.createComponents(resource);
}
Of course probably you will need other conditions.
Feel free to take inspiration from other plugin sources. I do it all the time.
A computer program does what you tell it to do, not what you want it to do. Murphy's Law
When all else fails, read the instructions. Murphy's Law
If you don't like "AS IS", DIY. Dorin's law
User avatar
Ollie_Jess
Posts: 13
Joined: Sun Apr 10, 2022 3:53 am
Country: México

Re: SurroundRoom Plugin

Post by Ollie_Jess »

@dorin thanks for detecting the source of the error and for recommending a way to fix it. I also detected that if the furniture angle is not at 0° it doesn't surround the room well. In version 1.2 these problems will be solved, which I hope to finish this month.
In version 1.3 I will add more ways to surround rooms, being able to surround curved lines and more customization to surround rooms.
User avatar
Ollie_Jess
Posts: 13
Joined: Sun Apr 10, 2022 3:53 am
Country: México

Re: SurroundRoom Plugin

Post by Ollie_Jess »

Hello community! the version 1.2 is ready, with the problems mentioned fixed.
If there is something wrong with the plugin or you have any suggestions, let me know.
User avatar
Ollie_Jess
Posts: 13
Joined: Sun Apr 10, 2022 3:53 am
Country: México

Re: SurroundRoom Plugin

Post by Ollie_Jess »

This is the version 1.2 and is also on SourceForge
User avatar
Daniels118
Posts: 503
Joined: Wed Nov 17, 2021 9:04 pm
Country: Italy

Re: SurroundRoom Plugin

Post by Daniels118 »

Nice plugin! I've added it to the Plugin Manager catalog!
User avatar
Ollie_Jess
Posts: 13
Joined: Sun Apr 10, 2022 3:53 am
Country: México

Re: SurroundRoom Plugin

Post by Ollie_Jess »

Thanks Daniels118!
Post Reply New Topic

Who is online

Users browsing this forum: No registered users and 1 guest