Krita, a beloved raster graphics editor among digital artists, has recently evolved into a prime platform for generating images with AI. This powerful feature allows anyone to create stunning images with ease, and in this article, we show you how to set up Generative AI for Krita and make the most of it.
Content
- Why Generate AI Images Using Krita
- How to Install the Generative AI for Krita Plugin
- How to Generate AI Images in Krita
- How to Inpaint a Part of an Image in Krita
Why Generate AI Images Using Krita
Krita’s AI image generation capabilities are made possible by the Generative AI for Krita plugin, which is free and open source.
One of the key advantages of using Krita for AI image generation is that the plugin runs locally on your hardware. This means you don’t have to worry about AI companies using your images to train their models, which could allow others to reproduce your unique style.
If you do enjoy digital painting but struggle to make your creations share-worthy, you can use the live painting feature to interpret your canvas in real time and turn a few basic brush strokes into a masterpiece. For example: you can create a picturesque landscape or realistic portrait right before your eyes.
But what really sets Krita apart from the likes of ComfyUI or Stable Diffusion WebUI by AUTOMATIC1111, is how seamlessly you can accomplish the same results that you can with Adobe’s Generative Fill/Expand feature – albeit without paying an expensive monthly subscription.
How to Install the Generative AI for Krita Plugin
Getting the Generative AI for Krita plugin up and running is straightforward, as long as you meet its hardware requirements. More specifically, you need to have a decent GPU with at least 6 GB of VRAM. Image generation using only your CPU is technically possible, but it’s so slow that we can’t recommend it.
If you do have a capable GPU, you can start by downloading Krita 5.2.0 or newer from the Krita website, then install it just like you would any other Windows, macOS, or Linux software.
Next, download the Generative AI plugin from its GitHub page. Once you have the plugin, you’ll need to unpack it into the pykrita folder on your system. The location of this folder varies, depending on your operating system:
- For Windows users, the folder is usually found at “C:\Users\<user>\AppData\Roaming\krita\pykrita”.
- On Linux, look for “~/.local/share/krita/pykrita”.
- macOS users should navigate to “/Users/<user>/Library/Application Support/krita/pykrita”.
After placing the plugin in the correct directory, the next step is to enable it within Krita. On Windows and Linux, go to Settings -> Configure Krita -> Python Plugin Manager. On Mac, go to Krita -> Preferences -> Python Plugin Manager. Find the plugin in the list, make sure it’s checked, then restart Krita to activate the plugin.
Once Krita is back up, you’re almost ready to start generating AI images. Open a new document (make sure to customize its dimensions based on your preferences), then navigate to Settings -> Dockers -> AI Image Generation to display the plugin’s docker, which is basically a panel that contains certain tools.
Click on Configure within the docker to initiate the server installation process. Note that this step requires at least 10 GB of free disk space on your device.
To generate images using the plugin, you need to install all core components, at least one Stable Diffusion version (I recommend version 1.5, as it requires less VRAM), and at least one Stable Diffusion checkpoint. (All three checkpoints conveniently provided by Krita are excellent, so it doesn’t matter which one you choose if you’re just starting.)
The screenshot above shows how it should look when the plugin is ready for use.
How to Generate AI Images in Krita
Now that everything’s set up, generate your first AI image in Krita. The process is simple, and it consists of just three steps.
First, choose one of the two provided style presets (Cinematic Photo or Digital Artwork). To customize the style further, click the gear icon next to the drop-down menu, select a model checkpoint (LoRA), provide your own style prompts, and customize the sample settings. If you don’t know what any of this means, I recommend you stick to the two default presets until you level up your Stable Diffusion skills further.
Next, enter positive and negative prompts into the corresponding fields. I’m going with “1girl, drinking coffee, cozy room, early morning, realistic, photo” for the positive prompt and “ugly, deformed, digital art, painting” for the negative prompt.
Finally, click the Generate button while leaving the Strength slider at 100%. (That’s the setting you want to use whenever generating new images from scratch.) The image will be generated after a short while (depending on the performance of your GPU). Keep in mind that the first image always takes the longest to generate.
Several versions will be provided by Krita. Select the one you like the most, and click Apply.
How to Inpaint a Part of an Image in Krita
But what if there’s some part of your image that you don’t like? No problem! The Krita AI generation plugin makes inpainting effortless.
Use one of the available selection tools in the left pane to select the part you want to replace, provide a new positive and a negative prompt to tell Krita what should (and should not) replace the part. Before you click Generate, lower the Strength slider. (80% is a good starting value.)
Using Krita to generate AI images is simple, and the results can be amazing. However, it’s important to use this powerful tool responsibly. Also, you should be transparent about your use of AI, especially considering that AI-generated images can be detected.
All images and screenshots by David Morelo.
David Morelo –
Staff Writer
David Morelo is a professional content writer in the technology niche, covering everything from consumer products to emerging technologies and their cross-industry application. His interest in technology started at an early age and has only grown stronger over the years.
Subscribe to our newsletter!
Our latest tutorials delivered straight to your inbox
Sign up for all newsletters.
By signing up, you agree to our Privacy Policy and European users agree to the data transfer policy. We will not share your data and you can unsubscribe at any time. Subscribe