Of domains and texture sheets, shaders &c.

TangoAlphaTangoAlpha Posts: 4,584
edited December 1969 in Carrara Discussion

This really amounts to an issue of "best practice" rather than the nuts and bolts of "how to".

I have a vertex object, which is reasonably large and reasonably complex - it's a bridge with arches and a covered walkway with steps and a house on top (see pic). Now I built it as a single vertex object because it's logically a single model - there's a wall running all the way from one end to the other, for example (see pic), and everything needs to fit exactly.

I've split it into a number of shading domains - roof, walls, arches, pillars columns, steps, paths etc and UV mapped it.

The question now comes, how best to allocate texture sheets, etc. When I was designing stuff for flightsim, the "rule" was, fit everything onto a single texture, and map all the shaders to use it. So there would be a single diffuse, a single bump map and so on, with each shading domain allocated a specific area on it.

Is that a good practice also in Carrara? This particular model would probably need 2 4k texture sheets with that method - one for the bridge section, and one for the "dry arches" section. That actually throws up a separate issue, of how to export a template that contains 5 out of 10 domains. It seems that Carrara will only export "everything" or a single domain.

Or is it better to have each domain fill a texture sheet of its own? That will result in a lot of texture sheets, some being smaller and others containing lots of empty space.

If I were to decide to use a "material" type shader for a particular domain (e.g. a general stone or concrete etc shader), would that affect how I UV map it?

I'd appreciate your thoughts and comments. :)

Screen_Shot_2014-07-01_at_23.11_.41_.jpg
1499 x 727 - 290K

