Bake Procedural Materials to Tileable Texture Maps (Blender & Gimp Tutorial)

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
in this tutorial I will show you how to texture bake a procedural material to tileable seamless texture Maps like a texture map that you would download from an online texture website and to do this we're going to be using blender to texture bake the material to image textures and then we're going to be using to make the textures tileable and if you're unfamiliar with it is a free open source image editing program and I'll have a link in the description to gimp's official website if you'd like to download it if you don't already have it and if you'd like to learn the basics of texture baking in blender then you can definitely check out my texture baking for beginners tutorial with the link in the description and you can also check out my texture baking tutorial playlist to learn more about texture baking so as an example I'm going to be using my procedural dirt material which I created a little while back and if you'd like to use the same exact procedural material that I'm using then you can check out the procedural dirt material with the link in the description or you can also help support this Channel and purchase the procedural dirt project files on my gumroad store and you can also purchase the tileable dirt texture maps on my gum red store links in the description I'm also selling my procedural materials in procedural material packs so if you'd like to check out my procedural material packs link will be in the description and that's also a great way to help support this channel you can also learn how to create any of my procedural materials with my blender procedural material tutorial playlist here on YouTube now this method of tiling won't work well for materials which have a consistent pattern for instance something like brick or tiles but this method works really well for any type of organic materials so things like dirt or rock or stone or metals or plaster or really any organic material so the first thing I'm going to do is press shift a I'm going to go here to mesh and I'm going to add a plane and then I'm going to select this object here and just move it out of the way and I just want to select the plane right here and then I'm in the shading workspace so I have the 3D viewport over here and the Shader editor right here so I'm going to click on the drop down and I want to add the dirt material to the plane so whichever material you're baking to texture Maps you just need to add that material to the plane and then I don't need any of the other objects so I can press Ctrl I in the 3D viewport that's going to invert the selection so now all the other objects are selected and I can press the X key and click on delete so I'm now going to hold down the Z button and move my mouse up into the rendered mode so that I can preview the texture and it is a little bit hard to see the texture in this lighting so if you wanted to you could press shift a and you could add a light object or what you can also do over here in the world is just turn up the world strength so I've added in an hdri in the world and I'm just going to turn the strength up to like 4 so that it is brighter so it's really easy to see the texture now this plane here is what we're going to be texture baking so if you want to scale the size of the texture then now's the time to do that so in the Shader editor in this procedural setup I've added all these textures and this mapping node is being plugged up to all the textures and I'm also using the object coordinates here with the texture coordinate and that's very standard when creating procedural materials so on the mapping node you can just click on the scale value and then you can drag down and then you can drag back and forth and that's going to change all the values at the same time and so you can scale the texture bigger or smaller or of course you can just individually go to the scale values of the procedural textures and make them bigger or smaller but I like how this is so the next thing that I need to do is create an image to bake to now as I mentioned earlier if you'd like to learn the basics of texture baking and blender then you can definitely check out my texture baking for beginners tutorial but I will really quick just go over the basics of texture baking so in the Shader editor I'm going to press shift a let's go to the search and I'm going to search for an image texture and let's put the image texture down here and then we want to create a new image that we can bake to so I'm going to click on the new button and on the name here I can just call this dirt now on the width and height this is going to be the resolution of the texture and on default it is a 1K texture I want this to be a 4K texture so I'm going to click and then drag down and then let go to change both values at the same time and I'm going to change this to 4096 by 4096 and that is the standard resolution for a 4K texture and then on all the other settings we can just leave it at the default and I will click on OK so this is the image that we're going to bake to now before we bake this we need to make sure that the UV and wrapping is nicely placed on the image so what I'm going to do is Click right up here to go to the UV editing workspace and the default plane and blender when you add a plane it is already UV unwrapped so you shouldn't have to UV unwrap it but if you need to you can just press the a key to select all the vertices and you can press U and then you can just click on unwrap and we just want to UV unwrap it to the dirt image and this uvn wrap is exactly what we want because we want the UV Island to be filling the entire texture so we can now go back to the shading workspace and for this material I'm going to be baking the base color and the roughness and the normal but if you have other Maps like metallic Maps or emission Maps then you can check out my text extra baking tutorial playlist where I show you how to bake other Maps so to bake this we're going to click right here on the render properties and on the render engine you need to make sure this is Cycles EV doesn't support baking if you are using EV that's totally fine you can change it to Cycles then you can bake the material and then afterwards you can change it back to EV but make sure it's set to cycles for now while we're doing the baking and then right here on the sampling if we turn the samples down then it will bake faster but it won't affect the quality of the bake so I'm just going to turn the render samples here to one and then I can close the sampling tab so we can now open up the bake tab right here and I'm just going to click and drag and bring it up here so it's on the top now on the bake type here I want to start by baking the color map so I'm going to click on this bake type and I'm going to change this to diffuse and diffuse is the same as color and then we don't want it to bake the lighting data we just want it to bake the color so here on the contributions I'm going to turn off the direct and indirect but just leave the color on so then to bake the image you need to make sure that the object is still selected and then you need to make sure that this image texture is selected in the material and that way blender will know to bake to this image and then you can click on the bake button and then to see the image when it's finished baking what I'm going to do is Click right up here in the corner when the Crosshair appears and I can click and drag down to split the window and then if you click right up here to change the editor type we can change this to the image editor and then in the image editor you can click on the drop down and just click on the dirt so we now need to save this to an image on our computer so let's click here on image and then we can click on save as and I'm just going to rename this to dirt color and I'll just save it as a PNG file and I will click on save as so we now just need to bake the other two maps so right here on the bake type we can change this to the roughness and then we can bake to the same image texture and just save it as a different map now what's really important with the other Maps is that the color space here we want to set this to non-color we have the color space for the color map set to the Sr RGB and that is because the color map is contributing to the base color of the material but any of the other Maps which aren't contributing to the base color of the material like the roughness and the normal those Maps need to be set to non-color before you bake them so they bake correctly and then here on the bake type this is set to roughness so then again make sure the object is selected and make sure the image is selected and you can click on the bake button again and here is the roughness map so to save the image you can click here on image and then click on save as and then this one I'm going to rename two dirtroughness dot PNG and I'll click on save as image so now we can do the normal map so on the bake type right here I can just change this to the normal and then again the color space needs to be set to non-color so then make sure the object is selected make sure this image is selected and you can click on bake again and then just like the other maps you can click up here on image and click on save as and then this one I will save to dirtnormal.png and click on save as so now that we've baked the images I want to delete this material and add a new material and then add up all the images so just in case I need to go back and rebake this or use the procedural dirt material again I'm going to click on this button right here the shield icon and that's going to add a fake user and this way even if we delete the material from the object it's still going to keep this data in the blender file just in case I need to go back to it so I can now click on the x button to get rid of it and then let's click on new here to add a new material to the plane and then to add in all the images I'm going to be using the node Wrangler add-on so if you don't have the node Wrangler enabled you can click on edit and you can go to the preferences and then over there on the add-ons tab you can search for node Wrangler and just check mark the node Wrangler add-on so with the node Wrangler add-on enabled you can click on the principled Shader and then you can press Ctrl shift T and Ctrl shift T will bring up blender's file browser and then you can just select all the images so I'm going to hold down the control key and select the dirt roughness normal and color color and then right down here I can click on printable texture setup and this is automatically going to set up all the textures for us so now here in the 3D viewport you can see the dirt material has been baked to these texture Maps however these maps are not tileable so if I click right up here to change the editor type I'm going to change this to the UV editor and then I will press the Tab Key to go into edit mode of the object and if I scale the UV editing I can then press tab to go back to object mode and if you look right here you can see a visible seam so I'm going to press Ctrl spacebar with my mouse in the 3D viewport and you can clearly see a seam right there so we're now going to make the images tileable in so that there isn't any seam alright so here I am in and I'm just going to drag and drop in the images so I'm first going to do the normal map just because the normal map has the most contrast and so it's easy to see what's happening so now to make this tileable we can click right here on filters and we can go down here to map and then we can click on the tile seamless option and so what this is going to do is it's going to take the image data from one side it's going to bring it over to the other side and then blend it together now if you change this opacity here you can see it taking effect now you don't want the opacity to be in the middle because if it's in the middle it's not going to take its full effect and so you still will be able to see a little bit of the tiling so I'm going to turn the opacity all the way to 1 and that way there won't be any tiling so I can just click on the OK button and then I can save this image so I'm just going to click on file and then you could click on export as and you could export this as a different image but I'm just going to override the dirt normal because I know this will work fine so I will override the dirt normal and then wait for that to save so I'm now going to do the exact same thing for the other image textures so right here I can click on the x button to get rid of this project and I can discard the changes and then I can just drag and drop from my file browser the color map and then again click on filter and you can go down here to map and then you can click on tile seamless and make sure that the opacity is 100 click on OK and then you can click on file and we can override dirt color and I'll do the same thing for the roughness map so I'll get rid of this image I'll drop in the roughness map and then I can go to filters and map and tile seamless make sure the opacity is 100 and click on OK and then I can click on file and override dirt roughness so then you can jump back into blender and if you saved the images from to different images then you're going to need to re-add them here in the Shader editor but I just overrided the materials so I just need to refresh the viewport now so that it will use the updated textures so what I'm just going to do is press Ctrl s to save the blender file and then I will close blender and open it back up again and I've opened back up the blender file so the material preview has reloaded the textures and you can see that the seam was right there but it is no longer there so there we have it now the texture is completely seamless and tileable if I control shift and select the base color or or the roughness and the normal you can see here is the image data but you can see it's completely seamless and if I press the Tab Key to go into edit mode I can press the a key to select the UV map and I can scale it up to make it bigger or smaller and I can control shift and select the principled Shader to preview it and you can see that there is no seams so that is it that is how you turn a procedural material into tileable seamless texture maps and if you'd like to purchase my blender procedural materials then definitely check out my blender procedural material packs with the link in the description and you can also learn how to create any of my procedural materials with my blender procedural material tutorial playlist here on YouTube and if you'd like to learn more about texture baking and blender then definitely check out my texture baking tutorial playlist where I have many more texture baking tutorials but I hope you found this helpful and thank you for watching
Info
Channel: Ryan King Art
Views: 18,641
Rating: undefined out of 5
Keywords: Ryan King Art, Blender Tutorial, Blender, Ryan King, Tutorial, texture baking, tileable maps, seamless maps, bake to texture maps, procedural material, texture bake procedural material, texture bake to maps
Id: VAjGtE678o0
Channel Id: undefined
Length: 12min 51sec (771 seconds)
Published: Wed Jan 04 2023
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.