Cluster Components
-
Hi all, I am building cluster components to create assemblies so that I can add a door and get a break down of hinges, jambs, architraves and door handles etc in outliner.I was hoping some one could help me? To do this I am drawing a door and making it a component, drawing a jamb and making it a component, drawing hinges and making them a component. In the description column I am writing the product code and quantity . I then put them all together and make them into 1 component cluster. The problem I am having is that there are many different door sizes so I tried to take a short cut by exploding the cluster, copying it and then stretching it with the scale tool to the next standard size. I then renamed the component to the new size. Unfortunately when I rename the door size component it renames the original clusters components. Can any one tell me if there is a solution without making all components individually as the scale tool saves a lot of time and repetion?
-
first of all: are you scaling everything (door, hinges...) or only the door leaf? because if you scale the hinges as well, they will be distorted.
to be honest, I have no idea, why SketchUp renames all your compontents. it is not supposed to do that.
but what you can do anyway, is to copy the overall component, then click right mouse button and choose "Make Unique" to create a new, independent copy of the door. you can rename it to your likings (in the entity info window). and by double clickin it you can alter this new version without exploding it at all.
I hope this works for you. in the meantime I will try to figure out, why your subcomponents are renamed...
-
Hi Andrew,
The problem with this method is that they are still the original components and even if you scale them from outside of their context (i.e. not editing them), only that particular component will be scaled.
The only real solution would be to make them unique. I presume not everything needs to be made unique since you can keep the hinges for instance (I don't think that you need different sizes for different doors) or the handles etc. Just the jambs and architraves and such.
-
Dear Andrew,
I suggest that for each assembly you make the individual parts (door, jamb, hinges etc) groups and then make a component of the groups and call it something meaningful (Door Assembly 1, say).
Go to Windows and open up Entity Info and Outliner.
Right click on a group, say a hinge, and type in the description (into Name). The description can be quite long (use right/left arrow keys to scroll through the entered text). This description will then appear in the Outliner. You will note that all the groups in a component are displayed in a tree structure under each component name. New door assembly components can be made by copying and exploding an existing component, altering the door and jamb, then regrouping under a different component name (Door Assembly 2, say).
You can also attach attributes to your groups using the script found in Attribs_v1_05.zip (http://www.crai.archi.fr/RubyLibraryDepot/Ruby/em_edi_page.htm. Unfortunately, there doesn't appear to be a help file to go with this script and so it is a case of trial and error. Start with Right Click>Attributes>Make Standard Categories, then Right Click>Attributes>Show.
I believe there is a script for exporting the contents of Outliner to a spreadsheet(?), but I'm not sure where to find that.
Hope this helps.
Regards,
Bob -
Dear Andrew,
Jim Foltz has written a script for exporting Outliner to a text file.
http://sketchuptips.blogspot.com/2007/10/plugin-export-outliner.html
Regards,
Bob -
Thanks for all your feed back its much appreciated. I will try to make unique first and then I will try the rubies and get it through to excel. When I come up with a positive result I will let you all know. Thanks again.
-
My ComponentReporter+.rb script also makes a reports on your model/selection and makes various spreadsheets of components and subcomponents info etc. It wouldn't be hard to read off further details like attributes if needed - however, you could avoid attributes by making unique and then (re)naming each your components as their 'part-code'...
.
-
Hi all, I made my components unique and used the entity info to rename the components, everything worked out perfect. I didnt have as much luck with the attributes ruby. I downloaded attributes reporter (http://www.smustard.com/script/AttribReporter)I opened a trial model and right clicked on a component then clicked on attribute reporter. A dialogue box named attribute reporter with dictionary and a box came up. I typed in "trial text" and clicked ok. A message came up reading " Attibutes + reports saved to: my docs. CSD-Attributes+report.csv. I navigated to the sheet with great antisipation and it was there and had a tab named attribute reporter but had no information in any cells. Am I missing an important step?sliding door assemblies
-
I hope you don't mind my barging in on your thread; I have no short term fix just a longer term solution that you and others may like to consider. Based on Sketchup's webdialog (which allows html/javascripts and Sketchup/Ruby interaction) it is this:
Rather than manually clustering components in Sketchup simply pick plain text names to identify them as shown on this nameset.
A nameset is something like a spreadsheet, except its cells move to display just their association with others. Each name with its address (the white trail that leads back to the project) is a unique identifier which provides access to its record, an unlimited series of CSS type name/value pairs that includes sizes, coordinates, source (real and model), price, timing ... and so on, obtained from many sources.
Rather than putting in and then extracting information from a modelling application, you generate models (or clusters) and analyses from the same unfettered plain text data - e.g. you can use web technology to generate different sizes, or abstract and even buy the ironmongery for a whole project.
Here's some code I used to pick up components and position them.
//javascript function productsRun(){ entryNo = parentNo coreIdentityExtractor() para = new Array(theFile,theX,theY,theZ) para = para.join(",") if(sketchup == 1) window.location.href = 'skp;find@'+para }
#Ruby @dlg.add_action_callback("find") {|d, p| a= p.split(",") subDir ="Components/NamesetComponents/" fileName = a[0]+".skp" theX = Integer(a[1]).mm theY = Integer(a[2]).mm theZ = Integer(a[3]).mm point = Geom;;Point3d.new theX,theY,theZ transform = Geom;;Transformation.new point model = Sketchup.active_model entities = model.active_entities path = Sketchup.find_support_file fileName, subDir definitions = model.definitions componentdefinition = definitions.load path instance = entities.add_instance componentdefinition, transform }
Hope you find this helpful/interesting ...
Chris
-
Thanks Chris for your input, its good to know that there are many ways to acheive a similar or better result. I will post you a private message on what I would like the final out come to be. (it sounds as though you may be talking about what I am seeking as a final result). I dont want to bore the rest of the people following this topic although If any one wants me to post the message here just reply and I will try not write a cure for insomnia (hehe).
-
I have taken the liberty of extracting parts of your PM that may be of interest to others.
@aadbuild said:
You will have to forgive me I am not exactly sure how and what the nameset actually does and how it takes the information from sketchup.
A nameset names all the physical things in a human endeavour using plain text and freely available code. This means it can be used by anyone who has an interest in it. Just put the name somewhere accessible and add a universal function call; those authorised can then add their bit. Information you used to make clusters in Sketchup is now captured in the name's record; select a device in the top panel for Sketchup to assemble the components, as in the coding example, or another, to make a time schedule and so on. You might consider a name and its address to be something like a barcode that is key to automating all sorts of things previously done by people (in your case, making clusters). Everyday work, not just code, becomes object-oriented.
@aadbuild said:
Let me know if am getting way to far ahead of what nameset can do....
No I don't think so but I would like to test this in the forum, if anyone is interested. The nameset concept does not work well without modelling and so when I discovered Sketchup and the webdialog everything seemed pre-ordained (well that's probably going too far!). Hopefully, the nameset plugin can be cooperatively developed for use pretty soon.
Chris
-
Here is a zip containing the original file and the 3 ComponentReporter+ reports that take seconds to make. You could easily rewrite the script to read component's attributes as well if needed...
-
Hi Tig, I had a look at the info on the excel sheets that you exported and attached. As i looked through the sheet I had one of those moments where I got all excited as this is what I have been trying to achieve for bloody ages. I will try to get leave from the wife and kids tonight to get it formated so I can use it. You are a champion TIG. I would like to have a crack at editing the script to include attributes but unfortunatly my ruby experiance is very limited. Can any one recomend a ruby book for dislexics?
-
I sent you two PMs on Friday but you don't seem to have picked them up yet ... any problem?
Chris
-
No problem. That's good. Thanks for letting me know.
Chris
-
Hi Chris please excuse my absence unfortunatley I have been caught up in work I will get back to you as soon as I get time with some component instances
-
@aadbuild said:
Hi Chris please excuse my absence unfortunatley I have been caught up in work I will get back to you as soon as I get time with some component instances
That's OK. It was kind of you to offer. I have plenty to do making new devices, annotating the code, testing and so on. I put screenshots of completed devices on http://sites.google.com/site/namesets/ - a measure of progress if you like. You or anyone else are welcome to have a look and comment. You may also find this helpful:
The prototype nameset is for a six storey apartment block with elevator and all the usual stuff. If anyone else would also like to volunteer some components, all will be gratefully received and acknowledged.
My regards
Chris
-
Hi Chris the guilt got to me while I was laying in bed Sunday morning so I dragged my fat arse out and made a model and threw in as many components that i thought would be of assistance. I also put in an excel breakdown of components from TIGS ruby (above). Let me know if you need anything else..
-
Thanks Andrew ... now I feel guilty!
I am sure your components will be most useful but I need some time to examine them. But I also need skps of furniture, fittings, plumbing and suchlike as the basic idea is to use them to define space requirements (working from inside out). You can see from the records extract below that in the early stages of design the minimum spaces set by the components' layouts accumulates the w's and d's back to the start. (As decisions are made and approved they become W's and D's - i.e. fixed.)
1;index; 2;genericName; 2;givenName; 3;childNo; 4;parentNo; 5;theType; 6;collection; 7;product; 8;grouping; 9;composite 0;10;1;Start;5;0;3;11;4;10;w;2017;d;1524 0;11;3;14;3;13;3;12;1;Site;2;Site;5;6;4;10;w;2017;d;1524 0;12;1;Constraints;2;Constraints;4;11;5;8 0;13;3;17;3;16;3;15;1;Design;2;Design;4;11;5;8;w;2017;d;1524 0;14;1;Brief;2;Brief;4;11;5;8 0;15;1;Landscape;2;Landscape;4;13;5;8 0;16;1;Roads;2;Roads;4;13;5;8 0;17;3;18;1;Buildings;2;Buildings;4;13;5;8;w;2017;d;1524 0;18;1;Building;2;Building;4;17;5;6;w;2017;d;1524;3;46;3;45;3;44;3;43;3;42;3;41;3;19;3;40;3;39;3;38;3;47 0;19;3;27;3;20;1;Floor;2;Floor 5;4;18;5;6;w;2017;d;1524 0;20;3;37;3;36;3;35;3;34;3;33;1;Spaces;2;Spaces;4;19;5;8;w;1637;d;1524;3;32;3;31;3;21;3;30;3;29 0;21;3;22;1;Space;2;Bathroom;4;20;5;6;w;1637;d;1524 0;22;1;Sanitary;2;Sanitary;4;21;5;8;3;26;3;25;3;24;w;1637;d;1524 0;24;1;Bath;2;Bath;4;22;5;7;x;1037;y;0;z;0;w;600;d;1524;h;500;model;Bath;rx;90;ry;0;rz;0 0;25;1;Basin;2;Basin;4;22;5;7;x;0;y;0;z;450;w;457;d;400;h;210;model;Washbasin 0;26;1;WC;2;WC;4;22;5;7;x;457;y;0;z;0;w;555;d;600;h;600;model;WC 0;27;3;53;3;52;3;48;3;28;1;Elements;2;Elements;4;19;5;8;w;2017;d;100 0;28;1;Wall;2;Wall;4;27;5;9;s;cube;x;-100;y;0;z;0;w;2117;d;100;h;2800
These records are similar (though more expandable) to the components breakdown but so far they are one way - Javascript to Sketchup. It would be good to make it bilateral so that those who prefer to use Sketchup to establish names, dimensions and so on can do so in the knowledge that their data will be made interoperative.
I am going to buy a headset so I can call you on Google Talk (I think the basic idea should be reasonably clear now not to confuse you with my babble) and also make a video as you suggested!
Toddle pip!
Chris
-
Hi chris, a quick question with the java script imports, are they going to be similar to clicking on components and inserting a java script component?
Advertisement