CLD-shaped Brushstrokes in Non-Photorealistic Rendering
📝 Original Info
- Title: CLD-shaped Brushstrokes in Non-Photorealistic Rendering
- ArXiv ID: 1002.4317
- Date: 2014-09-12
- Authors: ** 논문 본문에 저자 정보가 명시되어 있지 않음. (예: 저자 미상) **
📝 Abstract
Rendering techniques based on a random grid can be improved by adapting brushstrokes to the shape of different areas of the original picture. In this paper, the concept of Coherence Length Diagram is applied to determine the adaptive brushstrokes, in order to simulate an impressionist painting. Some examples are provided to instance the proposed algorithm.💡 Deep Analysis
📄 Full Content
The behaviour of CLD diagrams (see [6], [7], [8]) approximates this requirement, as each pixel position can be associated to a local diagram which reflects both the orientation and the length of the image texture for that point. Such shapes only need to be rescaled and filled with the appropriate RGB color, as in previous algorithms.
The starting point for CLD shaping of brushstrokes is the simpler Circular Paintbrush (CPB) algorithm, described in [5]: the RGB source image of
pixels is reppresented by the three-channel brightness function
For each step k in the sequence
, a regularly spaced grid of pixel positions k G is generated as
in the random grid, a circle of fixed radius r is generated and filled with the solid color given by the color of the corresponding regularly spaced grid pixel
in the original image (displaced fill). An alternate solution is using the original color of the same position
The previously discussed procedure is iterated several times according to the final desired covering of the canvas. In fact, CPB circles generated at each iterative step can partially or completely overlap. On the other side, some pixels of the output image might not be covered by any circle; in this case, a default color value is assigned, for instance white, the color of the corresponding pixel in the original image or an intermediate value.
This section describes a new paint-brush based on CLD image processing. This image analysis method has been discussed in some previous works [7], [8]. Its interesting feature resides in the diagram it generates, which can be regarded as a synthetic way to represent the local texture of the image. Instead of considering the full RGB picture under conversion, the corresponding grayscale image is computed, as CLD is defined on a scalar brightness matrix. So, let us consider
and the subscripts 1, 2, 3 correspond to the channels R, G, B. First we compute the average brightness over the whole image
For each point
, we can define the local first order moment = ) , ( 0,
which is a function of the distance l . The local CLD, for a given threshold τ , represents the minimum summing distance l such that the corresponding first order moment differs from 0 M by less than τ :
This quantity is not defined for all directions of all point: sometimes the edge of the image is reached without entering the desired neighborhood of 0 M . The appearance of a local CLD is represented in fig. 2. To see other local behaviour of Coherence Length Diagram, Ref. [6] is quite suitable, as the more general discussion proposed in [7].
By connecting all vertices of the CLD in ascending order, a star shaped polygon [9] ) , ( y x P τ is generated, in which the point ) , ( y x belongs to the kernel. With an appropriate scale factor α , such surface can be considered as the brushstroke at the point where the CLD is computed. The above described methods can be used together to obtain an output image containing “well shaped” and “well oriented” brushstrokes, as required at the beginning of this discussion. Instead of generating a set of circles, like in the CPB algorithm, , obtained with a threshold τ and filled with a color c . The parameter α is the rescaling factor which allows to mantain the shape of te generated polygon and enlarge or shrink it. In a practical case, the average size
of the brushstroke is set, and α can be consequently computed.
Again, the actual appearance of the output image