REAL-TIME NON-PHOTOREALISTIC RENDERING

             Softwarepraktikum Computergraphik       Saoud Asla: Ang. Informatik Student                Betreuerin: Dr. Susanne Krmker

 

 

What is this about ?

 

Algorithm

 

Implemention

 

Demo

 

Overview

 

Literature

 

Contact

 

 

–

 

 

  What this is about ?

 

 

The project is an implementation in C++ using OpenGL in Qt application of a nonphotorealistic rendering technique that automatically and in real-time performance delivers a stylized abstraction of a photograph.

 

 

 

 

 

 

  Algorithm

 

 

Looking at the image as a height field of pixel intensities, the task then is to display “significant” height discontinuities and  remove all “insignificant” height discontinuities. Which result in a line drawing and smoothed image. The combination of both result in a cartoon like image.  For both subtasks an adaptive version of the Difference of Gaussian for line extraction and an adaptive version of the bilateral flter for smoothing are employed. Both filters are guided by the Edge Tangent flow. The edge tangent flow is constructed first by computing the orthogonal to the gradient vector by the Sobel operator. Subsequently, the resulting vector field with two main weighting functions is iteratively smoothed. The first one ensures that tangents where the gradients have a larger magnitude weigh more, while the second ensures that tangents with similar directions have more weight:

 

 

 

 

 

 

 

 

The Flow-Based Difference of Gaussian applies one dimensional Difference of Gaussian in the gradient direction in the first pass:

 

 

 

 

 

 

The filter responses along the edge flow are weighted in the second pass with Gaussian function:

 

 

 

   

                                              (a) Original

 

 

 

 

-                            

 (c) Second iteration: Applying the filter to superimposing (b) upon the original image (a)

-           

 

 

-         

                 (b) First iteration: Thresholding of

 

 

 

 

 

 The Flow-Based Bilateral Filter applies linear bilateral filter along the edge directions in the first pass:

 

 

 

and applies linear bilateral filter along the gradient directions in the second pass:

 

 

 

 

(a)    Orginal

 

 

(b)    10 Iterations of Flow-Based Bilateral Filter

 

The smoothed image is stylized by performing a uniform-sized-bin luminance quantization:

 

 

 

 

 

 

 

(a)    Result

 

 

(b)    Result with luminance quantization

 

 

 

  Implemention

 

 

In order to allow parallel processing (to exploit all GPUs computational units), the filters are implemented in fragment programs using the OpenGL Shading Language (GLSL). Qt GUI is used for the realization of graphical user interfaces.

 

 

 

Performance:

 

On an intel core i3 7100u 2.4ghz with Windows 10 and an intel hd graphics 620, typical performance for a 640 ื 360 resolution and default parameters is 30 Millisecond.

 

 

 

 

 

 

  Demo

 

Here is a typical procedure when working with the program to be tried.

 

 

 

 

 

 

 

 

 

  Overview

    

 

In terms of abstraction and stylization the adaptation of both filter to a curved kernel, which follows the local “edge flow.” enhances the spatial coherence of lines and also suppresses noise by the FDoG. and helps convey clear and enhanced shape boundaries by the FBL. In terms of execution time the curved kernel of the FDoG and FBL filters provide linear time complexity with respect to the kernel radius.

 

 

 

 

 

 

 

 

 

Literature

 

[1] Kang H., Lee S., Chui C. K.: Flow-based image abstraction. IEEE Transactions on Visualization and Computer Graphics 15, 1 (2009), 62–76.

[2] H. Winnemller, S. Olsen, and B. Gooch, “Real-Time Video Abstraction,” Proc. ACM SIGGRAPH ’06, pp. 1221-1226, 2006.

 

 

 

 

 

Contact: asla@stud.uni-heidelberg.de

 

–––