Comments

  • 3DAGE3DAGE Posts: 3,311
    edited December 1969

    Hi Tim :)

    There's no hard and fast rules, but best practice, and the desire to show your model at it's best, determines that you allocate UV space to the areas that will be most visible, and sometimes that means splitting things up to add another Texture map (image).

    Don't be afraid of having multiple texture maps ,.. see any Daz figure as an example.
    Trying to fit the world onto a page, gives you very little detail

    for example, a vehicle: you may want to have a lot of detail on the bodywork, so you'd make that as large as possible,. then you realise that you're left with a tiny space for the wheels,. (which you'd like to detail with a tread displacement map) so the simple option is to create a new Texture Map and Shading domain for the wheels so that you can have the detail you need for that section.

    By splitting the model into logical sections, It should make the UV mapping and texturing process easier.
    it can also make the model more flexible , since the separate sections can be arranged as the user requires them,. perhaps they'll only use a wall, or the bridge, and add other models to create a completely different scene.

    hope it helps :)

  • TangoAlphaTangoAlpha Posts: 4,584
    edited December 1969

    That makes sense. :)

    Do UV maps have to be square? Carrara always creates them square, but what if the object only fills half the map - a 2048 x 1024 texture sheet would surely be better than a 2048x2048 sheet that's half empty - only uses half the memory, yes?

  • eyeseeeyesee Posts: 172
    edited July 2014

    Hi Tim.

    It may not apply to your model, but I've noticed that Bump/Displacement is not always taken into account when setting up UV's.
    For instance with the new Dragon 3 maps you have the Torso map and the Eye map together and you have the Horn and Head maps together.
    It's not very likely your going to want to apply the same amount of Bump/Displacement to the Eye as you are to the Torso or the Horns and the Skin on the Head. Yet there isn't a seperate shader for Eyes and Horns.


    Eyesee (Jedi Tea Master - Mug fully charged)

    Post edited by eyesee on
  • wetcircuitwetcircuit Posts: 0
    edited December 1969

    eyesee said:
    Hi Tim.

    It may not apply to your model, but I've noticed that Bump/Displacement is not always taken into account when setting up UV's.
    For instance with the new Dragon 3 maps you have the Torso map and the Eye map together and you have the Horn and Head maps together.
    It's not very likely your going to want to apply the same amount of Bump/Displacement to the Eye as you are to the Torso or the Horns and the Skin on the Head. Yet there isn't a seperate shader for Eyes and Horns.


    I would think that even if it used the same image map, the actual shader in Carrara is probably different, so you could still adjust the bump separately for each shader... (I don't have this model, but I really hate UV maps that put eyes on the same image as a bodypart because I like doing shader effects on the eyes and they should just be centered on their own square map always, imo. I hate V4/M4 for their eye maps.)

    However, I recall that someone discovered the bump strength is related to the image map size. In otherwords a 512x512 image map with a bump strength of 10 will look different than a 2048x2048 image map with a bump strength of 10.... I believe this is an issue even when you mix-match procedural shaders with image maps, the size of the image map in the shader effects the bump strength (maybe other parameters too)...

    I would avoid overly large complex maps, the 3DPreview sometimes balks with too many 4k images on a model - but I would also go for procedural shaders more than image maps where I could because they are sharper and just more flexible for me... I like to try a lot of shader tricks and also reusing shaders. Too many maps slows down Carrara, but with 64bit it has become less of an issue, I think.

  • TangoAlphaTangoAlpha Posts: 4,584
    edited December 1969

    I think I need to understand more about procedural shaders and the kinds of things they're better for. My previous foray into 3D only allowed for maps, and required us to be very memory efficient (plus, my first computer was a ZX81, so you can understand my "every byte is precious" mania!) hence everything was crammed into a single texture sheet.

    Elsewhere in the scene, I have high numbers of kerb stones - they run along the edge of the river, hiding the join between the ground and the walls. They strike me as benefitting from all using the same small stone or concrete image map. But then the choice becomes many cubes in a vertex object (or a few vertex objects, as there are several different sections), or many vertex objects. (the cubes option is easier to build, since the kerbstones are not all identical)

  • evilproducerevilproducer Posts: 9,050
    edited July 2014

    Tim_A said:
    I think I need to understand more about procedural shaders and the kinds of things they're better for. My previous foray into 3D only allowed for maps, and required us to be very memory efficient (plus, my first computer was a ZX81, so you can understand my "every byte is precious" mania!) hence everything was crammed into a single texture sheet.

    Elsewhere in the scene, I have high numbers of kerb stones - they run along the edge of the river, hiding the join between the ground and the walls. They strike me as benefitting from all using the same small stone or concrete image map. But then the choice becomes many cubes in a vertex object (or a few vertex objects, as there are several different sections), or many vertex objects. (the cubes option is easier to build, since the kerbstones are not all identical)

    My entry in this month's Carrara challenge only uses one tiling image map on part of the main terrain. There's V4 and her clothes of course use image maps, but I'm referring to stuff I made for the image. I did (probably poorly) UV map the ruins, but all the shaders are procedural. I prefer them as I think it makes for a faster loading scene, and I like the control and effects that can be accomplished.

    http://www.daz3d.com/forums/discussion/42978/#634049

    Post edited by evilproducer on
  • DUDUDUDU Posts: 1,945
    edited December 1969

    Hi EP,
    You perhaps will find my question stupid, but what is what a procedural a shader ?

  • evilproducerevilproducer Posts: 9,050
    edited December 1969

    Hi EP,
    You perhaps will find my question stupid, but what is what a procedural a shader ?

    The short answer is that it is a shader that doesn't strictly rely on an image map.

    Holly's Photoreal Sun tutorial is an excellent example of using Carrara's shader functions to build a procedural sun shader.

  • DUDUDUDU Posts: 1,945
    edited December 1969

    Very well realized this tutorial, and in an original way.
    Thank you for the link !

  • DartanbeckDartanbeck Posts: 21,583
    edited December 1969

    Tim_A said:
    When I was designing stuff for flightsim, the "rule" was, fit everything onto a single texture, and map all the shaders to use it. So there would be a single diffuse, a single bump map and so on, with each shading domain allocated a specific area on it.

    Is that a good practice also in Carrara?

    That technique/practice is a good general idea for 3d modeling/textures across the board. But consider where it comes from: It was intended to give the model fewer maps to load, but also to make efficient use of the pixel dimensions being loaded. If you're using a 4k x 4k image map, it will cost 4k x 4k even if the actual mapped image is much smaller. So there is a trade off between loading several lower resolution maps and one higher. Some artists can easily fall into a trap of making texture maps larger than what is truly necessary to get the best result. But in the end, it's far easier to reduce an image than to enlarge one, when quality is concerned.

    Procedural Shaders
    Carrara can truly be your friend in this regard, as it comes with a really decent arsenal of examples in the shader tab, as long as you've installed the native content pack. Magaremoto, Ringo, and others here at DAZ 3D have some great additional examples via inexpensive addons to the browser. I mention this because "seeing" some of those nodes in use can really be a forehead-slapper for me. "Of Course! Why haven't I thought of that?!!!" as I look at how these masters achieve great results building up shaders from the procedural functions that the Carrara Photo-real render engine offers.

    It can be a fun exercise to load some of the procedural examples onto your mesh and experimenting with some of the many changes that can be made to further tweak the look into what you need it to look like.

    Remember, too, that Carrara afford us the ability to 3d paint our own displacement and bump maps as well.

    Finally, Yo Tim,
    I really enjoy checking out your modeling experiences in Carrara. You're definitely making some very cool looking environments!

  • TangoAlphaTangoAlpha Posts: 4,584
    edited December 1969

    Thanks Dartan - still got to finish one yet though!

    One of my biggest weaknesses - feature creep. Just add this... and this... and.... And I really do grind to a halt when it comes to the textures, hence this thread I guess :)

    I've got at least another dozen scenes on my to do list. But... refer to line 1!

  • TangoAlphaTangoAlpha Posts: 4,584
    edited December 1969

    My entry in this month's Carrara challenge only uses one tiling image map on part of the main terrain. There's V4 and her clothes of course use image maps, but I'm referring to stuff I made for the image. I did (probably poorly) UV map the ruins, but all the shaders are procedural. I prefer them as I think it makes for a faster loading scene, and I like the control and effects that can be accomplished.

    That looks really impressive - particularly like the look of the rocks.

  • evilproducerevilproducer Posts: 9,050
    edited July 2014

    Tim_A said:
    My entry in this month's Carrara challenge only uses one tiling image map on part of the main terrain. There's V4 and her clothes of course use image maps, but I'm referring to stuff I made for the image. I did (probably poorly) UV map the ruins, but all the shaders are procedural. I prefer them as I think it makes for a faster loading scene, and I like the control and effects that can be accomplished.

    That looks really impressive - particularly like the look of the rocks.

    Glad you found it! I see I forgot to link it! I'll edit the post in case anybody finds this thread at a later date!

    Here's a screen cap of the rock shader. It's pretty simple.

    Picture_3.png
    808 x 763 - 272K
    Post edited by evilproducer on
  • DartanbeckDartanbeck Posts: 21,583
    edited December 1969

    Tim_A said:
    Thanks Dartan - still got to finish one yet though!

    One of my biggest weaknesses - feature creep. Just add this... and this... and.... And I really do grind to a halt when it comes to the textures, hence this thread I guess :)

    I've got at least another dozen scenes on my to do list. But... refer to line 1!

    Well, you've mentioned earlier (first post in this thread) that you're keeping things to a single vertex object due to it making sense in terms of, well.. making sense. I must say that, especially with Carrara's beautiful feature of allowing us to model in the Assemble room as well as 'soloing' in the Model room, that we can easily join bits and pieces as separate objects directly in the modeling phase. To me, this means that we can make their 'point zero' location fit to where we need them to be compared to the rest of the objects in the scene. But much more, it allows us to make simple shapes as a single object. This makes mapping very simple and fast. Joining them together is as simple as selecting everything and typing Cntrl + G to group them.

    In this manner, we could use six simple planes to create a cube. Although we would likely rather our cube to be unwrapped as a simple cube so that our texture map can better flow from one polygon onto the other, the idea of mapping a plane is the way to go. So thinking along the lines of simple mapping, we can build simpler pieces that are simple and more accurate to map, and simply fit them together in a group.

    Using that idea, we can further create more complex models, separating the material zones in just the same, simple-to-map manner. Then we can make more complete, single objects that are still simple to map.

    So, in that regard, if you feel that your UV Mapping is good as the single vertex object, but want to have an accurate path toward texturing it, Try using Carrara's wonderful 3D Paint option to help in this endeavor. Allow me to elaborate:

    If you get comfortable painting in 3D right from the start, go ahead and start working on your textures, one shader domain at a time. Otherwise, since painting in 3D can take a bit of practice, you could start by simply using the 3D Paint system to make guides for use in helping you to create the final textures in a Paint program. You can even write notes or simple queue's to help you know what goes where - from 3D to flat map. This could be using different colors and just painting along certain edges, painting each wall section separately using a different color or texture for each... or whatever will give yourself a comfortable reference to assist you in lining up texture image maps onto your model.

    If Texture image creation is part of the issue, that's another matter altogether, but we can help in that regard as well. For example, I like using Dogwaffle because it has so many filters and automated assistance to help make nearly any sort of image, as well as more conventional art tools. Genetica, even the basic (which is the only one I've used so far) is very useful for making seamless tileable texture maps. Even if they don't need to tile, Genetica is a program that allows us to 'build' textures by applying nodes, mixing possibilities, etc., without ever having to access a brush. Like Carrara procedural shaders, Genetica comes with a full selection of presets to get us started. We can either tweak the presets or start from scratch. It's pretty cool. Others will either take photos of existing architecture or perhaps even make an actual piece of art and photograph it for a texture. 3rd Edition Dungeons & Dragons core rule books covers were made in a manner like that. The artist built the covers as models on his table, then photographed them, and finished the look digitally in photoshop. Really cool process.

    So anyways, try taking a step back and having a good look on how you think you can accomplish getting a texture onto a model. Think about the easiest way that you might be able to make that happen and try that.

    Sorry... I get too 'explainy' so I'm not clear if anything is coming off the way I intend it to be heard. After reading some of this, let me know how we can help further in any of these or other directions of help.

    FYI, these processes can be a real PITA. They can also be fun and rewarding. Like everything, we get better, and therefore more speedy and efficient as we practice. But it still takes time. Since time is something I have a hard time finding, I'll often rather buy in my assets, since DAZ 3D and similar marketplaces have such fantastic prices for some pretty amazing models. Not say that 'You' should give up... heavens no. Just wanted to explain why you don't see me posting a plethora of cool models I've made myself. I can model and texture, but I prefer to spend my time animating and creating scenes for animation. But I can still help you to figure out how to get this working for you. You certainly have a knack for making cool models.

  • TangoAlphaTangoAlpha Posts: 4,584
    edited December 1969

    Thanks for the encouragement, Dartan. :-) I'll make it a challenge to texture this building before I add anything else (well, maybe except another 16 hours in a day...!)

  • 3DAGE3DAGE Posts: 3,311
    edited December 1969

    HI Tim :)

    Do UV maps have to be square?

    No. you don't "need" to have square images,. (see some of the Carrara "Leaf" texture maps)
    The UV grid is always square, since it makes the process logical and easy to fit the model for the majority of texture maps.

    Carrara always creates them square, but what if the object only fills half the map - a 2048 x 1024 texture sheet would surely be better than a 2048x2048 sheet that’s half empty - only uses half the memory, yes?

    Kind of,... but a simple "all white" or all black image will use less memory than a multicoloured image.
    the different coloured pixels and their brightness, saturation, etc,.. will increase the file size of the image.

    I think I need to understand more about procedural shaders and the kinds of things they’re better for

    Procedural shaders can either be used as an alternative for texture based shaders, such as procedural brick, wood etc,
    or they can be added to texture based shaders to add more interesting effects, such as dirt and stains, or moss, etc
    and by building a few shaders which use the same texture map, but with different procedural shaders mixed into it, you can create multiple variations.

    Procedural shaders can also be used to combine (mix) several "texture maps" with procedural functions and colours to create more varied and detailed shaders. great for terrains

    You also have some different options when it comes to how the procedural shaders are mapped, whether you use the models UV's or use Global XYZ for mapping.

    I'd suggest starting with something relatively simple, like a Brick procedural. just to get the feel for what and how the different functions and options work.

    the Basic brick would be a Mixer, with two main colours,. Brick, and grout,. which looks kind of boring,. so by changing the "brick" source to a mixer, you can create a mix of two flat colours, and use a "Fractal noise" to blend them,. or you could use two Colour gradients, mixed with fractal noise,...which would give you even more colour variations.
    or you could take the simple Mixer of two sources, and make each source a mixer, (four colour sources)

    Try the same process with the grout or, "Mortar" shader, and you should end up with a pretty detailed brick wall.

    Hope it helps :)

  • TangoAlphaTangoAlpha Posts: 4,584
    edited December 1969

    I think I've buggered up my Carrara somehow - no idea what I did, but now I can't vertex edit in the assembly room. At least, I can't select anything. No matter whether I click, double click, drag a marquee around the object, nothing gets selected unless I go to the vertex modeller room and select it there.

    Also, and even worse, I'm trying to split one vertex model into multiple vertex objects. So I select the model, copy it and paste into a new empty vertex object. Yesterday this worked fine. Today... I get a giant version of the object half a mile up in the air!

    I have no idea what I did to make it behave this way! Any ideas how to get it back to normal? Thanks :)

    2.jpg
    1234 x 803 - 112K
    1.jpg
    1323 x 996 - 190K
  • 3DAGE3DAGE Posts: 3,311
    edited December 1969

    HI Tim :)

    strangeness abounds..
    I've no idea why the vertex modeller is causing issues,. but there is a way to easily break up your single vertex model.

    Edit / Split object.

    Try cleaning out your Daz Temp folder,. see if that fixes the VM issues.

    MyDocuments / Daz3D / Daz Temp.

    You should do this regularly, since carrara doesn't clean these temp files, it just creates a new one each time.
    all the files should be 0 bytes, unless it's a temp movie file,. they should all be deleted.

    Also,. save your model to the browser, My objects / My buildings
    that should make it easier to load

  • TangoAlphaTangoAlpha Posts: 4,584
    edited December 1969

    It's definitely weird. When I try and select a vertex (or an edge/poly) either nothing happens, or something gets selected on a completely different part of the model. It's like something is adding 100 to the x/y values of the mouse location.

    I'lll try deleting the temp files when I get home (still at work - bummer on a nice Friday afternoon!)

  • TangoAlphaTangoAlpha Posts: 4,584
    edited December 1969

    Deleting the temp files has made no difference :(

    I think maybe the next step is to save the model to My Objects and then try editing it in a fresh project file...

  • TangoAlphaTangoAlpha Posts: 4,584
    edited December 1969

    If I save the building to My Objects and load it into a fresh scene, I can edit it with no problems. I guess that means it's something barfed in the project file, so it looks like a wholesale transfer of objects to a new project is in order. (shouldn't be too hard)

    That Edit-> Split Object... boy I wish i knew about that earlier!!! ::cheese:

  • TangoAlphaTangoAlpha Posts: 4,584
    edited December 1969

    There are some issues of scale, and shininess, and bump intensity, but I think progress is being made...

    The columns are showing the seams in the first pic, and I think it's hard to spot the join, so I'm pleased with that (it's a wrapping texture done in FilterForge) :)

    test2.jpg
    720 x 480 - 43K
    test1.jpg
    720 x 480 - 33K
  • DartanbeckDartanbeck Posts: 21,583
    edited December 1969

    That is looking really nice, Tim! See? You know how this works! It can be a PITA, but it's so worth it in the end!
    I know all about that, as a stone worker. Starting with having to dig out whatever's there to begin with, installing a good, compacted new ground footing, piecing in, cutting and chiseling heavy stone, and finally lifting them all again to create the final leveling... PITA, but worth the effort! ;)

  • TangoAlphaTangoAlpha Posts: 4,584
    edited December 1969

    It's shown up that I need to add in facing stones around the arches, & I need to figure out scaling - when I added the same texture to the next bit of the model on the left, it came out completely different. I think if you size the UV bigger than the grid in the editor, the texture sheet just repeats, yes?

    I'm also going to need to add little detailing effects, like a treatment around/below the waterline, streaks and so on. But that can wait for another day! :)

  • 3DAGE3DAGE Posts: 3,311
    edited December 1969

    HI Tim :)

    the UV 's should be kept within the grid,. Texture tiling is best done using the texture map options in the shader tree. (you can also rotate texture maps)
    remember that you can make several shaders, all using the same texture map's by duplicating your shader and adjusting the parameters.
    for example, create a Mixer, of your texture map and a colour, or colour gradient, blended together with noise.
    or try a Mixer of two texture maps,. blended with fractl noise or any other procedural pattern, like Bricks, or Wood.
    In C8.5, you can also use Multilayer , and Multilayer Element to blend image layers

    It's nice to see you're using Filterforge, it should have a "seamless" option (check box) when you're creating / exporting the maps , and it shouldn't normally have any visible seams. (with the exception that Carrara's cylindrical mapping has "issues"), and that some options in FF don't work with seamless, such as shapes,. but those will warn you that they won't be seamless.

    multilayer_example.jpg
    1240 x 537 - 134K
Sign In or Register to comment.