/*
 This Source Code Form is subject to the terms of the Mozilla Public
 License, v. 2.0. If a copy of the MPL was not distributed with this
 file, You can obtain one at http://mozilla.org/MPL/2.0/.
*/


namespace Vitelotte {

/*!
  \page vitelotte_user_manual_dc_mesh_page DCMesh

  The class DCMesh is an extension of VGMesh. It permits to manipulate nodes using diffusion curves defined on the mesh instead of directly manipulating nodes. It is the class used behind the scene in the [mvg_editor](@ref vitelotte_example_mvg_editor_page) example.

  DCMesh curves are simply paths of edges on the mesh. You can create a curve with DCMesh::addCurve and add an halfedge to it with DCMesh::addHalfedgeToCurve. Halfedges must be added in order.

  Obviously, each curve has a set of extra information to define how it behaves. First, you can use DCMesh::setFlags to set flags of a curve to a combination of DCMesh::VALUE_TEAR and DCMesh::GRADIENT_TEAR to mark the curve as respectively value discontinuous or/and gradient discontinuous (if the EDGE_GRADIENT attribute is enabled). Then you can edit the [piecewise linear functions](@ref PiecewiseLinearFunction) that constrain the value and the gradient on each side of a curve. If a PiecewiseLinearFunction object contains no sample, it means the values or gradients along the associated curve is unconstrained, otherwise it is constrained.

  Once you set the curves as you wish, you should call DCMesh::setNodesFromCurves. It will clear all nodes on the mesh and set nodes on halfedges belonging to a curve to reflect the curve constraints. You must call VGMesh::finalize after to get a valid input for the solver.

  You can also add point constraints. They can have a value constraint but also a gradient constraint if you use FVElements.

 */

}
