Include remarks from review

This commit is contained in:
Simon Giraudot 2018-03-16 09:18:09 +01:00
parent ac391e0fb2
commit 941e376ce6
4 changed files with 13 additions and 3 deletions

View File

@ -60,6 +60,8 @@ No default value.
\cgalNPBegin{callback} \anchor PSP_callback
is a mechanism to get feedback on the advancement of the algorithm while it's running and to interrupt it if needed. It is called regularly when the algorithm is running: the current advancement (between 0. and 1.) is passed as parameter. If it returns `true`, then the algorithm continues its execution normally; if it returns `false`, the algorithm is stopped.\n
The callback will be copied and therefore needs to be lightweight.\n
Note that when a callback is run on a parallelized algorithm with `CGAL::Parallel_tag`, it is called asynchronously on a separate thread and should then be thread-safe.\n
\b Type: `CGAL::cpp11::function<bool(double)>`.\n
\b Default: empty function.\n
\cgalNPEnd

View File

@ -640,7 +640,15 @@ Algorithms that support this mechanism are detailed in the [Reference Manual](@r
\subsection Point_set_processing_3Example_callbacks Example
The following example defines a callback that displays the name of the current algorithm along with the progress (as a percentage) updated every \f$1/10th\f$ of a second.
The following example defines a callback that displays the name of the current algorithm along with the progress (as a percentage) updated every \f$1/10th\f$ of a second. While the algorithm is running, the console output will typically look like this:
\code{.sh}
Computing average spacing: 100%
Grid simplification: 100%
Jet smoothing: 54%
\endcode
Thanks to the carriage return character `\r`, the lines are overwritten and the user sees the percentage increasing on each line.
\cgalExample{Point_set_processing_3/callback_example.cpp}

View File

@ -195,7 +195,7 @@ public:
1.) is passed as parameter. If it returns `true`, then the
algorithm continues its execution normally; if it returns
`false`, the algorithm is stopped and simplification stops with
no guarantee on the outut.\cgalParamEnd
no guarantee on the output.\cgalParamEnd
\cgalParamBegin{geom_traits} an instance of a geometric traits class, model of `Kernel`\cgalParamEnd
\cgalNamedParamsEnd

View File

@ -149,7 +149,7 @@ namespace CGAL {
1.) is passed as parameter. If it returns `true`, then the
algorithm continues its execution normally; if it returns
`false`, the algorithm is stopped and simplification stops with
no guarantee on the outut.\cgalParamEnd
no guarantee on the output.\cgalParamEnd
\cgalParamBegin{geom_traits} an instance of a geometric traits class, model of `Kernel`\cgalParamEnd
\cgalNamedParamsEnd