Instancing Options in Carrara

MythmakerMythmaker Posts: 606
edited December 1969 in Carrara Discussion

A few questions about instancing...

Will Vertex room duplicates considered replicated instances in Assembly room?

https://www.youtube.com/watch?v=B1aR7x7zhJM
Is this kind of "brush on surface" instancing possible in Carrara, either via Modeling tools or some plugins?

Thanks.

Comments

  • WendyLuvsCatzWendyLuvsCatz Posts: 37,954
    edited December 1969

    You can use a distribution map for surface replication, this can be painted using 3D paint
    I usually use a channel like shininess not being used loading a white png map saved for painting then cut and paste the texture in use texture in distribution for the replicator.

  • evilproducerevilproducer Posts: 9,040
    edited December 1969

    Mythmaker said:
    A few questions about instancing...

    Will Vertex room duplicates considered replicated instances in Assembly room?

    https://www.youtube.com/watch?v=B1aR7x7zhJM
    Is this kind of "brush on surface" instancing possible in Carrara, either via Modeling tools or some plugins?

    Thanks.


    3D paint won't let you "paint" objects onto the surface in realtime, such as in your youtube link, but as Wendy said, you can make a distribution map that you can use to tell the surface replicator where to place objects. It will still be randomized. If you need to place specific objects in certain places, you will need to do that manually. My preferred method, is if I need a tree in a specific place, but I also need that tree replicated, I'll place my tree where I need it, and then use that in the replicator.

    As to duplicated objects in a vertex model. they might lower system overhead if the duplicates truly refer back to the original, as they do in The Assembly room, but I honestly don't know. As far as I know, the way they are handled in the Assembly room as far as manipulation, is as a single vertex object. The VM isn't my strongest area. ;-)

  • TangoAlphaTangoAlpha Posts: 4,584
    edited December 1969

    Pretty sure vertex room duplicates are real mesh - if you duplicate something in the vertex room, you'll see the polygon count go up by that amount.

    My grass props - I only ever created one blade of grass - 8 polygons. Duplicate, tweak, duplicate, rotate, tweak, duplicate, scale, tweak etc. The final vertex model is around 6000 polys.

    But go to the assembly room and duplicate the vertex model, you only have a single instance of it, but multiple references to it. In memory terms this is the same as replicating an object. (BTW, if you duplicate a replicator, there is still only one actual instance of the vertex object - the master.

    You can tell if an object is a referenced object, since if you edit it, Carrara will ask if you want to edit the master or create a new one. If you create a new one, Carrara will spawn that object into a new real instance. I don't think there's a way to tell if an object is the master or just a reference - both behave the same way.


    "Instances" in Studio are a misnomer, since the only actual instance (i.e. real polygons) is the master object. All the others are references. it's also not a fully featured surface replicator like we have in Carrara, but that's another discussion.

  • MythmakerMythmaker Posts: 606
    edited March 2015

    Thanks for the tips...

    Wendy, that's another good tip from your magical bag of tricks and workarounds. I was thrilled enough by the distribution map capability. Hopefully in Carrara 9 we get to paint distribution mask on the fly in Assembly room.

    EP, yeah I'm exploring various instancing methods in Carrara. Reducing overhead is the main goal, also I love procedural workflow. I'm hoping for something more like controlled scattering. Better still "collision sensitive" scattering like they have in some game engine. Another plugins wish list I guess.

    Tim_A, yes Carrara is the only app I know that use the term Instances that way, REAL instances vs Instances Instances. LOL. I'll settle for "clones" vs Reference object (very long to type). So according to your experiments the vertex room model's nested clones won't port over to Assembly room.

    I've only discovered yesterday it is possible to vertex edit in Assembly room, albeit limited, maybe there are ways to clone/ replicate objects more dynamically in Assembly. It would be cool if there is Instancing by Path or Spline too in Assembly too, not just for positioning objects but making it possible to animate a flock of bird or school of fish in Carrara just by dragging along the master bird.

    Would be really cool if we could just brush on trees and grass and even animated people and butterflies and pigeons on the plaza. That would be so fun.

    Or...ability to import instances from other apps, like ZBrush... Haha dream on I know... Carrara 9? Plugins? Yes please.

    Another area I haven't explored yet is using Octane's instance scattering feature...

    Post edited by Mythmaker on
  • WendyLuvsCatzWendyLuvsCatz Posts: 37,954
    edited December 1969

    I draw polylines and join them and fill polygons for flat surface replication in the assembly room from top view
    also duplicate terrains and convert to other modeler then delete chunks make invisible by unticking visibilty and use those too for surface replication
    are lots of ways to get what you want

  • MythmakerMythmaker Posts: 606
    edited December 1969

    I draw polylines and join them and fill polygons for flat surface replication in the assembly room from top view
    also duplicate terrains and convert to other modeler then delete chunks make invisible by unticking visibilty and use those too for surface replication
    are lots of ways to get what you want

    The polyline method sounds great. Am still new to Carrara's very rich modeling options. Will wrap my head around the 'convert to other modeler' and back method. Go experiment now... Thanks!

  • MythmakerMythmaker Posts: 606
    edited December 1969

    So I built a new China style planned city today. A few buildings insist on occupying main roads. Oh well. Too lazy to move them.

    I like Surface Replicator and Carrara Shaders. Fun.

    surfacereplicatorcity.jpg
    1280 x 720 - 517K
  • evilproducerevilproducer Posts: 9,040
    edited December 1969

    Mythmaker said:
    So I built a new China style planned city today. A few buildings insist on occupying main roads. Oh well. Too lazy to move them.

    I like Surface Replicator and Carrara Shaders. Fun.

    Are the roads an image map? If so, load it into an image editor and use it to create a black and white version and Save As. In Carrara, open the editor for the surface replicator, then on the right side of the screen, choose to use a shader. Carrara will then open the Texture Room and open a shader for you. You can choose Multi-Channel, and in the color channel, load the black and white image map. All the other shader functions can be turned off. You can even copy the image map and force-paste it into the very top level of the shader if you wish.

    If the black and white image should be white and black, then simply enable the reverse color option in the image map's thumbnail area.

  • MythmakerMythmaker Posts: 606
    edited December 1969


    Are the roads an image map? If so, load it into an image editor and use it to create a black and white version and Save As. In Carrara, open the editor for the surface replicator, then on the right side of the screen, choose to use a shader. Carrara will then open the Texture Room and open a shader for you. You can choose Multi-Channel, and in the color channel, load the black and white image map. All the other shader functions can be turned off. You can even copy the image map and force-paste it into the very top level of the shader if you wish.

    The roads are auto-generated with native shader pattern channel. The buildings and trees with single poly primitives + pattern shaders too. I wanted to experiment keep it really basic and dumb and see how Carrara instancing can be used to make "autogen city".

    I'm a city sim game fan. Next thing to play with is generating highways and riverways by some kind of path. Maybe Wendy's polyline method.

    Not sure if it's the most efficient or correct way, but to make sure the source plane pattern matches the distribution pattern I saved the source plane shader as a custom preset then drop it into the distribution master channel.

    Is it possible to stake multiple distribution masks? Say one channel for river, one for roads, one for trees...etc?

    By copy and force paste do you mean texture map straight from explorer into color channel? That would be handy.

    But is it faster to 3Dpaint the distribution masks? Another room area I haven't explored.

    I also put a fog object in the scene, enough to fill the production frame. Wow instantly slowed down test render...

  • JonstarkJonstark Posts: 2,738
    edited December 1969

    I don't have it (but the more time goes by I keep thinking I need to go get it), but wouldn't the Baker plugin from Inagoni allow you to turn your procedural roadmap into an actual image, which you could then use the way Evil describes? This is armchair rendering from me since I don't even have the plugin, so I could be way way off on this, but that was the first thought that popped in my head.

  • MythmakerMythmaker Posts: 606
    edited December 1969

    Jonstark said:
    wouldn't the Baker plugin from Inagoni allow you to turn your procedural roadmap into an actual image, which you could then use the way Evil describes?

    I have Inagoni bundle in my wish list, lots of useful stuff. Just not sure if all still work in C8.5... Will check out Baker.

    Painting alpha map as mask externally is a familiar thing to me, the easiest path. Right now I feel a need to get to know Carrara's shader dept a little better. It seems there are many interesting ways to achieve the same thing. Trying not to overwhelm myself with so many great tips lol.

  • TangoAlphaTangoAlpha Posts: 4,584
    edited December 1969

    Export to obj has an option for baking procedural textures (I think it has a 2k x 2k limit), but it may produce a usable map that you can convert to black & white for a replicator distribution map. White will be where your replicated objects go, and black where they don't. It does have to be pure black and pure white. If you want to vary the density of objects, you'd need to use halftoning.

    In the replicator window, tick the 'Use Shader' option and set up the shader like you would any other texture image based shader. You only need the colour channel - all the others can be cleared or left at default.

  • MythmakerMythmaker Posts: 606
    edited December 1969

    Tim_A said:

    Export to obj has an option for baking procedural textures (I think it has a 2k x 2k limit),
    It does have to be pure black and pure white. If you want to vary the density of objects, you'd need to use halftoning.

    That's useful to know. Thanks!

    In the replicator window, tick the 'Use Shader' option and set up the shader like you would any other texture image based shader.


    That's how I generated the "roads" in my pic. I included a color gradient which is why some buildings bled onto roads. 4 keys is too much "halftoning" I think...
  • evilproducerevilproducer Posts: 9,040
    edited December 1969

    If you're using a procedural to generate the roads,it is possible to copy the shader tree that generates them and then paste it into the distribution shader. You would just need to change the colors to black and white. No need for an image map!

  • evilproducerevilproducer Posts: 9,040
    edited December 1969

    Mythmaker said:

    ....Is it possible to stake multiple distribution masks? Say one channel for river, one for roads, one for trees...etc?

    By copy and force paste do you mean texture map straight from explorer into color channel? That would be handy.

    But is it faster to 3Dpaint the distribution masks? Another room area I haven't explored.

    I also put a fog object in the scene, enough to fill the production frame. Wow instantly slowed down test render...

    Force drop or paste is from one shader type into another that Carrara doesn't like. Such as if you try to drag and drop something like an image map from the color channel into the very top level of the shader, then Carrara will tell you it doesn't like it, and ask if you want to force-drop it anyway.

    Regarding the multiple distribution maps, if you want roads and rivers on your terrain via shader functions, then yes, it is certainly possible. You would want to use the Terrain Shader at the top level. Then just click the little plus icons to give you more terrain layers. Each layer will give you a distribution shader channel. Normally all you'll be able to choose to use in that slot is a procedural shader, but if you load an image map into the multi-channel shader's color channel and then copy and paste it into the distribution channel, you can use an image map. You can then clear out the color channel and do whatever you need to do to get a river or road.

    Forgive me if I'm babbling, I have a nasty spring head cold.

    Picture_3.png
    878 x 870 - 127K
  • MythmakerMythmaker Posts: 606
    edited March 2015


    Force drop or paste is from one shader type into another that Carrara doesn't like. Such as if you try to drag and drop something like an image map from the color channel into the very top level of the shader, then Carrara will tell you it doesn't like it, and ask if you want to force-drop it anyway.
    This is such a cool feature I wished DS and iClone had. Yay!


    Regarding the multiple distribution maps, if you want roads and rivers on your terrain via shader functions, then yes, it is certainly possible. You would want to use the Terrain Shader at the top level. Then just click the little plus icons to give you more terrain layers. Each layer will give you a distribution shader channel. Normally all you'll be able to choose to use in that slot is a procedural shader, but if you load an image map into the multi-channel shader's color channel and then copy and paste it into the distribution channel, you can use an image map. You can then clear out the color channel and do whatever you need to do to get a river or road.

    OMG I knew there's something special about the terrain shader but don't know what exactly and now I know. Perfect! Thanks so much!

    Hmmmm the stuff I can do with this...head spin....

    Forgive me if I'm babbling, I have a nasty spring head cold.
    FWIW I'm going to recommend my pro physio lil sister's ultimate one size fit all cure, natural wintergreen oil diluted 2x, dab on temple, rub on feet bottom, socks on, snooze. Will at least reduce aches like aspirin without the side effects.

    Post edited by Mythmaker on
  • WendyLuvsCatzWendyLuvsCatz Posts: 37,954
    edited December 1969

    I force drop on the blighter all the time no matter how much it whines :-P
    can get some really cool effects or nothing but no harm in trying

  • DiomedeDiomede Posts: 15,088
    edited December 1969

    Any shader that you can create black and white (and imbetween) regions for can be used to control the replicators, For example, you can use a terrain type shader and replicate just on steep slopes, or just on flat areas. Or, you can replicate only in high elevations, or only on low elevations. Or, you can use the wires shader to replicate only on the lines, or only off of the lines. Or, as people have said, you can use the 3D paint tool to create the zones.

    The following thread may have a few useful tips in various posts.

    http://www.daz3d.com/forums/discussion/38177/

  • RoygeeRoygee Posts: 2,247
    edited December 1969

    You can also use the terrain shader for distribution - trees only below a certain height, or only on flat ground and grass on slopes, etc.

  • MythmakerMythmaker Posts: 606
    edited December 1969

    Thank you everyone for your tips. Carrara is more procedural capable than I thought. So many Carrarists candies too, and so little time!

    Diomede, will definitely check out yet another one of your gems.

  • evilproducerevilproducer Posts: 9,040
    edited March 2015

    Procedural shaders are a real strength of Carrara.

    I would link to it, but there is nudity and the puritans would freak out, but there is tutorial on how to make a completely procedural skin shader.

    It's interesting stuff.

    Here's a link to a skin shader I built based on the tutorial. Since I don't have a version of Carrara that supports Genesis, I built it on a V4, so even though the skin shader uses no maps for color or textures, I did use some distribution maps to soften the edges of a couple shading domains, such as the lips/face. As such, the UVs for the distribution maps are based on V4, but it is possible to copy and paste the base skin shader, or lip shader and nipple shader into any figure's various shading domains.

    I also included dynamic hair eyebrows and eyelashes. Those do need to be applied to a V4 mesh.
    http://www.sharecg.com/v/77436/view/7/Material-and-Shader/Carrara-V4-Procedural-Skin-Shader-and-hair

    Sexy_September_challenge03.2_.jpg
    2000 x 1333 - 872K
    137510.jpg
    1500 x 1680 - 413K
    Post edited by evilproducer on
  • MythmakerMythmaker Posts: 606
    edited December 1969

    EP, that's one good use of procedural shaders! And nice work you have there. Bumped into some of your vids on utube, looks like you've been doing some cool stuff since like 2009? Every time I see older videos with "what Carrara 6/7 can do" I want to kick myself for not arriving here sooner.

    Now I need to stop thinking character texture sets and start thinking of my actors as "terrains" lol. Mother Gaia etc...

Sign In or Register to comment.