Patate Lib
0.5

The Vitelotte module provides tools to smoothly interpolate a set of constraints on a mesh. Its primary intent is to provide an efficient solver to create diffusion curves images [6]. It includes a FEMbased diffusion solver that is able to do harmonic and biharmonic interpolation on triangular meshes with either linear or quadratic color interpolation over each face [1].
The diffusion approach offers several advantages compared to methods currently used to produce smooth arbitrary color gradients, like Gradient Meshes. Diffusion curves do not enforce a regular topology, which permits to represent similar gradients with less control points. This leads to easier to manipulate and more lightweight images. However, diffusion curves require to solve a costly equation to produce the final image.
Vitelotte represents images as arbitrary meshes with color interpolation over each face. This representation is easy to rasterize and scale independent, which makes it perfect to store the result of the diffusion. In facts, as our solver uses the finite element method, it also takes a mesh as input that encode the constraints and the structure of the final image.
This approach has several advantages:
Note that you are not constrained to diffuse colors with Vitelotte. You can also interpolate normals, displacement vectors or anything else that can be represented as a vectors.
This user manual is best read in order. The tutorial introduces some key concepts and the VGMesh page details the VGMesh class, which is central to Vitelotte. The rest of the manual does not need to be read in order, but requires a good understanding of VGMesh.
Here is a quick overview of the main elements of Vitelotte. For a more indepth introduction, see the tutorial.
At the heart of Vitelotte is the VGMesh class. It is a mesh representation that contains perface attributes used for color interpolation. It has been designed to be easily extensible and can support various color interpolation schemes. It can also represent a mesh with some color constraints to use as solver input. The DCMesh class is an extension that incorporates higherlevel diffusion curve constraints.
The FemSolver class implements a diffusion solver. It can do harmonic or biharmonic color diffusion over a VGMesh with unknown colors. It supports different kinds of elements, enabling either linear or quadratic color interpolation over the final image.
The VGMeshRenderer permits to render a VGMesh with linear or quadratic color interpolation, providing basic OpenGL routines to speedup implementation.
MVGReader and MVGWriter work together to save and load a VGMesh in the MVG file format. It allows users to save meshes at any processing step (i.e., before or after a solve), which can be useful for debugging purposes.
There are several header to include Vitelotte:
There is currently no easy way to manipulate the topology of a VGMesh, except the lowlevel mesh manipulation methods that do not preserve constraints. Don't worry, it is planned for the next release which should come very soon.
Vitelotte also comes with a small set of tools that offer a highlevel interface to the library:
The mvg toolkit (mvgtk
). Permits to do high level operations on DCMesh. Example:
See mvgtk's documentation for a complete explanation of this command.