Sign in to follow this  
nubcheese

black outline

Recommended Posts

Jroggy    172
Are you looking for just a silhouette or a silhouette, ridges and creases? If you're looking for just a silhouette outline, it is pretty straight forward. There are a few ways to do it (using the stencil buffer for instance), but here is how I do it.

Basically you use two passes. The first pass you extend the mesh using a vertex shader and the second the draw the mesh as normal. In the first pass you can draw the backfaces first (e.g. draw the opposite way you're drawing your geometry), so you get a black silhouette.

This doesn't always look that great however. You're much better off using the stencil buffer, as this ends up looking a lot better. It's a little more tricky to do though, so I won't get into it (aka I can't remember off the top of my head).

If you're wanting the silhouette/ridges/creases, there are also several ways to obtain this effect. One is doing it in image space (which is slow) another is to create a fin mesh (essentially a wire frame). There is a great article here that explains how to do this Fast Silhouettes

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this