add more river examples
This commit is contained in:
parent
6ba9fe9566
commit
250095cdbd
22
IV/Makefile
22
IV/Makefile
@ -23,9 +23,9 @@ FIGURES = \
|
|||||||
selfcrossing-1-after
|
selfcrossing-1-after
|
||||||
|
|
||||||
RIVERS = \
|
RIVERS = \
|
||||||
salvis-gdr10 \
|
salvis-25k \
|
||||||
salvis-gdr50 \
|
salvis-50k \
|
||||||
salvis-gdr250
|
salvis-250k
|
||||||
|
|
||||||
#################################
|
#################################
|
||||||
# The thesis, publishable version
|
# The thesis, publishable version
|
||||||
@ -121,15 +121,17 @@ selfcrossing-1-after_1SELECT = wm_debug where name='selfcrossing-1' AND stage='d
|
|||||||
selfcrossing-1-after_2SELECT = wm_debug where name='selfcrossing-1' AND stage='bbends' AND gen=1
|
selfcrossing-1-after_2SELECT = wm_debug where name='selfcrossing-1' AND stage='bbends' AND gen=1
|
||||||
selfcrossing-1-after_2LINESTYLE = invisible
|
selfcrossing-1-after_2LINESTYLE = invisible
|
||||||
|
|
||||||
salvis-gdr10_1SELECT = wm_rivers where name='Šalčia' OR name='Visinčia'
|
salvis-25k_1SELECT = wm_rivers where name='Šalčia' OR name='Visinčia'
|
||||||
salvis-gdr10_WMCLIP = salcia-visincia:GDR10
|
salvis-25k_WMCLIP = salcia-visincia:25k
|
||||||
|
salvis-25k_WIDTHDIV = 1
|
||||||
|
|
||||||
salvis-gdr50_1SELECT = wm_rivers where name='Šalčia' OR name='Visinčia'
|
salvis-50k_WIDTHDIV = 2
|
||||||
salvis-gdr50_WMCLIP = salcia-visincia:GDR50
|
salvis-50k_1SELECT = wm_rivers where name='Šalčia' OR name='Visinčia'
|
||||||
|
salvis-50k_WMCLIP = salcia-visincia:50k
|
||||||
salvis-gdr250_1SELECT = wm_rivers where name='Šalčia' OR name='Visinčia'
|
|
||||||
salvis-gdr250_WMCLIP = salcia-visincia:GDR250
|
|
||||||
|
|
||||||
|
salvis-250k_WIDTHDIV = 10
|
||||||
|
salvis-250k_1SELECT = wm_rivers where name='Šalčia' OR name='Visinčia'
|
||||||
|
salvis-250k_WMCLIP = salcia-visincia:250k
|
||||||
|
|
||||||
.faux_test-rivers: tests-rivers.sql wm.sql .faux_db
|
.faux_test-rivers: tests-rivers.sql wm.sql .faux_db
|
||||||
./db -f $<
|
./db -f $<
|
||||||
|
@ -17,9 +17,10 @@ PSQL_CREDS = "host=127.0.0.1 dbname=osm user=osm password=osm"
|
|||||||
TEXTWIDTH_CM = 12.12364
|
TEXTWIDTH_CM = 12.12364
|
||||||
|
|
||||||
SCALES = {
|
SCALES = {
|
||||||
"GDR10": 10000,
|
"10k": 10000,
|
||||||
"GDR50": 50000,
|
"25k": 25000,
|
||||||
"GDR250": 250000,
|
"50k": 50000,
|
||||||
|
"250k": 250000,
|
||||||
}
|
}
|
||||||
|
|
||||||
def inch(cm):
|
def inch(cm):
|
||||||
@ -52,7 +53,7 @@ def parse_args():
|
|||||||
|
|
||||||
parser.add_argument('--wmclip',
|
parser.add_argument('--wmclip',
|
||||||
type=wm_clip,
|
type=wm_clip,
|
||||||
help="Clip for scale. E.g. salcia-visincia:GDR10",
|
help="Clip for scale. E.g. salcia-visincia:10k",
|
||||||
)
|
)
|
||||||
parser.add_argument('--widthdiv',
|
parser.add_argument('--widthdiv',
|
||||||
default=1, type=float, help='Width divisor')
|
default=1, type=float, help='Width divisor')
|
||||||
|
@ -85,7 +85,7 @@ Current open-source line generalization solutions have their roots in
|
|||||||
NOTICE: this value should be copied to layer2img.py:TEXTWIDTH, so dimensions
|
NOTICE: this value should be copied to layer2img.py:TEXTWIDTH, so dimensions
|
||||||
of inline images are reasonable.
|
of inline images are reasonable.
|
||||||
|
|
||||||
textwidth in cm: {\printinunitsof{cm}\prntlen{\textwidth}}
|
Textwidth in cm: {\printinunitsof{cm}\prntlen{\textwidth}}
|
||||||
\fi
|
\fi
|
||||||
|
|
||||||
When creating small-scale maps, often the detail of the data source is greater
|
When creating small-scale maps, often the detail of the data source is greater
|
||||||
@ -129,7 +129,8 @@ different trade-offs.
|
|||||||
\label{sec:literature-review}
|
\label{sec:literature-review}
|
||||||
|
|
||||||
A number of cartographic line generalization algorithms have been researched.
|
A number of cartographic line generalization algorithms have been researched.
|
||||||
The "classical" ones are {\DP} and {\VW}.
|
The "classical" ones are {\DP} and {\VW} in combination with Chaikin's. There
|
||||||
|
are also modern ones.
|
||||||
|
|
||||||
\subsection{Available algorithms}
|
\subsection{Available algorithms}
|
||||||
|
|
||||||
@ -150,13 +151,43 @@ Both algorithms are part of PostGIS, a free-software GIS suite:
|
|||||||
\href{https://postgis.net/docs/ST_SimplifyVW.html}{PostGIS SimplifyVW}.
|
\href{https://postgis.net/docs/ST_SimplifyVW.html}{PostGIS SimplifyVW}.
|
||||||
\end{itemize}
|
\end{itemize}
|
||||||
|
|
||||||
Examples of <TBD Chaikin and others>
|
|
||||||
|
|
||||||
It may be worthwhile to post-process those through a widely available Chaikin's
|
It may be worthwhile to post-process those through a widely available Chaikin's
|
||||||
line smoothing algorithm \cite{chaikin1974algorithm} via
|
line smoothing algorithm \cite{chaikin1974algorithm} via
|
||||||
\href{https://postgis.net/docs/ST_ChaikinSmoothing.html}{PostGIS
|
\href{https://postgis.net/docs/ST_ChaikinSmoothing.html}{PostGIS
|
||||||
ChaikinSmoothing}.
|
ChaikinSmoothing}.
|
||||||
|
|
||||||
|
To use in generalization examples, we will use two rivers: Žeimena and Šalčia
|
||||||
|
(they flow into one). Figure~\onpage{fig:salvis-25} illustrates the original
|
||||||
|
two rivers without any processing (yet).
|
||||||
|
|
||||||
|
\begin{figure}[h]
|
||||||
|
\centering
|
||||||
|
\includegraphics[width=\textwidth]{salvis-25k}
|
||||||
|
\caption{Example rivers for visual tests (1:25000)}
|
||||||
|
\label{fig:salvis-25}
|
||||||
|
\end{figure}
|
||||||
|
|
||||||
|
Same rivers, unprocessed, but with higher density (scales 1:50000 and 1:250000)
|
||||||
|
are depicted in figure~\onpage{fig:salvis-50-250}. Some river features are so
|
||||||
|
compact that a reasonably thin line depicting them is overlapping with itself.
|
||||||
|
As can be seen in the article example, generalization is worthy.
|
||||||
|
|
||||||
|
\begin{figure}[h]
|
||||||
|
\centering
|
||||||
|
\begin{subfigure}[b]{.49\textwidth}
|
||||||
|
\includegraphics[width=\textwidth]{salvis-50k}
|
||||||
|
\caption{Example scaled 1:50000}
|
||||||
|
\end{subfigure}
|
||||||
|
\hfill
|
||||||
|
\begin{subfigure}[b]{.49\textwidth}
|
||||||
|
\centering
|
||||||
|
\includegraphics[width=.2\textwidth]{salvis-250k}
|
||||||
|
\caption{Example scaled 1:250000}
|
||||||
|
\end{subfigure}
|
||||||
|
\caption{Down-scaled original river (1:50000 and 1:250000)}
|
||||||
|
\label{fig:salvis-50-250}
|
||||||
|
\end{figure}
|
||||||
|
|
||||||
|
|
||||||
\subsubsection{Modern approaches}
|
\subsubsection{Modern approaches}
|
||||||
|
|
||||||
@ -359,12 +390,12 @@ when a single vertex is moved outwards the end of the bend.
|
|||||||
|
|
||||||
\begin{figure}[h]
|
\begin{figure}[h]
|
||||||
\centering
|
\centering
|
||||||
\begin{subfigure}[b]{.45\textwidth}
|
\begin{subfigure}[b]{.49\textwidth}
|
||||||
\includegraphics[width=\textwidth]{fig5-gentle-inflection-before}
|
\includegraphics[width=\textwidth]{fig5-gentle-inflection-before}
|
||||||
\caption{Before applying the inflection rule}
|
\caption{Before applying the inflection rule}
|
||||||
\end{subfigure}
|
\end{subfigure}
|
||||||
\hfill
|
\hfill
|
||||||
\begin{subfigure}[b]{.45\textwidth}
|
\begin{subfigure}[b]{.49\textwidth}
|
||||||
\includegraphics[width=\textwidth]{fig5-gentle-inflection-after}
|
\includegraphics[width=\textwidth]{fig5-gentle-inflection-after}
|
||||||
\caption{After applying the inflection rule}
|
\caption{After applying the inflection rule}
|
||||||
\end{subfigure}
|
\end{subfigure}
|
||||||
@ -386,12 +417,12 @@ vertices to the next bend instead of one.
|
|||||||
|
|
||||||
\begin{figure}[h]
|
\begin{figure}[h]
|
||||||
\centering
|
\centering
|
||||||
\begin{subfigure}[b]{.45\textwidth}
|
\begin{subfigure}[b]{.49\textwidth}
|
||||||
\includegraphics[width=\textwidth]{inflection-1-gentle-inflection-before}
|
\includegraphics[width=\textwidth]{inflection-1-gentle-inflection-before}
|
||||||
\caption{Before applying the inflection rule}
|
\caption{Before applying the inflection rule}
|
||||||
\end{subfigure}
|
\end{subfigure}
|
||||||
\hfill
|
\hfill
|
||||||
\begin{subfigure}[b]{.45\textwidth}
|
\begin{subfigure}[b]{.49\textwidth}
|
||||||
\includegraphics[width=\textwidth]{inflection-1-gentle-inflection-after}
|
\includegraphics[width=\textwidth]{inflection-1-gentle-inflection-after}
|
||||||
\caption{After applying the inflection rule}
|
\caption{After applying the inflection rule}
|
||||||
\end{subfigure}
|
\end{subfigure}
|
||||||
@ -427,12 +458,12 @@ following the rules of the article.
|
|||||||
|
|
||||||
\begin{figure}[h]
|
\begin{figure}[h]
|
||||||
\centering
|
\centering
|
||||||
\begin{subfigure}[b]{.45\textwidth}
|
\begin{subfigure}[b]{.49\textwidth}
|
||||||
\includegraphics[width=\textwidth]{fig6-selfcrossing-before}
|
\includegraphics[width=\textwidth]{fig6-selfcrossing-before}
|
||||||
\caption{Bend's baseline (dotted) is crossing a neighboring bend}
|
\caption{Bend's baseline (dotted) is crossing a neighboring bend}
|
||||||
\end{subfigure}
|
\end{subfigure}
|
||||||
\hfill
|
\hfill
|
||||||
\begin{subfigure}[b]{.45\textwidth}
|
\begin{subfigure}[b]{.49\textwidth}
|
||||||
\includegraphics[width=\textwidth]{fig6-selfcrossing-after}
|
\includegraphics[width=\textwidth]{fig6-selfcrossing-after}
|
||||||
\caption{Self-crossing removed following the algorithm}
|
\caption{Self-crossing removed following the algorithm}
|
||||||
\end{subfigure}
|
\end{subfigure}
|
||||||
@ -447,12 +478,12 @@ figure~\onpage{fig:selfcrossing-1-non-neighbor}.
|
|||||||
|
|
||||||
\begin{figure}[h]
|
\begin{figure}[h]
|
||||||
\centering
|
\centering
|
||||||
\begin{subfigure}[b]{.45\textwidth}
|
\begin{subfigure}[b]{.49\textwidth}
|
||||||
\includegraphics[width=\textwidth]{selfcrossing-1-before}
|
\includegraphics[width=\textwidth]{selfcrossing-1-before}
|
||||||
\caption{Bend's baseline (dotted) is crossing a non-neighboring bend}
|
\caption{Bend's baseline (dotted) is crossing a non-neighboring bend}
|
||||||
\end{subfigure}
|
\end{subfigure}
|
||||||
\hfill
|
\hfill
|
||||||
\begin{subfigure}[b]{.45\textwidth}
|
\begin{subfigure}[b]{.49\textwidth}
|
||||||
\includegraphics[width=\textwidth]{selfcrossing-1-after}
|
\includegraphics[width=\textwidth]{selfcrossing-1-after}
|
||||||
\caption{Self-crossing removed following the algorithm}
|
\caption{Self-crossing removed following the algorithm}
|
||||||
\end{subfigure}
|
\end{subfigure}
|
||||||
|
Loading…
Reference in New Issue
Block a user