Commit 162ef382 authored by Julien Michel's avatar Julien Michel

DOC: Enhancing textures and pantex examples

parent be3dc31b
......@@ -42,7 +42,8 @@
// detection.
// \relatedClasses
// \begin{itemize}
// \item \doxygen{otb}{ContrastTextureFunctor}
// \item \doxygen{otb}{ScalarImageToTexturesFilter}
// \item \doxygen{otb}{ScalarIamgeToAdvancedTexturesFilter}
// \end{itemize}
//
// The first step required to use this filter is to include its header file.
......@@ -82,7 +83,8 @@ int main(int argc, char * argv[])
// Software Guide : EndLatex
// Software Guide : BeginCodeSnippet
typedef otb::ScalarImageToPanTexTextureFilter<ImageType, ImageType> PanTexTextureFilterType;
typedef otb::ScalarImageToPanTexTextureFilter
<ImageType, ImageType> PanTexTextureFilterType;
// Software Guide : EndCodeSnippet
typedef otb::ImageFileReader<ImageType> ReaderType;
typedef otb::ImageFileWriter<ImageType> WriterType;
......@@ -109,7 +111,7 @@ int main(int argc, char * argv[])
// the neighborhood to compute the texture.
// The number of bins per axis for histogramm generation (it is the
// size of the co-occurrence matrix). Moreover, we have to specify
// the Min/Max in the input image. In the example, image Min/Max is setted
// the Min/Max in the input image. In the example, image Min/Max is set
// by the user to 0 and 255. Alternatyvely you can use the class \doxygen{itk}{MinimumMaximumImageCalculator}
// to calculate these values.
//
......
......@@ -43,37 +43,53 @@
//
// This example illustrates the use of the
// \doxygen{otb}{ScalarImageToTexturesFilter},
// which compute the standard Haralick's textural features presented in table~\ref{tab:haralickStandardFeatures}.
// which compute the standard Haralick's textural features presented in table~\ref{tab:haralickStandardFeatures},
// where $\mu_t$ and $\sigma_t$ are the mean and standard deviation of the row
// (or column, due to symmetry) sums, $ \mu = $ (weighted pixel average)
// $ = \sum_{i,j}i \cdot g(i, j) =\sum_{i,j}j \cdot g(i, j) $ due to matrix summetry, and
// $ \sigma = $ (weighted pixel variance) $ = \sum_{i,j}(i - \mu)^2 \cdot g(i, j) =\sum_{i,j}(j - \mu)^2 \cdot g(i, j) $
// due to matrix symmetry.
//
// \begin{table}
// \begin{center}
// \begin{tabular}{|c|c|}
// \hline
// & \\
// Energy & $ f_1 = \sum_{i,j}g(i, j)^2 $ \\
// & \\
// \hline
// & \\
// Entropy & $ f_2 = -\sum_{i,j}g(i, j) \log_2 g(i, j)$, or 0 if $g(i, j) = 0$ \\
// & \\
// \hline
// & \\
// Correlation & $ f_3 = \sum_{i,j}\frac{(i - \mu)(j - \mu)g(i, j)}{\sigma^2} $ \\
// & \\
// \hline
// & \\
// Difference Moment & $f_4 = \sum_{i,j}\frac{1}{1 + (i - j)^2}g(i, j) $ \\
// & \\
// \hline
// & \\
// Inertia (a.k.a. Contrast) & $ f_5 = \sum_{i,j}(i - j)^2g(i, j) $ \\
// & \\
// \hline
// & \\
// Cluster Shade & $ f_6 = \sum_{i,j}((i - \mu) + (j - \mu))^3 g(i, j) $ \\
// & \\
// \hline
// Cluster Prominence & $ f_7 = \sum_{i,j}((i - \mu) + (j - \mu))^4 g(i, j) $ \\
// & \\
// \hline
// & \\
// Haralick's Correlation & $ f_8 = \frac{\sum_{i,j}(i, j) g(i, j) -\mu_t^2}{\sigma_t^2} $ \\
// & \\
// \hline
// \end{tabular}
// \itkcaption[Haralick features available in] {\doxygen{otb}{ScalarImageToTexturesFilter}}
//
// \itkcaption[Haralick features]{Haralick features available in \doxygen{otb}{ScalarImageToTexturesFilter}}
// \end{center}
// \label{tab:haralickStandardFeatures}
// \end{table}
// where $\mu_t$ and $\sigma_t$ are the mean and standard deviation of the row
// (or column, due to symmetry) sums, $ \mu = $ (weighted pixel average)
// $ = \sum_{i,j}i \cdot g(i, j) =\sum_{i,j}j \cdot g(i, j) $ due to matrix summetry, and
// $ \sigma = $ (weighted pixel variance) $ = \sum_{i,j}(i - \mu)^2 \cdot g(i, j) =\sum_{i,j}(j - \mu)^2 \cdot g(i, j) $
// due to matrix symmetry
//
// More features are available in \doxygen{otb}{ScalarImageToAdvancedTexturesFilter}.
// \relatedClasses
......@@ -219,8 +235,8 @@ int main(int argc, char * argv[])
// \center
// \includegraphics[width=0.40\textwidth]{ADS40RoiSmall.eps}
// \includegraphics[width=0.40\textwidth]{pretty_TextureOutput.eps}
// \itkcaption[Texture Functor]{Result of applying the
// \doxygen{otb}{ContrastTextureFunctor} to an image. From left to right :
// \itkcaption[Results of applying Haralick contrast]{Result of applying the
// \doxygen{otb}{ScalarImageToTexturesFilter} to an image. From left to right :
// original image, contrast.}
// \label{fig:TEXTUREFUNCTOR}
// \end{figure}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment