[0:00] in today's video I'm going to show you [0:02] everything you need to know about the [0:03] imaged image tool in automatic 1111 [0:06] image to image sketch in painting in [0:09] paint sketch even in paint upload this [0:11] video has it all ready let's get started [0:14] the image to image tab is an essential [0:16] tool in your air toolbox it lets you [0:19] create a new image or new elements of an [0:21] image from an existing picture that you [0:23] provide there are so many powerful tools [0:25] here but let's start with the image [0:27] damage tab itself really you're going to [0:29] use this tool if you have an image that [0:31] you want to use as a starting point you [0:34] can use that image to pull elements of [0:35] composition and color into a brand new [0:38] image so I've got an image here that [0:41] I've generated earlier it's a portrait [0:43] of a girl on a city street I use the [0:45] sdxl base model to generate this image [0:47] but you can use any image you want an [0:50] existing photo a painting whatever so to [0:53] start we'll drop that into the image to [0:54] image box you can also send images here [0:57] from the text image tab just click on [1:00] send to image to image under your [1:02] generation at the top just like we would [1:04] for text image we can add in positive [1:07] and negative prompts if you did send [1:09] your image across from text to image the [1:11] original prompt will appear just like [1:13] you see here below the image box you'll [1:15] see all the settings we can play with [1:17] now a lot of these settings in this tab [1:19] are shared with text image so I'll only [1:21] touch on the image to image specific [1:23] ones here for a more in-depth [1:25] explanation of settings check out the [1:27] video in the description the First new [1:29] setting is resize mode use this if your [1:32] new image will have a different size or [1:34] aspect ratio than your original image [1:36] for example if your original image is [1:38] landscape and you want your new image to [1:40] be portrait the default is just resize [1:43] this will stretch or shrink your [1:45] original image to fit the new image you [1:46] create crop and resize will keep the [1:49] aspect of your original image and crop [1:51] it to fit the new canvas size resize and [1:55] fill takes the original image fits it [1:57] into the canvas and fills in the blanks [1:59] with colors from the input image I don't [2:01] see much use for this one but let me [2:03] know in the comments if I'm missing [2:04] something just resize latent upscale is [2:07] just like just resize but also upscales [2:10] the image if necessary note that this [2:12] setting is a bit tricky to get right and [2:14] there are easier ways to upscale your [2:16] images below resize modes you'll find [2:18] settings you're already familiar with [2:20] including sampling method sampling steps [2:23] your size and batch settings and the CFG [2:26] scale the most important setting here is [2:29] denoising strength stable diffusion [2:31] makes images by taking random noise and [2:33] converging it into an image based on [2:35] your prompt this setting will control [2:37] how much extra noise is added to the [2:39] picture and in turn will determine how [2:41] different the new image is from the [2:43] original lower settings won't change the [2:45] image that much and higher settings will [2:47] make bigger changes I like to use 0.7 as [2:50] a good starting point okay so now for [2:52] the fun part once you've sent over an [2:55] image you can start tweaking some [2:56] settings to refine your picture we sent [2:58] this image over from text to image so we [3:00] have all of our settings and the [3:02] original prompt now we could just start [3:04] tweaking our prompt here but bear in [3:06] mind that the entire prompt plus the [3:08] image will be used to create a new image [3:10] so if you aren't using the same model [3:13] seed and sampler from the original image [3:15] you may get some weird results so [3:18] instead we're just going to use some [3:20] simpler instructions to see how it will [3:22] affect the image so let's get rid of the [3:24] prompt and put in pink and and blue hair [3:30] and let's keep the same sampling method [3:33] and steps we'll tick restore faces and [3:37] we'll keep the default on just resize [3:39] and keep our Dimensions the same and [3:42] we'll set our denoising strength to 0.7 [3:45] so we should see a bit of a variation in [3:48] our output foreign [3:53] seven that's had a pretty big effect so [3:56] if we want something a little more [3:57] subtle let's try lowering the denoiser [4:00] strength to 0.5 [4:03] [Music] [4:07] and yeah that's a much more subtle [4:09] impact on the image [4:11] so you can keep on adding more detail [4:13] here and reworking things until you get [4:15] an image that you're looking for [4:17] when we use this method though we can [4:19] see that the prompt has had an impact on [4:22] the entire image the hair and eyes have [4:24] changed but so has the face and the [4:26] clothes let's say we just want to change [4:28] a particular part of the image and keep [4:31] the rest just as it is that's where in [4:33] paint comes in in paint is a powerful [4:35] tool that allows us to paint over the [4:37] specific parts of images that we want to [4:39] change this is especially useful when [4:41] you like the overall composition of your [4:43] image but you get one of those Cosmic [4:46] nightmare faces from the hell Dimension [4:48] just no to start you can click on the in [4:51] paint tab or just click in paint under [4:53] the image to copy the image over and all [4:56] of its settings so now we can just paint [4:58] over the particular part of the image we [5:00] want to change in this case the hair we [5:03] can use the settings in the top right of [5:05] the box to change the brush size or [5:07] clear our selection if we go wrong so [5:10] let's just paint over the hair and then [5:13] we can check our settings we've seen [5:14] some of these already so we'll keep [5:16] resize mode on default mask blur is the [5:19] amount of blurring that happens around [5:21] your painted mask lower numbers will [5:23] give you harder edges while cranking [5:25] this up will affect how many pixels [5:27] beyond your mask will be affected by [5:29] your prompt the default of four is [5:31] usually fine but feel free to play with [5:33] this if you're getting hard edges mask [5:35] mode determines what is actually changed [5:37] in the image in paint mask will change [5:39] the parts you've painted while in paint [5:42] not masked will change everything but [5:44] the parts you painted this is great if [5:46] you want to change the background or [5:48] large amounts of your image in one go [5:49] next you can choose the masked content [5:52] setting these settings tell stable [5:54] diffusion what method it should use as [5:56] its basis for generating the new image [5:58] part The Fill option will take the [6:00] impainted area blur it then generate [6:03] using that as its base the original [6:05] setting will use the original image [6:07] unaltered as its base to generate a new [6:09] image from latent noise will fill the [6:12] impainted area with new random noise [6:14] based on the seed number this can be [6:16] used if you want to result completely [6:18] different from the original Late nothing [6:20] will fill in the painted area with a [6:22] blend of the colors from the surrounding [6:24] pixels and base the generation of that [6:25] these settings will have a dramatic [6:27] effect on the output but if you're [6:29] making Minor Adjustments the original [6:31] setting will usually work great the [6:33] in-paint area setting is easily confused [6:35] with mask mode but they are different [6:37] choosing whole Picture Tells stable [6:39] diffusion to use the whole picture as [6:41] inspiration for the in-paint generation [6:43] while only masked will treat the Mast [6:46] area in isolation and not draw from the [6:48] rest of the image typically whole image [6:50] is the best setting if you want the [6:52] painted area to blend in but if you do [6:54] choose only masked you can change the [6:56] padding size right next to it which will [6:58] tell stable diffusion how many [6:59] neighboring pixels it should take into [7:01] consideration as inspiration for the new [7:03] generation and of course below that we [7:05] have the CFG scale and the noising [7:07] strength let's stick this on 5.5 and 0.6 [7:11] and see what happens [7:17] now that looks pretty good but we can do [7:19] even more within painting sketch so [7:21] let's say we want to give our model a [7:23] scarf we can send this image to in-paint [7:25] sketch just like we did before we can [7:27] paint over the image but we now have the [7:30] option of choosing colors so let's go [7:32] with red here and just paint in the area [7:35] we want to add our scarf to [7:38] and in the prompt we'll just type in red [7:40] Woolen scarf [7:42] for this you usually have to bump up the [7:45] denoising strength so let's go to 0.8 [7:47] and we can keep all of the other [7:49] settings the same as before [7:51] and let's hit generate [7:56] and yeah that looks pretty good for a [7:58] first try now you can keep iterating and [8:01] adding to this to really get the results [8:02] that you want the last in painting tool [8:05] is in paint upload now I'm not going to [8:07] go into too much detail because it's [8:09] more of an advanced topic but basically [8:11] you can create a mask in another program [8:13] like Photoshop using black for the parts [8:16] that you want to keep and white for the [8:18] parts that you want to change it's [8:19] actually a pretty powerful tool and if [8:21] you have the patience to get really [8:22] detailed it can be really useful [8:25] and finally that brings us to the sketch [8:27] tab if you're struggling to get the [8:29] image you have in your head onto the [8:31] screen using image to image or other [8:33] tools you can always flex your creative [8:35] muscles and draw it out here [8:37] simply drop in a white or black mask in [8:39] the Box provided and use the paintbrush [8:42] to sketch out your idea [8:43] use color to highlight the details you [8:46] want to show up and pair that with your [8:48] prompt and watch your sketch turn into [8:49] something incredible [8:51] there is so much more image to images [8:53] capable of and in my next video I'll be [8:55] showing you even more ways to level up [8:57] your art with the image to image tab if [8:59] you found this video helpful why not [9:01] leave a like And subscribe to see more [9:03] videos like this one thank you for [9:04] watching to the end I'll catch you later [9:07] foreign