Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Forums Maxon Cinema 4D create content with Xpresso = duplicate, clone or create instances?

  • create content with Xpresso = duplicate, clone or create instances?

     Tom Morton updated 3 days, 11 hours ago 2 Members · 6 Posts
  • Tom Morton

    June 23, 2022 at 11:14 am

    Hello there,

    I’m using R20 Visualise which doesn’t include Mograph. Incredibly frustrating, I’ve come across many times I’ve needed it.

    Can I create a basic cloning tool in Xpresso? Can I select an object and programmatically create a number of clones or instances of the selected object, and distribute them evenly, all entirely with Xpresso?

    I can get around Xpresso fairly well, but I can’t find a node for creating or duplicating an object – is there anything that can be utilised for this? And I’m not familiar with Python to go down that route.

  • Andy Kiernan

    June 23, 2022 at 12:51 pm

    not my area really, but, one way may be to, for example, make say 10 cubes, put under a null and then use xpresso to iterate through them and create offsets etc. As far as I know xpresso cant create geometry though. Even though you have no MG tools, isn’t there still arrangement tools under the ‘tools’ menu? like array etc…

  • Tom Morton

    June 24, 2022 at 8:39 am

    Thanks Andy, appreciate your reply.

    In visualise I do have a a couple of arrangement tools but quite limited. I have a Array and Atom Array. Array is excellent but limited in that it can only array on a circle, and not a straight line. If I could only create a straight line it would solve most of my problems. See tools attached.

    I’ve been using the Duplicate tool ( Tools > Arrange Objects > Duplicate) which works ok but I find it annoying that I can’t tweak parameters after the event. It creates a bunch of hard copies while Array does it programmatically, allowing me to add or remove copies after it has been applied. Does seem a shame there’s nothing in visualise to array on a spline or at least a straight line.

    I had wondered if I could use Particle Emitter or Array to create the instance copies programmatically and then use Xpresso to manipulate their position. Not sure if that’s possible yet.

    See second image attached, I’ve got an idea of the process: user data defines how many copies of the object. Link it to the radial array and create these copies. Iterate through the objects and redefine their position according to a formula.

    But a lot of ??? involved – is it possible to iterate through objects that aren’t objects (Array objects don’t appear in the hierachy). Can I change their position even if I can identify them? etc

  • Andy Kiernan

    June 24, 2022 at 11:17 am

    i cant see any way to make it work with an array no. I made a thing, its not very flexible and may not be any good but here you go! The workflow would be, make an object, use the duplicate command (or just cmd+d a load) have all copies under a null. use expresso to iterate through them, then multipy the index with user data/ constant value to create an offset to distribute our ‘clones’!

    Hacky but maybe something to start with, maybe? no? sorry 😪

  • Andy Kiernan

    June 24, 2022 at 11:18 am

    …. made with R26, so if you cant open it here is image of xpresso

  • Tom Morton

    June 24, 2022 at 11:34 am

    Looks good Andy, I’ll have a look at this later and let you know – thanks!

Viewing 1 - 6 of 6 posts

Log in to reply.

We use anonymous cookies to give you the best experience we can.
Our Privacy policy | GDPR Policy