See the stacking formation of bricks above? How would you think one could achieve this inside Blender? Any idea?
Python scripting could definitely give nice solutions of object stacking like above. At the moment, I am still working on my Python skill, so it is going to take a while if I actually write script. There is probably script out there that does similar thing. This is after all, a classic CG problem.
NO SCRIPTING WAY
So, if not scripted, maybe we should look for different ways we can achieve this?
Stacking of objects is actually an interesting Mathematical problem. To create a bricky structure that is truly procedural, using random size of objects, and stack it on top of one another without interpenetration happening between objects. Can the basic structure shape be based on a simple object supplied by user? (cylinder, taper, sphere, maybe alphabet letter)
Other objects that require stacking logic:
- Books
- Buildings
- Cardboard Boxes
- LEGO (of course!)
- Google Image Search (ever wonder how those image nicely stacked on top of each other?)
There are many possible solutions for this matters. I am interested to know your solution to this problem :)
Maybe:
- Use Bullet Physics? Just place objects and then let it dynamically relax.
- Maybe use NodeBox2 solution?
- Maybe you can just fake it using Boolean?
- Can we use Particles?
UPDATE 2012.08.24
PARTICLE SOLUTIONS:
Ok, here is one of easy solution hack for this.
We know that it is really easy to get a brick structure using Array Modifier. So we can start from that organized structure of bricks (ABOVE IMAGE: Top). Easy to do manually, just few seconds of setup.
Now, to actually randomize the structure, we then use Particle Group Instancing to replace each structured brick with a randomized version of the bricks. Here, I supplied 4 different variation bricks.
By replacing each bricks with imperfect structure, you get something that is more or less random (ABOVE IMAGE : Bottom).
Further tweak, you continue apply all kind of randomness using Modifers.
- Displace Modifier
- Subdivide: Simple
- Displace Modifier
- Smooth: Iterate
- Displace Modifier
- and so on...
Furthermore, you can always go to the base and do manual tweak or sculpt it. This add more natural randomness.
Then next is just adding some procedural texture and displacement. By now, your eyes can no longer see the pattern and your brain will think that the brick model is more complex that it actually is.
Basic building block and template = SIMPLE. Mixing them together = will give you a more complex result. |
BONUS: Voronoi Method
You can also do something like this using the Cell Fracture in Blender (get version 2.64 up).
This is kind of procedural too, but once-off Python script method.
In fact, the Cell Fracture is doing a lot of procedural hard work, Boolean and clever checking of overlapping and deletions. The resulting voronoi shards of Cell Fracture is not always 100% perfect, but it is pretty good.
Combine this kind of thing with Blender incoming Bullet Physics, it is just great.
BLENDER INSPIRED HOUDINI, HOUDINI INSPIRED BLENDER
All these kind procedural stuffs was actually inspired by Houdini artists.
I was doing this earlier today inside Houdini:
http://houdoodles.blogspot.com.au/2012/08/procedural-brick-stacking.html
The stacking can be done procedurally and in real time. It is the strength of procedural package like Houdini. But you know, Blender is also magical and awesome in my personal opinion.
It is fun to see Blender to work with other 3D tools and how you would approach one problem using all set of different tools.
Check out another example below:
"Houdini Voronoi Procedural Rock Brick Generator" by Johnny Core.
UPDATE 2012.08.26: WALL FACTORY ADD-ON
I got this info from Liero at Blender Artist forum regarding pending Blender Add-On called "Wall Factory":
http://wiki.blender.org/index.php/Extensions:2.6/Py/Scripts/Add_Mesh/WallFactory
That is something to look into, in near future. Apparently still WIP (work in progress), not yet final:
SEE ALSO
http://wiki.blender.org/index.php/Extensions:2.6/Py/Scripts/Add_Mesh/Masonry
http://www.blender.org/forum/viewtopic.php?t=18934&sid=b8993d9226716d562bd39c7a2ec99730
UPDATE 2012.12.25
See also:Advanced Array Modifier by Fabio
https://vimeo.com/34468992
http://www.blendernation.com/2012/01/05/advanced-array-modifier/
Post a Comment