Skip to content

Commit

Permalink
Merge pull request #61 from CSRT-NTUA/morphology
Browse files Browse the repository at this point in the history
Added morphology operations
  • Loading branch information
spirosmaggioros authored Jul 4, 2024
2 parents bc017b3 + 7edfb29 commit 3e05d29
Show file tree
Hide file tree
Showing 133 changed files with 2,830 additions and 1,249 deletions.
5 changes: 3 additions & 2 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@
"thread": "cpp",
"random": "cpp",
"list": "cpp",
"memory": "cpp"
}
"memory": "cpp",
},
"editor.language.colorizedBracketPairs": []
}
21 changes: 11 additions & 10 deletions docs/html/class_image-members.html
Original file line number Diff line number Diff line change
Expand Up @@ -84,16 +84,17 @@
<tr class="odd"><td class="entry"><a class="el" href="class_image.html#aa3b2dab58f9f49a64c3c8a1349b50e68">add</a>(Image img2) const</td><td class="entry"><a class="el" href="class_image.html">Image</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
<tr class="even"><td class="entry"><a class="el" href="class_image.html#aaeae286b25120ded439611b04bae3425">add_2_point</a>(const int x, const int y, const T val)</td><td class="entry"><a class="el" href="class_image.html">Image</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
<tr class="odd"><td class="entry"><a class="el" href="class_image.html#a3a56602ae5335142e179e679c9e31aa6">apply_filter2d</a>(std::vector&lt; std::vector&lt; int32_t &gt; &gt; &amp;filter) const</td><td class="entry"><a class="el" href="class_image.html">Image</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
<tr class="even"><td class="entry"><a class="el" href="class_image.html#ad70be146565fdfd89e6f061a80f6e348">get_2d_array</a>() const</td><td class="entry"><a class="el" href="class_image.html">Image</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
<tr class="odd"><td class="entry"><a class="el" href="class_image.html#a622b4c33bd14c5cd20d688f22a81fef4">get_point</a>(const int x, const int y) const</td><td class="entry"><a class="el" href="class_image.html">Image</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
<tr class="even"><td class="entry"><a class="el" href="class_image.html#a990cb1a2708a9af67c6b46a90b490aed">get_point</a>(const int x, const int y)</td><td class="entry"><a class="el" href="class_image.html">Image</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
<tr class="odd"><td class="entry"><a class="el" href="class_image.html#a6a6f4692c2770414c62cc1181ee0dfff">Image</a>(std::vector&lt; std::vector&lt; int32_t &gt; &gt; img_pass={}) noexcept</td><td class="entry"><a class="el" href="class_image.html">Image</a></td><td class="entry"><span class="mlabel">inline</span><span class="mlabel">explicit</span></td></tr>
<tr class="even"><td class="entry"><a class="el" href="class_image.html#a6383baa72a87f006f0d1ab1ac19006eb">Image</a>(int height, int width)</td><td class="entry"><a class="el" href="class_image.html">Image</a></td><td class="entry"><span class="mlabel">inline</span><span class="mlabel">explicit</span></td></tr>
<tr class="odd"><td class="entry"><a class="el" href="class_image.html#a7ceea7a73b614f189cd5c9e9bf3f7863">mul</a>(std::vector&lt; std::vector&lt; int32_t &gt; &gt; &amp;img2) const</td><td class="entry"><a class="el" href="class_image.html">Image</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
<tr class="even"><td class="entry"><a class="el" href="class_image.html#a1af53349d893161a56a03e1b89eed0f9">mul</a>(Image img2) const</td><td class="entry"><a class="el" href="class_image.html">Image</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
<tr class="odd"><td class="entry"><a class="el" href="class_image.html#a75f51a29849d86680f6e7548efdc73aa">set_point</a>(int x, int y, int val)</td><td class="entry"><a class="el" href="class_image.html">Image</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
<tr class="even"><td class="entry"><a class="el" href="class_image.html#ae998c80337bc8941c914e5209df97bb3">sub</a>(std::vector&lt; std::vector&lt; int32_t &gt; &gt; &amp;img2) const</td><td class="entry"><a class="el" href="class_image.html">Image</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
<tr class="odd"><td class="entry"><a class="el" href="class_image.html#a2f4635f1d0e7d8a11e7d4d10db18ed6c">sub</a>(Image img2) const</td><td class="entry"><a class="el" href="class_image.html">Image</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
<tr class="even"><td class="entry"><a class="el" href="class_image.html#a91a1625610a4bc05aa3b9f161edf57e2">binary</a>() const</td><td class="entry"><a class="el" href="class_image.html">Image</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
<tr class="odd"><td class="entry"><a class="el" href="class_image.html#ad70be146565fdfd89e6f061a80f6e348">get_2d_array</a>() const</td><td class="entry"><a class="el" href="class_image.html">Image</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
<tr class="even"><td class="entry"><a class="el" href="class_image.html#a622b4c33bd14c5cd20d688f22a81fef4">get_point</a>(const int x, const int y) const</td><td class="entry"><a class="el" href="class_image.html">Image</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
<tr class="odd"><td class="entry"><a class="el" href="class_image.html#a990cb1a2708a9af67c6b46a90b490aed">get_point</a>(const int x, const int y)</td><td class="entry"><a class="el" href="class_image.html">Image</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
<tr class="even"><td class="entry"><a class="el" href="class_image.html#a6a6f4692c2770414c62cc1181ee0dfff">Image</a>(std::vector&lt; std::vector&lt; int32_t &gt; &gt; img_pass={}) noexcept</td><td class="entry"><a class="el" href="class_image.html">Image</a></td><td class="entry"><span class="mlabel">inline</span><span class="mlabel">explicit</span></td></tr>
<tr class="odd"><td class="entry"><a class="el" href="class_image.html#a6383baa72a87f006f0d1ab1ac19006eb">Image</a>(int height, int width)</td><td class="entry"><a class="el" href="class_image.html">Image</a></td><td class="entry"><span class="mlabel">inline</span><span class="mlabel">explicit</span></td></tr>
<tr class="even"><td class="entry"><a class="el" href="class_image.html#a7ceea7a73b614f189cd5c9e9bf3f7863">mul</a>(std::vector&lt; std::vector&lt; int32_t &gt; &gt; &amp;img2) const</td><td class="entry"><a class="el" href="class_image.html">Image</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
<tr class="odd"><td class="entry"><a class="el" href="class_image.html#a1af53349d893161a56a03e1b89eed0f9">mul</a>(Image img2) const</td><td class="entry"><a class="el" href="class_image.html">Image</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
<tr class="even"><td class="entry"><a class="el" href="class_image.html#a75f51a29849d86680f6e7548efdc73aa">set_point</a>(int x, int y, int val)</td><td class="entry"><a class="el" href="class_image.html">Image</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
<tr class="odd"><td class="entry"><a class="el" href="class_image.html#ae998c80337bc8941c914e5209df97bb3">sub</a>(std::vector&lt; std::vector&lt; int32_t &gt; &gt; &amp;img2) const</td><td class="entry"><a class="el" href="class_image.html">Image</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
<tr class="even"><td class="entry"><a class="el" href="class_image.html#a2f4635f1d0e7d8a11e7d4d10db18ed6c">sub</a>(Image img2) const</td><td class="entry"><a class="el" href="class_image.html">Image</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
</table></div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Expand Down
33 changes: 33 additions & 0 deletions docs/html/class_image.html
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,9 @@
<tr class="memitem:a990cb1a2708a9af67c6b46a90b490aed" id="r_a990cb1a2708a9af67c6b46a90b490aed"><td class="memItemLeft" align="right" valign="top">int32_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a990cb1a2708a9af67c6b46a90b490aed">get_point</a> (const int x, const int y)</td></tr>
<tr class="memdesc:a990cb1a2708a9af67c6b46a90b490aed"><td class="mdescLeft">&#160;</td><td class="mdescRight">get_point function <br /></td></tr>
<tr class="separator:a990cb1a2708a9af67c6b46a90b490aed"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a91a1625610a4bc05aa3b9f161edf57e2" id="r_a91a1625610a4bc05aa3b9f161edf57e2"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a91a1625610a4bc05aa3b9f161edf57e2">binary</a> () const</td></tr>
<tr class="memdesc:a91a1625610a4bc05aa3b9f161edf57e2"><td class="mdescLeft">&#160;</td><td class="mdescRight">binary function. Check if an image is black and white <br /></td></tr>
<tr class="separator:a91a1625610a4bc05aa3b9f161edf57e2"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae46a0fc3c5ab7f98cedfc14802509926" id="r_ae46a0fc3c5ab7f98cedfc14802509926"><td class="memItemLeft" align="right" valign="top"><a class="el" href="class_image.html">Image</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#ae46a0fc3c5ab7f98cedfc14802509926">add</a> (std::vector&lt; std::vector&lt; int32_t &gt; &gt; &amp;img2) const</td></tr>
<tr class="memdesc:ae46a0fc3c5ab7f98cedfc14802509926"><td class="mdescLeft">&#160;</td><td class="mdescRight">add function adds the img2 to img <br /></td></tr>
<tr class="separator:ae46a0fc3c5ab7f98cedfc14802509926"><td class="memSeparator" colspan="2">&#160;</td></tr>
Expand Down Expand Up @@ -406,6 +409,36 @@ <h2 class="memtitle"><span class="permalink"><a href="#a3a56602ae5335142e179e679
</dl>
<dl class="section return"><dt>Returns</dt><dd>vector&lt;vector&lt;int32_t&gt; &gt; the resulted image </dd></dl>

