Skip to content
Home » Projection Painting in Blender

Projection Painting in Blender

Spread the love

Today we’ll be talking about projection painting in Blender. We’ll see how to paint a texture from a projection. I’ll be using the 2.90 version of Blender.

Here’s the video version of this article:

In this article we’ll be using the following image by Kevin Amrulloh from Pixabay:

image by Kevin Amrulloh from Pixabay

Here we have an interesting Rubik’s cube. What interests us is the top face of the cube. Here we have a texture projected in a perspective that we want to extract from the image so that it’s in orthographic projection, so it should look as we were facing it and not viewing from an angle. Here are the steps to follow:

Step 1 – Create a Blender File

Create a new Blender File and save it right away. You can use any file name you like. Delete the default cube, we’re not going to need it.

Step 2 – Set the Camera Background Image

As mentioned before, we’ll be using the image by Kevin Amrulloh from Pixabay. Let’s set it as the camera background image. To do this, select the camera (A) and go to camera view (Num 0). Then go to the Object Data tab (B) and check the Background Images box (C). Click Add Image (D) and select the aforementioned image (E):

Camera Background Image

Step 3 – Add a Plane

Now we’re going to add a plane and position it so that it covers the surface we want to extract the texture from. In our case it’s the top face. We will do it in camera view. So, hit Shift + A and select Mesh -> Plane (A) and then toggle the X-Ray button on (B) so that we can see through it:

Add a Plane

Step 4 – Position the Plane

Go to edit mode and select the four vertices of the plane one by one and move them so that the plane outlines the top face of the cube:

Position the Plane

Step 5 – Go to the UV Editing Workspace

With the plane still selected, go to the UV Editing workspace. In the 3D Viewport on the right go to camera view so that you can see the background image. Select all the vertices of the plane in the 3D Viewport.

Now, the top face of the cube, when viewed from the front, is a square, and so is the aspect ratio in the UV editor on the left. If it was a different shape, like a rectangle, you might want to adjust the aspect ratio so that it matches that of the original surface that you want to paint.

Go to the UV Editing Workspace

Your Panda3D Magazine

Make Awesome Games and Other 3D Apps

with Panda3D and Blender using Python.

Cool stuff, easy to follow articles.

Get the magazine here (PDF).

Step 6 – Add Another UV Map

We’ll need another UV map, so go to the UV Maps section (A) in the Object Data tab and add another UV map by hitting the plus sign (B). Rename it ‘projected’ (C). We will then draw from the ‘projected’ UV map onto the first UV map.

Add Another UV Map

Step 7 – Project from View

While still in camera view, go to the UV menu and select Project from View:

Project from View

Step 8 – Open the Cube Image

Now open the cube image in the UV editor by selecting it from the drop-down list. The UV map should overlap with the top face of the cube. If it does, you’re good to go:

Open the Cube Image

Step 9 – Create a New Image

Now we’re ready to create the image that we want, so the front view of the texture which we now see in projected view on the top face of the cube. First, let’s go to the Texture Paint workspace (A) and set the Mode under Texture Slots to Single Image (B). Then press the New button to create a new image and name it ‘extracted’ (C) – this is going to be the image of the extracted texture:

Create a New Image

Python Jumpstart Course

Learn the basics of Python, including OOP.

with lots of exercises, easy to follow

The course is available on Udemy.

Step 10 – Select the Original UV map

We want to use our original UV map for the painting, not the ‘projected’ one, so make sure to select it.

Select the Original UV map

Step 11 – Select the Clone Tool

We will be using the clone brush to paint our texture, so select it from the tool bar. It works just like the clone tool in any graphical program, so you just set one cursor on the area that you want to copy and then you use the main cursor to actually clone the texture the first cursor is moving over:

Select the Clone Tool

Step 12 – Select Source Image and Source UV Map

In order to be able to clone the texture, you first have to enable the Clone from Paint Slot box (A). Then you have to set the source image to the image of the Rubik’s cube (B) and the source UV map to the ‘projected’ UV map (C), which is the one from which we will be cloning:

Select Source Image and Source UV Map

Blender Jumpstart Course

Learn the basics of 3D modeling in Blender.

step-by-step, easy to follow, visually rich

The course is available on Udemy and on Skillshare.

Step 13 – Clone the Texture

If you now hover your mouse cursor over the source image (A), the target image will be drawn (B):

Clone the Texture

Step 14 – Finish the Projection Painting

When you finish the painting, you will have the original projected texture in front view, so as if you were facing it. But you will notice that the target image is distorted. This is because it has to little geometry. Let’s add some geometry to get rid of the distortion.

Finish the Painting

Step 15 – Add Geometry

To add geometry, we must go to edit mode (A). Now, with the plane selected, let’s subdivide it. You can do it from the Edge menu (B). Set the number of cuts to 50 (C), this should do:

Add Geometry

Step 16 – Paint Again

Now go back to texture paint mode (A) and paint again (B). This time there should be much less distortion (C). If you’re not yet fully satisfied, you can try a greater number of subdivisions, but generally we’re done.

You can now go to the Image menu and save the extracted texture.

Paint Again


Spread the love
Tags:

Leave a Reply