Hi everybody!
I thought it would be a good idea to create a thread where all the tips & tricks and workflow guides could be gathered. I´ve been getting quite a few questions regarding how I do certain things so I thought I would kickstart this thread with my guide on: "How to create custom patterns for DDO" posted below. Please feel free to share your own guides & tutorials, and try to keep the format user friendly!
Replies
Most smart materials can be created using the already included materials and the Dynamask editor, but for those rare cases when you need something else, that´s what this tutorial is for!
So what is a pattern and what can it be used for? A pattern is a simple black and white texture that is used in the DDO Dynamask editor, the pattern can also contain normal map information should it need to. The patterns that are already included in DDO are located in the material browser under Patterns
There is an option to import a Grunge mask straight in to Dynamask, there is even a sizeable library of included grungemasks to chose from. This is an excellent compliment that I use very frequently.
This feature can be used instead of creating a custom pattern as a material, but I like the fact that they are so instantly accessible and easier to to tile than Grunge maps. You also have the option to include a normal map which can be very important at times
I usually make my patters 4096x4096, you never know what you will end up using them for in the future, and 4K is sufficient for most things. For this tutorial we will be doing a dirt pattern, quite grungy. These kinds of patterns are easier to make than The tiger stripes for instance, but the principal is the same. I´ve used a photo I took myself, partly because it is gratifying to make something from scratch, but mostly to avoid copyright infringement. This is the picture I will start from.
This image is in raw format which can be extremely helpful at times, for this image though I didnt do to many changes in the Photoshop
RAW importer. First I used Match Color on the blue, and desaturated it and reduced lightness, all in the match color window. After that I desaturated the image. That leaves us with this:
Since the original image isn´t 4096 pixels high I´m going to have to do some cut and paste. I also need to cover the locking mechanism and chain. Luckily the image is wider than 4096 pixels, that means I can use some parts to cover and prolong the texture without having certain details repeat. I simply cut parts of the image that I know won´t be used in the end, and paste them to cover the problem areas. My very simple technique for doing this is to always overlap the cut out patch and use eraser and clone tool to mask the edges. It helps to have brushes suitable for the task, here I used very grungy brushes. After that we are left with this:
The next step is to make sure the background is completely black, this will ensure that it will be completely transparent when used as a mask. There might be cases when you don´t want that of course, but for this texture I only want the dirt to show. I use Curves and levels to achieve this. I´m making sure that I don´t blow out the grey/white since I want the dirt to look natural. Next step is to make sure it tiles, again, you dont have to do this, but since it makes the pattern so much more versatile I always make sure my textures tile. using photoshops offset filter we are left with this:
Its starting to get there but we obviously need to fix the tiling here. What I usually do is I make a copy of the layer before tiling it, and I keep the original layer underneath. I then proceed to use the eraser tool on the top layer and remove all the tiling. Its good to work at close to 100% zoom here so that your texture comes out nice and perfect. If you zoom out to far its very easy to loose sight of details and your texture will end up with obvious clone/brush marks. Very important again to use brushes that blend well with the texture here. After this step the texture look like this:
Notice that all the tiling is gone but the texture looks quite natural and you cant really tell that it has been tiled.
We´re close to the finish line here, at this stage I usually use the offset feature in Photoshop to restore the texture to the Default position, this is only personal preference. Its also a good time to look the texture over and do the final touches. Make sure the black/white balance is correct. So after all the polish and offsetting it back to it´s original position the texture looks like this:
As you can see the the white parts are not entirely white, I did not want to push it any further since I didn´t want
to loose all the nice details. You can always do the final push in Dynamask editor once the texture has been made in to a pattern.
That being said, your patterns should not be hazy or grey when they don´t need to be.
At this point I could call this done and just import it in to DDO, but I also would like to make a normal map to really give the grime a sense of dept when using this pattern. So all I have to do is open NDO and use the photo-normal automatic converter, make sure to check tillable before converting. After tweaking the settings this is what I came up with, as I want it fairly subtle it looks quite flat, but that is what I was going for here.
From this point the process is very simple, open up DDO, click Input custom material, insert albedo and normal (optional)
and click Create Material.
To demonstrate the results I´m using a very simple project with the Scratched painted metal 07 as a base, I´m using the Muddy dirt material as the dirt, scaled down to -1 with the albedo texture intensity lowered. The layer stack in DDO looks like this:
Notice that the normals for the dirt is in a separate layer that has the pattern set as the material.
And here is how it looks in 3do, not to shabby:
This is obviously the most basic use for this custom pattern.
Lets have a look how it tiles:
The tiling is somewhat obvious but it works correctly. With this guide you can now start making your own custom patterns and I hope that I have demonstrated with this example that it is an easy and fast way workflow.
Let me know if you have any questions!
CKhol - I have seen some hilarious pictures of Teddy doing this...
As for what I'd like to see is some examples of organic/skin texturing.
+1 on skin texturing tutorial.
If you mean a zbrush model that has normal maps etc, just make sure your lowest poly has UV and create a Normal map. If you like, use poly paint to paint areas for colourID. Use multimap export to export everything you want, then export the low poly model and import the lot into DDO. Should be relatively simple, and not much different to getting your zbrush model into any other 3d package.
Since we´ve been getting a lot of questions about high-poly texturing I´m thinking a tutorial on that would also be good. Any particular things regarding highpoly texturing that you want more information on?
There's no way ATM to create a curvature map that works with DDO and smart material .Teddy did confirm the problem and that a fix is on the way. I'd still be interested in viewing what's best setting in xnormal to create good curvature map.
http://www.polycount.com/forum/showpost.php?p=2142870&postcount=32
In theory the curvature map doesn't need any raycasting and should be generated either directly from mesh or from a normal map, but also take into consideration the edges of UV islands.
I spent the last few days researching this topic and came to the conclusion that at the moment, Substance Designer is the only tool that generates a proper curvature map. I hope that in the future, Quixel will be able to generate it's own proper curvature map that takes UV island in consideration.
So here is a little tutorial on how I created the skin for the Bat Man model showed in our GDC trailer this year. This is actually a very simple setup based on one of the standard smart materials in the Quixel Suite and is the exact same method used on my troll model.
The Quixel Suite might be able to do some magic for you, but it all starts with good base maps. The better the base maps, the better the results will be with the preset materials or anything else that will use the masking features. Do them properly.
This is my usual setup, which includes an ID Map to define what material should go where, a Tangent Space Normal Map for some texture based trickery when the existing geometry isnt enough, an Ambient Occlusion Map to define what is most exposed to light, or in some cases what is in a crevice or inside a closed object, an Object Space Normal Map to define directionally specific details and a curvature map to define small details like wrinkles, scratches or harder edges. In some cases I also use a gradient map for materials that gradually fade over the mesh, this are also the things that most of the included Smart Materials is based on, if a specific map would be missing that part of the masking simply would not take place. DDO will however create a curvature map from the tangent space normal map if you do not plug in one of your own, and it does a pretty good job of doing so.
I baked all of my maps in Xnormal, something that you will be able to do directly in the Quixel Suite shortly.
For the outputs I unchecked both Bump and Ambient Occlusion since I will not need them for my purpose, which is rendering and left Albedo, Specular, Gloss, and Normal checked.
I left the calibration profile at the default setting since I dont work for any specific engine or anything that requires any modifications of my textures.
The Texel Density will directly influence the size of the detail patterns applied to your materials, this is also a number we see being confused a lot. What it actually refers to is the surface area of the texture itself. So if you were to have a UV mapped flat plane of 1x1 meters, and wanted a 2k texture the value would be 2048 pixels/m2. This number doesnt have to be super accurate, as long as it isnt a crazy low or high value. If you are uncertain, just leave it at the default value. There is room for tweaking after the project has been created.
Alright, now just hit create and after some loading you should be greeted with a grey square and some open Photoshop documents, which in this case indicates success! You will also see this nifty little window where you can add a Smart Material by clicking the button showed in the picture, which will open the Material Browser.
In this case we will use the Smart Material called Monster Skin, which is found under the Organic tab in the left side menu in the Material Browser.
And after hitting create, this is what we should see without any tweaking.
Now its time to mask the material so it is applied to the areas where we want it. To do this you click the white square next to the materials group in DDOs window, which opens the Dynamask editor. To mask via ID, simply expand the category by clicking the small arrow on the right side of the tab and click links. A window with your ID map called the Mask ID Editor will show up. To select a color simply click it in that window, to select several colors, hold CTRL while clicking on the additional colors you want. After this, click done to close the Mask ID Editor and then click done in the Dynamask Editor to apply the mask. Sometimes this glitches out on me and just leaves me with a black mask. If you experience the same issue, simply open the Dynamask Editor again by clicking the mask once more, change nothing and hit done again and the change will apply.
In this particular project this step wasnt really necessary since the entire thing uses the same material, but it also looks cleaner in the texture map so I did it anyway, I also changed the background color to black for some extra neatness.
After this step there is not really that much more to it, I just tweaked the color value of the Skin blues, Skin greens and Skin reds until I had a color I liked. This can be achieved by simply clicking the box representing the layer color in DDOs menu or in Photoshops layer menu. I also tweaked the Scale for the individual layers until I had something I liked, this number determines the size of the pattern overlay DDO uses to add detail to your texture.
The rest of the tweaks were done on the albedo map only and with custom solid color and adjustment layers, using DDOs masking features. This can be done on any Photoshop layer with a mask attached to it and is done by creating it in Photoshops layer menu, in this case I used Solid Color layers. (My PC sadly ignores the menu where you find these while taking a print screen, but its located next to the Create New Group button in Photoshops layers menu and looks like a half filled circle)
For the highlights, I created a mask using the Ambient Occlusion tab in Dynamask, for the spots I used dirt masks, something Eric has already done a tutorial on and can be found in earlier in this thread.
Sometimes people sound surprised when I tell them you can just add whatever layer you want in Photoshops own layer menu and/or just paint stuff in when texturing with DDO, but there is nothing hindering you from doing so.
Billy out.
The method I use to get good base maps might be a little bit backwards but it will work with any project and isnt really any different from what you would do when baking maps to a low-resolution model from a higher resolution version. So, how does one get around this? I simply bake the high resolution model onto itself. Does that work? Indeed it does. And here is the proof, the final textures for my UZI model.
I am assuming that most people dont bake cavity maps at all and just let DDO convert a tangent space normal map into a cavity map, something it does very well and will do automatically if no one is specified. But in this case we might not have a tangent space normal map at all or in my case, one with only a bit of symbols made in NDO and a bit of sculpted damage, neither do we need one as the only thing DDO really uses it for is to convert it into a curvature map and then use its black and white value for masking as well as putting it as a base texture on the output normal document.
What 3D application and what program you use for baking doesnt really matter but the steps may vary, of course. I create my models in Maya and bake my base maps in Xnormal.
So to get this started, I usually explode my model so no part of it is in contact with anything else, this is because parts that are close may cause errors in the bake where the cage from one object penetrates the other. I then smooth the model to the wanted level of detail and then export it as an .OBJ file. I am using Mayas Smooth Mesh Preview when modelling, so none of my parts are actually the polycount they appear to be and if exported this way, they would be the actual number of polygons instead of the smooth model I want. Depending on what kind of model I make I also export an assembled version at times to generate an ambient occlusion map, this will generate a somewhat crude map with a few errors, but I mainly use my ambient occlusion maps to tell DDO what is on the inside of the model for grease, oil and such and dont really use it for anything else, so it doesnt really matter to me.
Now comes the somewhat funky part, after exporting the mesh I start up Xnormal and import it under High definition meshes, I also import the exact same file under Low definition meshes.
I then hit the 3D Viewer button and click Launch viewer. Xnormal might complain on your mesh scale while doing so, if that is the case you can scale the model up by increasing the value under Mesh scale on both meshes, which is found in the high and low definition mesh tabs or you could do as me and just model in the correct scale to begin with and never be bothered by this .
When inside the viewer, the camera might not be focusing on the mesh, if so, just click the icon that looks like a looking glass over globe in the top left corner and it will find it for you. The viewer also uses game controls and you can move around with the WASD keys. Now, click Show cage to show the cage and then drag the Mesh global extrusion slider a little bit to the right to expand it a little bit, you dont need to extrude it much at all, just so it covers the parts. I have tried this without extruding a cage and it produces errors, even though the meshes are identical for some reason.
When you are happy with your cage, press the Save meshes button, this will open Windows standard explorer menu, then save the temporary file anywhere you like and call it whatever you like. After you click Save you will be asked if Xnormal is going to automatically switch your imported meshes for the new ones, click yes and then hit escape to exit the viewer.
Now, go into the Baking options tab and select Curvature map and/or anything else you might want generated at the same time. I usually bake an object space normal map in the same step as well and then bake a separate ambient occlusion map with the assembled version of the mesh like mentioned earlier. If you have vertex colors your model you could also bake a Color ID map with the Bake highpolys vertex colors option, I however usually do mine caveman style and just paint them in Photoshop.
We do however need to tinker a little bit with the curvature settings, since it will generate the map with a green background by default. So click the green square with 3 dots next to the map name to enter its options. In here we change the background color by clicking the colored rectangle in the bottom of the options window then changing the color to a 50% grey. You dont really need to tinker with anything else, the default settings work just fine for most stuff.
After this is done, just enter the size you want your maps generated in under Size and then select where you want them to end up under Output File and click the round Generate Maps button in the lower right corner of the interface and then just let Xnormal do its thing. And here are my two output maps, enjoy .
Billy out.
Also, just as a heads-up, in the first tutorial, you have the paragraph that starts with, "Alright, now just hit create and after some loading..." in there twice. If you're going to copy/paste the tutorial somewhere else, might want to take that one out.
This is perfect timing for me, since I'm working on a character right now who's waiting for a skin texture.
But then I tested your setting for a curvature map in xnormal and i got a regular curvature map with dark, middle and light gray. Am i missing something? Not that i does matter much as your results are obviously really good, i'm just curious.
Martin7: Yes, there is actually something funky with this one. I might have edited it and saved it over or something while working. I will have to find the original one or re-bake it. Good catch man.
//Edit: I found the original map and replaced the weird one without the lighter values.
Quixel doesn't own it and I won't give it away. Making some sort of test kit with another model might be a possibility though, if they want me to.
+1
Well, this can be arranged. Although, it would have to be a combination using both NDO and DDO to make the normal part and some standard Photoshop functions.
Just tweak the Height slider in your material property, that should fix it.
This would be ideal.
For starters, we need to find our decal, here is the one I will use (its already cut out, I just added the black background for clarity).
To add the detail to your document, open it in Photoshop and drag/drop it into one of your DDO documents, copy paste it or import it anyway you want and then place it where you want it to appear on the texture. What document you put it in is irrelevant, I used the Albedo here.
I have made a group on top of all the DDO materials where I keep all the custom stuff, this is nothing you need to do but its a nice way to keep things organized. Custom layers can be added anywhere in the document.
Next thing we need to do is to apply this decal to all the maps, this is done with a feature called Copy layer to all maps which is found in the top right menu in DDOs window. Despite the name of this feature, you will get a dialog box asking you what maps you want the layer copied to (we need to rename that thing), in my case its all of them.
After you hit Propagate, the layer will be copied to the respective maps and you will now have an identical version on all of them. This of course is not what we want since the color information will have weird results in the normal and since this is a sticker-type decal I also want it to have a uniform specular and gloss value. To get around this I created solid color layers and used a clipping mask to bind them to the decal layer, this way I have a simple value to tweak restricted to the area of the decal with a uniform color.
To create a clipping mask, place the layer you want to clip down above the layer you want it clipped to, then right click on it and select Create clipping mask or hold ALT while hovering on the line between the layers and click while the cursor symbol changes to a box with a bent arrow. Do this in both the Gloss and the Specular documents.
After this, its time to tweak the normal. In this case we will not actually keep the copied layer, rather use its silhouette to create a selection which we can use with NDO. So firstly, we will create a selection buy holding CTRL and clicking the square representing the layer in Photoshops layer menu. This will select all the pixels within the layer. After this, we start NDO and click the convert selection button.
Since this is within a DDO document, it will create a few things we wont need like the backing layer and the thingamajig on top of our newly created normal so we can just delete them along with the old decal layer.
Now we need to change the blend mode of the decal to Normal, this will make it a solid color and keep the details underneath from showing through. After that, tweak the settings to your liking and then click the little zipper icon in the bottom left corner of NDOs interface to save some well needed performance.
And thats it my friends. We now have a sticker placed on our gun, Counterstrike Global Offensive style. Enjoy.
Billy out.
You have a decal that is black background? or transparent background?
also, when you say drag and drop into DDO, where? Are you suggesting we create a new material layer on top over everything we have and import it into that?
The decal has a transparent backround, if it would have a solid background that would simply be part of the decal.
And no, you don't need to create a DDO material at all. You just put the decal inside the Photoshop document like you would with any other image or project in Photoshop.
A DDO project is simply a bunch of standard Photoshop documents, so doing things outside of DDOs interface or combining functions from the Quixel suite with standard Photoshop features works just fine.
Would like to learn how to exagerate the edge mask made from curavture map(in way like tightness option works). Plus how to blur that mask.