</div>
</div>
<a id="a91a1625610a4bc05aa3b9f161edf57e2" name="a91a1625610a4bc05aa3b9f161edf57e2"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a91a1625610a4bc05aa3b9f161edf57e2">&#9670;&#160;</a></span>binary()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">bool Image::binary </td>
<td>(</td>
<td class="paramname"><span class="paramname"></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span> </td>
</tr>
</table>
</div><div class="memdoc">

<p>binary function. Check if an image is black and white </p>
<dl class="section return"><dt>Returns</dt><dd>true if the image is black and white </dd>
<dd>
false otherwise </dd></dl>

</div>
</div>
<a id="ad70be146565fdfd89e6f061a80f6e348" name="ad70be146565fdfd89e6f061a80f6e348"></a>
Expand Down
88 changes: 88 additions & 0 deletions docs/html/dir_34f07cb00329381c112abf22f7f2e286.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,88 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
<meta name="generator" content="Doxygen 1.10.0"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>AlgoPlus: /Users/spirosmag/Documents/AlgoPlus/tutorial/image/morphology Directory Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<script type="text/javascript" src="clipboard.js"></script>
<script type="text/javascript" src="cookie.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
<tbody>
<tr id="projectrow">
<td id="projectlogo"><img alt="Logo" src="logo.png"/></td>
<td id="projectalign">
<div id="projectname">AlgoPlus<span id="projectnumber">&#160;v0.1.0</span>
</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.10.0 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
var searchBox = new SearchBox("searchBox", "search/",'.html');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(function() {
initMenu('',true,false,'search.php','Search');
$(function() { init_search(); });
});
/* @license-end */
</script>
<div id="main-nav"></div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<div id="MSearchResults">
<div class="SRPage">
<div id="SRIndex">
<div id="SRResults"></div>
<div class="SRStatus" id="Loading">Loading...</div>
<div class="SRStatus" id="Searching">Searching...</div>
<div class="SRStatus" id="NoMatches">No Matches</div>
</div>
</div>
</div>
</div>

<div id="nav-path" class="navpath">
<ul>
<li class="navelem"><a class="el" href="dir_07c2df013bb20677b8e65a9f18968d2c.html">tutorial</a></li><li class="navelem"><a class="el" href="dir_8156ce265928c6d5a2b57dcbae95bfbb.html">image</a></li><li class="navelem"><a class="el" href="dir_34f07cb00329381c112abf22f7f2e286.html">morphology</a></li> </ul>
</div>
</div><!-- top -->
<div class="header">
<div class="headertitle"><div class="title">morphology Directory Reference</div></div>
</div><!--header-->
<div class="contents">
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by&#160;<a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.10.0
</small></address>
</body>
</html>
88 changes: 88 additions & 0 deletions docs/html/dir_53c6764aee5796f46c058e0b2db63910.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,88 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
<meta name="generator" content="Doxygen 1.10.0"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>AlgoPlus: /Users/spirosmag/Documents/AlgoPlus/examples/machine_learning/image/morphology Directory Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<script type="text/javascript" src="clipboard.js"></script>
<script type="text/javascript" src="cookie.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
<tbody>
<tr id="projectrow">
<td id="projectlogo"><img alt="Logo" src="logo.png"/></td>
<td id="projectalign">
<div id="projectname">AlgoPlus<span id="projectnumber">&#160;v0.1.0</span>
</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.10.0 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
var searchBox = new SearchBox("searchBox", "search/",'.html');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(function() {
initMenu('',true,false,'search.php','Search');
$(function() { init_search(); });
});
/* @license-end */
</script>
<div id="main-nav"></div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<div id="MSearchResults">
<div class="SRPage">
<div id="SRIndex">
<div id="SRResults"></div>
<div class="SRStatus" id="Loading">Loading...</div>
<div class="SRStatus" id="Searching">Searching...</div>
<div class="SRStatus" id="NoMatches">No Matches</div>
</div>
</div>
</div>
</div>

<div id="nav-path" class="navpath">
<ul>
<li class="navelem"><a class="el" href="dir_d28a4824dc47e487b107a5db32ef43c4.html">examples</a></li><li class="navelem"><a class="el" href="dir_52ca4c5bd9c8eb3bd1193a81de804b3a.html">machine_learning</a></li><li class="navelem"><a class="el" href="dir_cb03ce94fce8ccdd62afe2ec4257c72f.html">image</a></li><li class="navelem"><a class="el" href="dir_53c6764aee5796f46c058e0b2db63910.html">morphology</a></li> </ul>
</div>
</div><!-- top -->
<div class="header">
<div class="headertitle"><div class="title">morphology Directory Reference</div></div>
</div><!--header-->
<div class="contents">
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by&#160;<a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.10.0
</small></address>
</body>
</html>
Loading

0 comments on commit 3e05d29

Please sign in to comment.