- Home /
How to apply image effect on a specific area of the screen
I am now trying to make a fake volumetric lighting post effect based on radial blur. However since the light source may not locate at the very center of the screen, I need to blur certain quads on the screen during the post effect. So my question is how to sample part of the screen pixels into a RenderTexture and later blend the texture with the original one? Any suggestions would be greatly appreciated!
Do you want the specific squared area to have image effects? Or just the objects within that area
Specific squared areas in screen space. Thank you for your reply and I feel eager to extend our discussion.
Just to mention ... I have figured out how to apply radial blur to a specific area of the screen. But however the solution is not general, which means it could NOT be utilized into other image effects. Hence could anybody provide some ideas about this post? Looking forward to any update.
Answer by Gmotagi · Nov 20, 2016 at 12:45 PM
Dont know if you have Shader Forge or not and this may be totally off from what you want to do. But the technique used in this tutorial is bluring on a quad. May be this will help you, if only giving an idea on a way to do it. https://www.youtube.com/watch?v=XKbSu5PC8VA
Thank you for your reply and your share. The technique introduced in the video is to set a transparent and blurred material to a mesh renderer, which is also a creative solution. $$anonymous$$y problem COULD UNDENIABLY BE solved by setting billboards with the materials and shaders set in the video. However I am now currently working on a paper published in 2011 about post effects with depth texture where this post is introduced, which means my problem could also be solved using only Image Effects. Hence I am interested in applying image effects to only part of the screen. The link to the paper is as follows: http://beta.unity3d.com/talks/Siggraph2011_SpecialEffectsWithDepth_WithNotes.pdf Anyway, I really appreciate your post, and feel eager to communicate more about rendering and shader! GL & HF.
BTW I am not a native English speaker and thus what I have written may look awkward. Thank you for your patience and understanding.
Finally, this comes to be the correct solution! However BE SURE to make the quads locate at the correction positions, otherwise it is no longer a fake image effect but a mirror or something.
Your answer
Follow this Question
Related Questions
How can I make the most efficient SDF Shader in unity 1 Answer
Image Effect - Screen coordinates 1 Answer
"Motion vectors" and "depth with normals" from camera's target texture 1 Answer
Screen shaders that alter geometry at runtime or through camera 1 Answer
In FastBloom(Bloom Optimized) shader, what's the difference between Standard and Sgx blur type? 0 Answers