Showing posts with label tips. Show all posts
Showing posts with label tips. Show all posts

Sunday, 6 October 2013

5 simple steps to making a clean cut in Blender

In this post I will outline the method I use to making smooth cuts (or spaces) in my meshes. It's pretty basic and I'm sure you'll find examples of this elsewhere.

While I admit its not completely perfect because of the introduction of ngons and triangles, the result seems to be quite good and the amount of polygons required is quite low which is great.

The following images show what I'm talking about. The second image uses the same method to achieve the opposite shape.


The result of this tutorial


The following steps assume you have a mesh with a Subsurf modifier.

Step 1 Position where you want the cut/space in your mesh to be.
I usually use the Edge loop tool (ctrl+R) to set where I want the loops to define where the sides the thole will be. It helps reduce unwanted distortions. If your mesh happens to have edge loops already there, use those.


Step 2 Make some lines 
Draw an edge using the Knife tool (K) around the area that you want to become a hole. Ensure that when you change direction you leave a triangle between the edges as shown in the picture. Make sure the edge you are drawing is close to the existing edges you defined earlier.



Step 2 Make some space
Delete the polygons where you want the space to be. Notice how the mesh is being smoothed. This will be fixed later.



Step 3 Extrude
Select the edges around the polygons you just deleted and extrude downwards (or whatever direction you want). Again, notice how the mesh is smoothed. The next step will resolve that.



Step 4 Add lines
Creating these lines will make the corners sharp. Use the Knife tool and cut from the outer edge of the mesh up to the corresponding vertex of the triangle mentioned in step 3 making sure to cut as close to the corner as possible.



Step 5 Add sharpening line
The purpose of this line is to make the edge sharper as well as producing smoother geometry where the triangles are.



Done. I hope someone found this useful.

Friday, 27 September 2013

Normal Mapping the Time Device + basic Normal Mapping tips

Normal mapping in Blender always seemed such an awkward thing to accomplish. After reading into "mesh exploding" something finally clicked! If you want to know more about normal mapping I made a mini tutorial at the end of this article.

Now about the Time Device prop. I started modelling using the subdivision method as described in the scientist character modelling overview. This allowed me to make it look as nice as possible and not worry about re-topologising it later.
Image showing the high poly mesh before exploding

Image showing the mesh after optimisation

Once a Low poly mesh was produced, I removed the parts that can be duplicated and unwrapped it as efficiently as possible.

Next, and this is important, I made a copy of the low poly mesh and moved it far away from the original meshes. I then "exploded" both the high poly and original low poly meshes as described on some other sites. This essentially consists of taking all the parts that can be separated (anything that's a separate mesh, or can be made separate) and moving them far from their original positions.

Note: This is done for both high poly and low poly meshes making sure each corresponding high poly and low poly parts overlap.

Image showing how the high poly mesh was exploded. The low poly mesh was then matched as closely as possible.

Image shows how the high poly and low poly meshes are overlapped ready for baking


This may seem crazy but remember that mesh copy I made? The non-exploded and exploded versions share the same UVs. This means that a normal map baked on the exploded version, will work on the non-exploded version and be glitch free! The original low poly mesh is left untouched and baked map can be applied to it!

Image showing how the baked normal map on the exploded mesh applies fine on the non exploded mesh

Exploding the mesh reduces the interference between all the components and seems to produce much cleaner results.

Hope someone found this informative. Read on for more normal map related stuff!


Mini tutorial - Normal mapping Distance and Bias settings

This is something I only recently understood.

Lets make a normal map for this object (the picture shows the low poly and the high poly models):
Image shows the high poly model that will be projected into a normal map

I have identified the parts which will cause issues with the baking. In this case it happens to be the corners because the low poly deviates a lot from the high poly. 



The distance value represents an imaginary "cage" around every mesh comprising your model (or Object). This cage is both on the outside of the mesh and on the inside. The Distance value can only be made positive. Nevertheless the cage extends the same distance in the oposite direction. This ensure that no matter if the high poly extends outside or inside the low poly, the cage will still pick it up. The Bias is another imaginary cage, around your meshes, inside the first cage. The values are in Blender units (Bu).

So for each separate mesh in your model (within the same Object), you will get a separate cage with the same settings. You may need to explode your model as I explained above if this causes problems.

Anything outside the Distance (or cage) will not be baked. So when you get some solid colour artefacts in your bakes, this happens because the high poly mesh has polygons that extend beyond that distance. They intersect with the cage. You simply need to increase the Distance value until the cage is large enough that no intersections occur.

Distance, in Blender units required for the bake to work

You can see that in order to resolve the detail of the high poly mesh, we need to set the distance parameter to be as close to the maximum distance between the high poly and low poly mesh. In this case, the maximum distance between the low and high poly models occurs at the corners and is around 0.1 Bu. So that's the minimum Distance value I can use for this low poly mesh.

The Bias value functions in a similar way. Anything inside the Bias cage will be projected onto the mesh to which that cage belongs to. Anything that extends beyond the Bias will not be baked.


 The first picture has a Bias of 0 and even though the cube is still within the Distance, it doesn't get baked to the normal map. This shows why the method above works .


The second picture shows that with some tweaked values you can project the cube onto the map. It also shows the Distance and Bias cages and clarifies what the Bias value does (please ignore the fact that I forgot an edge loop resulting in the corner of the main mesh being a little screwed up).

By making the Bias 0, the cube was totally ignored. Setting the Bias to the correct value (the distance from the surface of the main mesh, to a point beyond the cube) allowed the cube to be projected on the surface.

Note: in order for this to work, you need to increase the Distance value so as to include the cube within the Distance cage (see the previous picture).

In most cases the Bias value is not needed unless you want to project some objects onto your model e.g. you could project some screw holes, rivets, shirt buttons or anything that stands out from the surface of the mesh onto the normal map without needing extra geometry on the low poly mesh. This is good for many situations where you want to add small details without increasing poly count.

In conclusion here are some basic settings to keep in mind.

Single mesh where low poly matches high poly very closely:
Distance = 0.2
Bias = 0

Multiple meshes (say, box with complex surface plus screw holes around 0.1 Bu away from the main mesh)
distance = 0.2
Bias = 0.15

Note: these values will need to be tweaked because every model has a different scale etc.

I hope this was useful to some people! 

Monday, 23 September 2013

Unwrapping woes

Quick tip for people who happen to hit the same problems I did with UV unwrapping.
This is what I used to do:
Don't do this

When you have a cylindrical object with a continuous perfectly vertical side, select the top and bottom edge loops of the perfectly vertical side (this is important) and make a seam. Make sure you make your seams are on polygons that are facing the same way. e.g. If you have a bevelled edge, select the edge loop at the end of the bevel when the next polygon is exactly (or as close as it gets to) vertical.

Next make a vertical seam, but only between those two seams you created earlier and not between other seams where the geometry is not perfectly vertical or you will end up with bent strips of UVs (see above). This ensures the middle strip is  opened and flattened out evenly and remains straight while the top and bottom parts are flattened into circles/rings (see below).
Do this!

I found this produced a much cleaner looking UV map with little extra clean up work.

One disadvantage I can see is that you end up with thin rings of UVs which may end up wasting texture space. However this can be easily countered by nesting other parts within the rings.

Sorry if this seems trivial. I'm sure most of you already know this but while modelling a prop it suddenly hit me and I realised I maybe someone else might have been in the same situation. I hope someone found it helpful.

Anyway, 'till next time.