Re: Real-time Depth-of-Field Image processing

New Message Reply Date view Thread view Subject view Author view

Javier Castellar (javier++at++sixty)
Fri, 5 Jan 1996 19:20:10 -0800


Hi,

One solution that was used in order to simulate focus in the old VGX times is
based on the accumulation buffer.

You could render multiple views which intersect his view direction on the focal
point. Each pass is stored in the accumulation buffer to be merge with the
following views. The final effect is a focused area (all the views will differ
much less on the focal point) and a blur effect in function of the distance
(before and after the focal point).

The number of passes increase the quality but you will be surprised with the
results.

If your scene is not very complex the main penalty is the scene render, since
the accumulation buffer operation is very simple.

Following please find a four views example:

Pass 1) Render view 1 (offset in +x, common focal) in the back buffer
Pass 2) Accumulation buffer copy with scaling (1/4)
Pass 3) Render view 2 (offset in -x, common focal) in the back buffer
Pass 4) Accumulation buffer copy with add and scaling (1/4)
Pass 5) Render view 3 (offset in -y, common focal) in the back buffer
Pass 6) Accumulation buffer copy with scaling (1/4)
Pass 8) Render view 4 (offset in +y, common focal) in the back buffer
Pass 9) Accumulation buffer copy with scaling (1/4)
Pass 10) Accumulation buffer return to back buffer.
Pass 11) Swapbuffers.

Keep in mind that all this operations are being done inside the graphics
pipeline, with hardware support.

Remember to use 12 or 24 accumulation size with Reality Engine. It is very
common to use the wrong acc size value and then the machine will perform the
accumulation operation IN CPU !!!!!!

You need medium pixel depth to support accumulation buffer.

If you can support 4 renders per frame with some room for accumulation
operation s you could get some good perfomance.

Hope this helps.

-Javier

-- 
*************************************************************************
* Javier Castellar Arribas     * Email:              javier++at++asd.sgi.com *                 
*                              * Vmail:            		 3-1589 *            
* Member of Technical Staff    * Phone:             NEW! (415)-933-1589 *
* Real-Time Graphics	       * Fax:                    (415)-964-8671 *     
* Advanced Systems Division    * MailStop:                       8U-800 *
************************************************************************* 
* Silicon Graphics Inc.                                                 *
* 2011 N. Shoreline Boulevard,                                          *                        
* Mountain View, California 94043-1386, USA                             *
*************************************************************************
"Violence is the last refuge of the incompetant"
						Hari Seldon

New Message Reply Date view Thread view Subject view Author view

This archive was generated by hypermail 2.0b2 on Mon Aug 10 1998 - 17:52:14 PDT

This message has been cleansed for anti-spam protection. Replace '++at++' in any mail addresses with the '@' symbol.