Harry Heath Profile picture
Nov 15, 2020 6 tweets 4 min read Read on X
@spikebor_comic Sure. So first, I render all objects that need lines using a custom shader tag. So object's with shader pass tagged "LightMode"="Outline" are rendered to a new texture that holds information I've found I need to create nice lines.
@spikebor_comic That ends up looking the like the images below: RGB, R, G and B, the channels are different images so you can see each. Each channel is used for a different aspect of rendering. R stores a float referring to an object, this is used to draw inter-object lines (outlines). ImageImageImageImage
@spikebor_comic G is used to distinguish inside lines, the zebra pattern in the previous G image show how I use grey where I don't want to draw a line. So after using an edge detection method of your preference on both R & G you're left with something like this, which is stored in a new texture. Image
@spikebor_comic This texture is then applied over the camera's color texture multiple times with a slight noise offset each time to give it that pencil-ish aesthetic, I also use the B channel here like an opacity so different areas are less or more harsh.
@spikebor_comic To get the wiggle effect, the noise offset which is used when applying outline texture is changed 6 times a seconds. And I move around the soft/harsh spots in the B channel on each object at the same rate.
@spikebor_comic Also here's the code for rendering shader passes to textures and blitting from one texture to another that I wrote for this. I don't recommend using these, but they might be nice to try and learn from. Passes: pastebin.com/LstBHRZF, Features: pastebin.com/rvju9psM

• • •

Missing some Tweet in this thread? You can try to force a refresh
 

Keep Current with Harry Heath

Harry Heath Profile picture

Stay in touch and get notified when new unrolls are available from this author!

Read all threads

This Thread may be Removed Anytime!

PDF

Twitter may remove this content at anytime! Save it as PDF for later use!

Try unrolling a thread yourself!

how to unroll video
  1. Follow @ThreadReaderApp to mention us!

  2. From a Twitter thread mention us with a keyword "unroll"
@threadreaderapp unroll

Practice here first or read more on our help page!

Did Thread Reader help you today?

Support us! We are indie developers!


This site is made by just two indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member ($3/month or $30/year) and get exclusive features!

Become Premium

Don't want to be a Premium member but still want to support us?

Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal

Or Donate anonymously using crypto!

Ethereum

0xfe58350B80634f60Fa6Dc149a72b4DFbc17D341E copy

Bitcoin

3ATGMxNzCUFzxpMCHL5sWSt4DVtS8UqXpi copy

Thank you for your support!

Follow Us!

:(