A new modifier for adding randomness to mesh objects, duplicated objects and arrays

Hi,
Indeed, the ‘individual vertices’ mode has some similarity with the displacement modifier. It is a bit simpler to set up, not needing any texture, but far less powerfull, being in a way too random, or ‘only random’. Textures are far more flexible. I did have plans to allow for random vertex displacement to be either along normal or tangent to normal, or a bit of both in a configurable way, instead of x,y,z.

Anyway, this ‘individual vertices’ mode is not the main purpose, it’s more like a by-product. The main goal was to give randomness to objects after they are duplicated by an array modifier. Extending the array modifier could work fine for one dimension (instances in a single ligne), but cannot work for 2 or 3 dimensions, because the second array modifier on the stack only sees as its input the line of objects that came out of the first array modifier. For that reason at least, you may only distinguish loose parts, and a dedicated modifier, or at least distinct from array, is a better approach.

It was suggested to add these features as new modes to the displacement modifier, and indeed there is some logic to this, since be it vertices, a whole mesh or loose parts, be it randomly or along a texture, it is displacement that we are doing. But the displacement modifier is so much associated with textures to every Blender user, that I fear many would not turn to it for the new features. But I’ll gladly implement it this way if there is a consensus for extending the displacement modifier.

Anyway, I’m happy to see there is some interest for these features. The ‘Whole Mesh’ mode, together with ‘object Id as seed’ option, can also be a useful thing I believe: you copy objects, be it by shift-D or alt-D, and yet they are not perfectly identical.
I’ll be working on it some more and propose again. Maybe it can go into a 2.7x.

@blenderman75: yes, modifiers like this need to be in C, cannot be implemented in Python.

On adding the individual vertices to the displacement modifier, I do have to admit that I really question the usefulness of having a dumb ‘random displacement’ of vertices rather than just sticking to mesh pieces.

A far more useful addition to the displacement modifier, in my opinion, would be to allow all of the resultant displacement be unidirectional, this would finally make the displacement modifier useful for things like rugged, but tight-fitting stone structures and together with the piece displacement would make the system very powerful for stone or brick walls.

Also, perhaps instead of random vertex displacement, you have piece displacement that can be driven by a texture (because the random displacement can already be done by plugging a very high frequency clouds texture into the displacement modifier).

@patb, really nice job, I hope we can find a consensus pretty fast so that you can concentrate on your work instead of speaking about design all day. How can I test your patch?

@@matali

I’m not a pro… on the old bugtracker, ppl tended to write the revision number on which the patch could/should be applied. Here I can’t find it. Can I apply it on any revision ?

I just tried to apply and it doesn’t work, it seems that you’d need a version that predates the additions of the wireframe and the laplacian deform mods (so a couple month old).

sorry, i don’t have access to my computer till sunday. I am not aware of any dependancy, I worked on an svn extract of like 2 weeks ago. I will be happy to help anyone willing to test, as soon as I am behind my keyboard.

Hi patb,
COudl you make a version of your patch that will work with the official 2.70 source? The decision of integrating it may take very long. In the meantime, a custom build with your patch will make many people happy I think.
All the best.

Hello matali,
It’s done: https://developer.blender.org/D320
I just uploaded a new patch, that has several new features, some fixes, and more importantly is based on 2.70-rc.
Hope you like it. Thank you for your feedback.

New features in latest patch (https://developer.blender.org/D320) include:

  • Rotation and Scaling for Whole Mesh and Loose Parts mode now works. Pivot point is center of loose part bounding box.
  • An overall “factor” setting for the whole modifier.
  • In Vertex mode, it’s now possible to constraint offset along normals.
  • Translation, Rotation and Scaling may be defined through another object; similar to what is done in the array modifier, except it’s override, not multiply.
  • 3 modes for randomness:
    • Constant: displacement is identical for all items, but is dependant on “probability” setting.
    • Linear: displacement is between -max and +max, with equal probability.
    • Gaussian: displacement follows a normal distribution, centered on “maximum” (used as average), and with defined std deviation.

I hope this makes the modifier consistent and powerfull while not making it to complicated.

All feedbacks very much welcome. Thanks. Patrice.

Hi patb,
thanks for the patch :slight_smile: I didn’t had time to compile, but the previous version already worked pretty well :slight_smile: As some people already mentioned, I think your idea to process the mesh by loose parts could be very helpfull in other modifiers. For the Shrinkwrap case, as you thought your modifier as a “modifier modifier”, maybe instead of modifying the shrinkwrapcode, we could use the min/max or mean values on x, y or z in each loose parts of the shrinkwrapped mesh and align all connected vertecies on one of those values to get plannar ngons. Hope you see what I mean ^^ A kind of “flaten by loose parts” option. I’m mostly a python coder, very little knowledge in C so can’t really help to code, but that’s how I would do it.
Really great job :slight_smile:

Hi, can someone help and compile a windows x64 build with this when 2.7.1 comes out in a few weeks. Thanks.

An excellent add-on, for animators also, really hope it gets into trunk. One step closer to Cinema 4D’s Mograph Cloner!

Hi, Can someone do a 2.71 build win64 with this modifier? Thanks.

Is there a wat i can get this to work on mac? Or perhaps a other way to give random rotation. I have a stack of business cards which i want to move randomly in x, y and z rotation. I know did this by adding a constraint to them all and than use different influences on all of them. Problem is that i need to set these all manually

I believe the newer builds of Blender should now have a deselect option for the select random operator, so it should allow you to offset a bunch of randomly picked cards at once.

On the patch itself, I heard before that there were plans for a ‘patch amnesty’ period where more focus would go on patch review, can a dev. tell us if it’s still being planned, is ongoing, or simply forgotten altogether?

i found a mac build in one of the links above, it works great!!!. One thing i miss or perhaps its said is that you can animate this randomness?! My manualy setup can but its kind of tedious to setup

Attachments

Businesscard_55x85.blend (281 KB)

When this modifier will be added to the master?

It was rejected, see https://developer.blender.org/D320 for more info on the subject.

Campbell made a pretty good mention in the comments about something like this requiring perhaps an improved modifier system that would be based on nodes.

A node-based system, I think, would be the definitive way to go since it would allow dozens, perhaps even hundreds of possibilities that are either clunky to do or can’t be done with the existing stack. It would make Blender a little more like Houdini in terms of what can done with meshes.