Optimizing Post Processors

ratchet.dev

제목 없음 Crepuscular Rays, Depth of Field and Bloom Post Processors

Currently most of the Post Processors are handled loosely and internally by the vxRenderer class. This is great for keeping everything in one place, but it causes a lot of redundant information to be sent to the GPU each call. A perfect illustration of this is in this excerpt from the Edge Detection Post Processor code:

As you can see above, there’s a number of redundant calls to items which wouldn’t had changed from the last loop. A more efficient way would be to add these into get/set Properties and to manage the effects from within their own class.

I could’ve put each of these get/set Properties within the vxRenderer class, but then that would only add lines of code to an already very full *.cs file and makes debugging any post processor issues even more complicated.

I decided a cleaner…

View original post 209 more words

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s