Fetch previous passes output?

Hey everyone, I’ve got a single frag/vert shader and I have a little function in it to remove thin lines and I need to run it twice to remove a few little artifacts. I thought I could simply make it a pass and call it twice but I’m not sure how to reference the previous pass’s output? All the googling I’ve tried is mostly about problems with multi pass surface shaders (if you’ve just googled this, the answer is surface shaders don’t support multiple passes but you can put two subshaders next to each other or something).

Any help is greatly appreciated!

This says that it grabs the screen’s contents though? Wouldn’t that my background elements rather than what’s about to be output by my shader’s first pass? The documentation isn’t clear in the slightest but I gave it a go, making two passes with a grab in between and there’s literally 0 difference in the output.

Render the result of the first pass to a RenderTarget and then use that in the second pass.