Cut list sketchup script

UKworkshop.co.uk

Help Support UKworkshop.co.uk:

This site may earn a commission from merchant affiliate links, including eBay, Amazon, and others.

PaulO

Established Member
Joined
31 Jan 2007
Messages
318
Reaction score
0
Location
West Country
I have been using an old ruby script to generate cut lists. This had all sorts of problems in that it wouldn't group components together or give the dimensions in a sensible order.

Today I found an improved version of this script that I thought others might appreciate.

You can download it here:
http://sketchup-pro-groups.googlegroups.com/web/CutListAndMaterials32.zip

When you unzip it, make sure you use the folder names stored in the zip file.

It will list sheet goods separately if you apply a material to them that includes the word "plywood", "sheet" or "veneer".

It sorts the dimensions to give consistent lengths, widths and thicknesses.

It can list parts (such as screws, dowels etc) separately, if you give them a component name with the word "part" in it.

The only downside is that it lists imperial volumes in board feet, but I have modified my version to the more UK friendly cubic feet. (pm me if you want this version)

There is a discussion about this script, showing a version history here:
http://groups.google.com/group/Ruby-API/browse_thread/thread/41990420606da989/244d39b1a8012627
 
Version 3.3 is the latest. I just did a write up last weekend.

Note that currently, it does not work correctly with components that are not aligned parallel to the axes and you absolutely must make components. It doesn't work with groups or "loose" geometry. I've contacted the author about correcting the alignment problem and I'm waiting to hear back about it.

cutlist_capture.jpg
 
frugal":bwx94ivh said:
That link does not work,

Strange, it works fine here.

I had read that it didn't cope well with rotated components, but the author does describe a work around, which seems a bit convoluted as it involves components within components.

I had also read elsewhere that the author had contacted the developers of sketchup about the rotational problem, in fact here is a description of the workaround from the author



You may have a problem where the dimensions given for your component are larger and not what you know your component to be. What you are seeing happens when the components axes are not aligned with the main axes. Here is what you need to do to get the correct measurements.

1) Create your object aligned to the main axes.
2) Select the whole object.
3) Create a componet for this object. (Not a group, groups ignore axes.)
4) Triple click this component so that the object is selected within it.
5) Create a second nested component!
6) Now you can copy and rotate the top level component and the inner component will retain its correct dimensions. The inner component is now relative to the outer component rather than the drawing axes.
7) Apply materials and descriptions you want to use to the inner component.
8 ) Components that are already nested within another component should work fine.

If you have objects that are already rotated you will have to unfortunatly do the following:
1) Change them to components from groups if necessary.
2) Triple click them to select the inner object.
3) Create a nested component as described above.
4) When you create this nested component you will see a blue bounding box that is not ligned up with you rotated object. This is what is being measured rather than your object.
5) Select the inner component, right click on it, and select change axes.
6) Set the axes along the edges of your component.
7) The dimensions should now show up correctly.

In short:
a) Nest all components that will be rotated within an outer component.
b) Apply materials and names to the inner component.
c) Copy, move and rotate the outer component.

Unfortunatly that is the only way around the problem right now without re-implememnting the bounding box logic that sketchup uses. It would be nice if they gave me a second function to use that gave the smallest bounding box independent of the axes used.
 
There are other plugins that don't seem to have this problem of dealing with rotated components. I suspect that it has to do with the way the script is written. Hopefully there will be a change coming.

I hadn't seen that work around description you posted. Thanks for posting it.

I don't care for nesting components if there isn't a good reason for it. It tends to complicate the model, particulalry when componets definitions are associated with different layers.
 
Just thought I'd post an update on this topic. Although I tried, I couldn't get in touch with the author of the script. I did find a very patient friend who knows Ruby and he was able to correct the script so that it no longer has the problems with components that aren't aligned with the global axes. I have edited my DCB blog entry and uploaded the new version there.
 
It still doesn't seem to be working correctly
rotated_components.gif


I created a cuboid form, made it a component, then copied it. I made the new component unique, then triple clicked to select it and rotated it.

All components then selected and cutlist 33a was run.
 
"I made the new component unique, then triple clicked to select it and rotated it. "

Can you post a screen grab with the components highlighted?

This sounds like you've rotated the geomtry inside the component. Don't do that. In fact you should never do that. Going by your description, the component should still have been highlighted after making it unique. At that point you should get the Rotate tool and rotate the component.
 

Latest posts

Back
Top