1
$\begingroup$

I have created a part of city and now I want to apply some textures.

When I had a small object, my texture looks good. I am new in blender (2 weeks). I tried to add materials for every part of object, but in some places I need a custom texture and I can't paint the object if it has other materials already.

enter image description here

Link to .blend file:

$\endgroup$
  • $\begingroup$ From what I can recognize on your screenshot, you have the whole scene in one single object, or at least in one single UV map. That's quite impractical. Why not breaking up the scene in smaller objects and texture them? $\endgroup$ – metaphor_set Apr 24 at 20:03
  • $\begingroup$ It is a great idea, sounds good, but trust me, i have no Idea how to split my object in smaller pieces and create a texture for everyone. My object is real big. $\endgroup$ – Razvan Apr 24 at 20:14
  • $\begingroup$ Select a part of the object at appropriate places (loopcuts for example), then hit "P" on your keyboard and select "Selection" in the menu - boom! new object. $\endgroup$ – metaphor_set Apr 24 at 20:41
  • $\begingroup$ You could also upload your .blend file to blend-exchange and paste the given link into your question by editing it (edit link below your question). $\endgroup$ – metaphor_set Apr 24 at 20:43
  • $\begingroup$ Done, but I really want to learn how to do it by myself $\endgroup$ – Razvan Apr 24 at 20:49
3
$\begingroup$

The problem with your model is its size. Depending on the quality you expect to see on the finished model and on its purpose, you either need a huge texture or you can try to split up the model into smaller parts.

Another problem is that you are probably want to use seamless textures. To make them look good, you normally need to plan ahead and try to imagine your scene as a sort of a Lego model, where all the pieces have about the same size.

Preparation

Before you do anything, make sure that your model is in good condition by removing double vertices. Go into edit mode, hit W and select "Remove Doubles".

(I didn't clean your model entirely, there is still weird geometry in it. You can see double polygons around the curbs, that should be removed. Best you check every piece separately, remove doubles again and check for any redundant leftover geometry.)

remove doubles

Splitting the Model

To split your model into smaller pieces, select equally sized parts of your mesh, then hit P on your keyboard and select "Selection" in the popup menu.

split model in equally sized parts

Then you need to uv-unwrap those parts again, so each part has its own UV texture space.

bridge part unwrapped

The curbs and sidewalks should probably look different, so we need to separate their UVs from the road. Go into Edge Select Mode, then select the left and Shift-select the right edge of the road, then hit Ctrl+E and select "Mark Seam".

mark seams to uv-separate sidewalks from road

After hitting U and selecting "Unwrap", you are presented with a new UV layout for the new part of your model.

New UV layout with separated sidewalks

You can then straighten the UV layouts by using the method I described in my anser here.

When you are finished, your UV layout should look similar to the screenshot below. Note how the UV islands are straightened and sized equally, so they go right to the edges on the X axis.

UV islands straightened

Next, you want to open a road texture, that is seamless in the X (U) direction, then start to move the UV islands around until they match the pattern of the texture.

rearrange UV islands to match the texture pattern

Creating the Material

Go to the Properties Panel - Material tab, delete whatever material you find in the slot, create a new material and rename it appropriately.

create a new material and name it

Then open the Node Editor, select "Node Tree Type - Shader" and check "Use Nodes".

In the Node Editor view, hit Shift-A, select "Input - Texture Coordinate", then Shift-A, "Texture - Image Texture" and select your Road Texture in the Texture Selector.

create material node

If you then switch to Material View, you are presented with this result:

Result in Material View

Note how the texture pattern follows the road? This is due to our effort to straighten and realign the UV islands. This method can only used to a certain extent. If the road makes too tight curves, the texture gets distorted too much, which breaks the illusion.

If you follow through with this pattern, you should be able to achieve an almost seamles look for the whole road. You can reuse the material that was created for all similar pieces.

seamless result

You can use your own texture, the one I packed into the .blend file is just a basic road texture. You could also edit it, so the curbs and the sidewalks would look different.

Link to .blend file:

$\endgroup$
  • $\begingroup$ With your tutorial I can add same texture to all objects, but for few objects I want another texture, or I want to paint some lines $\endgroup$ – Razvan Apr 25 at 7:04
  • $\begingroup$ Same process, different texture. Come on, it's really not that hard. $\endgroup$ – metaphor_set Apr 25 at 7:28
  • $\begingroup$ I am soft dev, but this blender is really hard and I have to finish my object today. $\endgroup$ – Razvan Apr 25 at 7:56
  • $\begingroup$ For split, how did u select so easy? I see you used Vertex select and it selected all lines $\endgroup$ – Razvan Apr 25 at 8:06
  • $\begingroup$ In Vertex Select mode, press Alt+Select for the first loop, then Shift+Alt+Select for the following loops. $\endgroup$ – metaphor_set Apr 25 at 12:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.