diff --git a/documentation/kurver_ås.png b/documentation/kurver_ås.png new file mode 100644 index 0000000..337cbfd Binary files /dev/null and b/documentation/kurver_ås.png differ diff --git a/documentation/ms_wikipedia.svg b/documentation/ms_wikipedia.svg new file mode 100644 index 0000000..f0a0f15 --- /dev/null +++ b/documentation/ms_wikipedia.svg @@ -0,0 +1,3092 @@ + + + + + + + 1 + 2 + 3 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 3 + 3 + 3 + 3 + 2 + 2 + 2 + + + + + + + + + + + + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 0 + 0 + 0 + 0 + 0 + 0 + 0 + 0 + 0 + 0 + 0 + 0 + 0 + 0 + 0 + 0 + + + + + + + + + + + + + + 1 + 2 + 3 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 3 + 3 + 3 + 3 + 2 + 2 + 2 + + + + + + + + + + + + Case 0 + Case 1 + Case 2 + Case 3 + Case 4 + Case 5 + Case 6 + Case 7 + Case 8 + Case 9 + Case 10 + Case 11 + Case 12 + Case 13 + Case 14 + Case 15 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1 + 2 + 4 + 8 + + + Give every cell a bitnumber based onwhich corners aretrue/false + Look up the contourlines in the tableand put them inthe cells + Look at the originalvalues and use linearinterpolation todetermine amore accurate positionof all the line end-points + Thresholdwith isovalue + here:isovalue = 1 + 0 = below, 1 = above + = below + =above + Binary imageto cells + Look-up table contour lines + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 2 + 3 + 3 + 1 + 6 + 15 + 15 + 9 + 6 + 4 + 15 + 12 + 15 + 12 + 8 + 9 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/documentation/slides.md b/documentation/slides.md index a91d102..eacce3f 100644 --- a/documentation/slides.md +++ b/documentation/slides.md @@ -5,16 +5,31 @@ author: - Trygve og Esther --- -# What are contours -# Output of our program -pretty pictures +# Output of our program: +![Contour map of Ås](kurver_ås.png) + +# Marching squares +![By Nicoguaro; Adroitwhiz - File:Marching_squares_algorithm.svg, CC BY-SA 4.0, https://commons.wikimedia.org/w/index.php?curid=143418710](ms_wikipedia.svg) # The logical flow of our program -flowchart - -# GDAL -What is it? +```cpp +int main(int argc, const char* argv[]) +{ + const char* filepath = argv[1]; + HeightMap map(filepath); + map.blur(0.8) + auto lines = create_lines(&map, 5); + write_output_file(cellmaps, "out.geojson", &map); +} +``` # Performance -show the benchmarks \ No newline at end of file +| | Time | +|--------------------|--------------------| +| 12 threads | 41s | +| 1 thread | 116s | + + +# Problems we encountered +