Need extension to fill large object with smaller objects

Given a truncated icosahedron, calculate its volume. Then given any large, arbitrary shaped object, fill the large object with as many Icosahedrons as will fit.

Does anyone know how to do this?
Is there an extension I can use (or purchase) to do this?

Sounds alot like the old Voxelize extension I helped cleanup. It is by “The Dro”.
It filled a group or component volume with cubes I think, if memory serves.

The Voxelize plugin thread over at SketchUcation Forums:
… and it’s SCF PluginStore page:

Perhaps the code could be modified to use an icosahedron as the “voxel” ?

Or just do it manually …
The author mentions that after doing the voxelization, that editing one of the components instances will change them all. (This is because of the SketchUp fact that editing an instance really puts you into the editing context of the common definition of all the instances of that component. Ie, instances do not “own” a geometry collection, only definitions do.)

P.S. - It has been a long time since that ol’ plugin was released, and it may not have been updated to run under Ruby 2.x. You’ll just need to try it.


Thanks for pointing me to the Voxelize extension. I am able to install and run it successfully. I am able to modify it and load my modified version. It is a good template for proceeding. And yes, you were correct in that it approximates what I had described. Community discussion groups work well for connecting requests to solutions.

I concocted six tests. It met my hopes/expectations for how it should respond.

  1. I created a cylinder and it voxelized it. I see that if the majority of a cube would be inside the circle, it generated that cube, but if the majority of the cube would be outside the circle it did not, thus giving the rounded effect.
  2. I created four standalone columns. It voxelized each individual column and no stray cubes in the empty space.
  3. I laid a surface on top of the four columns turning it into a table (or crude bridge). Voxelized as expected.
  4. I raized the centerline of the bridge and then raised the centerline of the two halves to different heights, thus making a crude drawbridge shape. It voxelized successfully.
  5. I created a building that was a half circle in the first 100 feet, and on its roof I placed a tower, a hexagonal utility structure, and a round skyway between those two roof structures. Voxilized successfully, with empty space below the skyway.
  6. I voxelized that multi-shape structure with half-foot cubes. It took a long time, but it eventually completed the task successfully.

Although I am a good programmer, I am not proficient in either CAD, Ruby, or Sketchup. So progress by me would be slow and inefficient. I have a small budget for modifications.

Are you still in touch with Andrew? A web search turned up his web site (as of 2015) - I will send a variation of this message to him. The intent is to see if either of you are interested in updating the program and/or know of some SketchUp programmer interesting in undertaking this task.

To Do:

  1. add an offset option to provide for space between the voxels. For example, replacing 1’ cubes, I would want 9" cubes separated by 3" empty space (additional user input for the space dimension).
  2. change the cubes to icosahedrons (thus changing the app from a Voxelizer to an Icosalizer)
  3. pre-calculate how many objects will be needed to fill the big space
  4. if it is a big number and sure to be slow…
    4a) give the user a dialog box with the precalculated numbers and a “Do you want to proceed?” option
    4b) a progress bar
    4c) a keystroke or mouse click to be able to abort processing
  5. following the completion of the voxelizing/icosalizing, report to the user the volume of the space filled and how many items were generated to fill it.

I am doing this work for a company called C6XTY. They are in Vancouver WA (in the Portland OR metro area). Their product is a 3D lattice of truncated icosahedrons, interconnected with different types and shapes of connectors, resulting in different characteristics for construction. It is “assembled” material - as pieces are connected the lattice has structural integrity. Thus conceptually you could assemble a bridge out across a chasm starting from either side. See

I have attached a PDF file and a couple of photos that will give you a sense of technology and uses behind this request for an “icosalizer” module.


Griff Jay
(541) 231-6429
C6XTY Applications.pdf (838.9 KB)


1. Can be done by editing the voxel definition, and scaling down the geometry about the center.

2. Can be done (as mentioned above) or with existing component replacer extensions.

3. Don’t know offhand. (Have not read the code in years.)

4(a). if 3 is possible, no problem using UI.messagebox, …

return unless UI.messagebox('Do you want to proceed?',MB_YESNO||15) == IDYES

4(b). Progress Bar interface has not been implemented in the API’s UI module. (We have asked for one like … forever.) They are rather difficult to hack. Often we just show a series of pipe symbols on the status bar but if the user moves the mouse they disappear.

4(c). abort on keystroke or mouse click would require implementing a tool interface which is kind of weird as this is an automated process and tools usual wait for user input and interact with the model.

5(a). The user can get a volume amount in the Entity Info inspector panel even before the voxelizing. Select the manifold group or instance. (The plugin could easily store this value for later display.)

@volume = grp.volume

5(b). the number of instances of a given component definition is trivial to get …

num = comp_def.instances.count

… or …

num = comp_def.count_instances

… or …

num = comp_def.count_used_instances

Thank you, Dan. Helpful.

BTW - I was able to contact Andrew S. He was flattered and amused that his voxelizer extension had found a fan.


1 Like

2. Can also be done via the “In Model” component browser …

RMB on the voxel component definition > Reload … (from the context menu)
Choose a SKP definition file from the explorer file open dialog …
Click Open button.
… all the instances of that component are replaced with instances of the new definition.
(… and it appears the old definition is automagically purged from the “In Model” components collection.)

Yes, of course this can also be done with code.

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.