Skip to content

Commit 172602b

Browse files
committed
cleaning docs and adding intial note
1 parent 0812ce0 commit 172602b

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

60 files changed

+77
-50
lines changed
-30 Bytes
Binary file not shown.
Binary file not shown.
Binary file not shown.
1.87 KB
Binary file not shown.
1.77 KB
Binary file not shown.
1.72 KB
Binary file not shown.
1.83 KB
Binary file not shown.
1.12 KB
Binary file not shown.

docs/build/html/01 - Installing OpenCV for Java.html

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ <h2>Install Open CV 2.4.6 under Linux or Mac.<a class="headerlink" href="#instal
7777
As first step, if you don&#8217;t have these already, download and install <a class="reference external" href="http://www.cmake.org/download/">CMake</a> and <a class="reference external" href="http://ant.apache.org/">Apache Ant</a>.
7878
Extract the downloaded OpenCV file in a location of your choice and open CMake ( cmake-gui ).
7979
Put the location of the extracted OpenCV library in the <code class="docutils literal"><span class="pre">Where</span> <span class="pre">is</span> <span class="pre">the</span> <span class="pre">source</span> <span class="pre">code</span> <span class="pre">field</span></code> (e.g., /opencv2.4.6.1/) and put the destination directory of your build in the <code class="docutils literal"><span class="pre">Where</span> <span class="pre">to</span> <span class="pre">build</span> <span class="pre">the</span> <span class="pre">binaries</span></code> field (e.g., /opencv2.4.6.1/build), at last, check the <code class="docutils literal"><span class="pre">Grouped</span></code> and <code class="docutils literal"><span class="pre">Advanced</span></code> checkboxes.</p>
80-
<a class="reference internal image-reference" href="./res/01-00.png"><img alt="./res/01-00.png" src="./res/01-00.png" style="height: 200pt;" /></a>
80+
<img alt="_images/01-00.png" src="_images/01-00.png" />
8181
<p>Now press <code class="docutils literal"><span class="pre">Configure</span></code> and use the default compilers for <code class="docutils literal"><span class="pre">Unix</span> <span class="pre">Makefiles</span></code>.
8282
In the <code class="docutils literal"><span class="pre">Ungrouped</span> <span class="pre">Entries</span></code> group, insert the path to the Apache Ant executable (e.g., <code class="docutils literal"><span class="pre">/apacheant1.9.2/bin/ant</span></code>).
8383
In the <code class="docutils literal"><span class="pre">BUILD</span></code> group, unselect:
@@ -91,19 +91,19 @@ <h2>Install Open CV 2.4.6 under Linux or Mac.<a class="headerlink" href="#instal
9191
insert the Java include path (e.g., <code class="docutils literal"><span class="pre">/usr/lib/jvm/java7oracle/include/</span></code>)
9292
insert the alternative Java include path (e.g., <code class="docutils literal"><span class="pre">/usr/lib/jvm/java7oracle/include/linux</span></code>)
9393
Once we have pressed <code class="docutils literal"><span class="pre">Generate</span></code> twice the CMake window should appear with a white background. Now close CMake.</p>
94-
<img alt="res/01-01.png" src="res/01-01.png" />
94+
<img alt="_images/01-01.png" src="_images/01-01.png" />
9595
<p>Now open the terminal , go to the <code class="docutils literal"><span class="pre">build</span></code> folder of OpenCV and build everything with the command: <code class="docutils literal"><span class="pre">make</span> <span class="pre">-j8</span></code> (wait for the process to be completed...).
9696
If everything went well you should have <code class="docutils literal"><span class="pre">opencv-246.jar</span></code> and <code class="docutils literal"><span class="pre">libopencv_java246.so</span></code> files in the <code class="docutils literal"><span class="pre">/opencv-2.4.6.1/build/bin</span></code> directory and the <code class="docutils literal"><span class="pre">data</span></code> folder in the <code class="docutils literal"><span class="pre">/opencv-2.4.6.1/</span></code> directory.</p>
9797
</div>
9898
<div class="section" id="set-up-opencv-for-java-in-eclipse">
9999
<h2>Set up OpenCV for Java in Eclipse<a class="headerlink" href="#set-up-opencv-for-java-in-eclipse" title="Permalink to this headline"></a></h2>
100100
<p>Open Eclipse and select a workspace of your choice. Create a User Library, ready to be used on all the next projects: go to <code class="docutils literal"><span class="pre">Window</span> <span class="pre">&gt;</span> <span class="pre">Preferences...</span></code>.</p>
101-
<img alt="res/01-02.png" src="res/01-02.png" />
101+
<img alt="_images/01-02.png" src="_images/01-02.png" />
102102
<p>From the menu navigate under <code class="docutils literal"><span class="pre">Java</span> <span class="pre">&gt;</span> <span class="pre">Build</span> <span class="pre">Path</span> <span class="pre">&gt;</span> <span class="pre">User</span> <span class="pre">Libraries</span></code> and choose <code class="docutils literal"><span class="pre">New...</span></code>.
103103
Enter a name for the library (e.g., opencv246) and select the newly created user library.
104104
Choose <code class="docutils literal"><span class="pre">Add</span> <span class="pre">External</span> <span class="pre">JARs...</span></code>, browse to select <code class="docutils literal"><span class="pre">opencv246.jar</span></code>.
105105
After adding the jar, extend it and select <code class="docutils literal"><span class="pre">Native</span> <span class="pre">library</span> <span class="pre">location</span></code> and press <code class="docutils literal"><span class="pre">Edit...</span></code>.</p>
106-
<img alt="res/01-03.png" src="res/01-03.png" />
106+
<img alt="_images/01-03.png" src="_images/01-03.png" />
107107
<p>Select <code class="docutils literal"><span class="pre">External</span> <span class="pre">Folder...</span></code> and browse to select the folder containing the OpenCV libraries (e.g., <code class="docutils literal"><span class="pre">C:\opencv\build\java\x64</span></code> under Windows).</p>
108108
</div>
109109
</div>

docs/build/html/02 - First Java Application with OpenCV.html

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,10 @@ <h3>Navigation</h3>
5151

5252
<div class="section" id="first-java-application-with-opencv">
5353
<h1>First Java Application with OpenCV<a class="headerlink" href="#first-java-application-with-opencv" title="Permalink to this headline"></a></h1>
54+
<div class="admonition note">
55+
<p class="first admonition-title">Note</p>
56+
<p class="last">We assume that by now you have already read the previous tutorials. If not, please check previous tutorials at <a class="reference external" href="http://polito-java-opencv-tutorials.readthedocs.org/en/latest/index.html">http://polito-java-opencv-tutorials.readthedocs.org/en/latest/index.html</a>. You can also find the source code and resources at <a class="reference external" href="https://github.com/java-opencv/Polito-Java-OpenCV-Tutorials-Source-Code">https://github.com/java-opencv/Polito-Java-OpenCV-Tutorials-Source-Code</a></p>
57+
</div>
5458
<div class="section" id="introduction-to-a-opencv-application-with-java">
5559
<h2>Introduction to a OpenCV application with Java<a class="headerlink" href="#introduction-to-a-opencv-application-with-java" title="Permalink to this headline"></a></h2>
5660
<p>This tutorial will guide you through the creation of a simple Java console application using the OpenCV library by mean of Eclipse.</p>
@@ -70,17 +74,17 @@ <h2>What we will do in this tutorial<a class="headerlink" href="#what-we-will-do
7074
<div class="section" id="create-a-new-project">
7175
<h2>Create a New Project<a class="headerlink" href="#create-a-new-project" title="Permalink to this headline"></a></h2>
7276
<p>Open Eclipse and create a new Java project; open the <code class="docutils literal"><span class="pre">File</span></code> menu, go to <code class="docutils literal"><span class="pre">New</span></code> and click on <code class="docutils literal"><span class="pre">Java</span> <span class="pre">Project</span></code>.</p>
73-
<img alt="res/02-00.png" src="res/02-00.png" />
77+
<img alt="_images/02-00.png" src="_images/02-00.png" />
7478
<p>In the <code class="docutils literal"><span class="pre">New</span> <span class="pre">Java</span> <span class="pre">Project</span></code> dialog write the name of your project and click on <code class="docutils literal"><span class="pre">Finish</span></code>.</p>
7579
</div>
7680
<div class="section" id="add-a-user-library">
7781
<h2>Add a User Library<a class="headerlink" href="#add-a-user-library" title="Permalink to this headline"></a></h2>
7882
<p>If you followed the previous tutorial (<code class="docutils literal"><span class="pre">Installing</span> <span class="pre">OpenCV</span> <span class="pre">for</span> <span class="pre">Java</span></code>), you should already have the OpenCV library set in your workspace&#8217;s user libraries, if not please check out the previous tutorial.
7983
Now you should be ready to add the library to your project.
8084
Inside Eclipse&#8217;s <code class="docutils literal"><span class="pre">Package</span> <span class="pre">Explorer</span></code> just right-click on your project&#8217;s folder and go to <code class="docutils literal"><span class="pre">Build</span> <span class="pre">Path</span> <span class="pre">--&gt;</span> <span class="pre">Add</span> <span class="pre">Libraries...</span></code>.</p>
81-
<img alt="res/02-01.png" src="res/02-01.png" />
85+
<img alt="_images/02-01.png" src="_images/02-01.png" />
8286
<p>Select <code class="docutils literal"><span class="pre">User</span> <span class="pre">Libraries</span></code> and click on <code class="docutils literal"><span class="pre">Next</span></code>, check the checkbox of the OpenCV library and click <code class="docutils literal"><span class="pre">Finish</span></code>.</p>
83-
<img alt="res/02-02.png" src="res/02-02.png" />
87+
<img alt="_images/02-02.png" src="_images/02-02.png" />
8488
</div>
8589
<div class="section" id="create-a-simple-application">
8690
<h2>Create a simple application<a class="headerlink" href="#create-a-simple-application" title="Permalink to this headline"></a></h2>
@@ -119,7 +123,7 @@ <h2>Create a simple application<a class="headerlink" href="#create-a-simple-appl
119123
</div>
120124
<p>We can now try to build and run our application by clicking on the Run button.
121125
You should have the following output:</p>
122-
<img alt="res/02-03.png" src="res/02-03.png" />
126+
<img alt="_images/02-03.png" src="_images/02-03.png" />
123127
<p>Here I put the whole source code:</p>
124128
<div class="highlight-java"><div class="highlight"><pre><span class="kn">package</span> <span class="n">mypackage</span><span class="o">;</span>
125129

0 commit comments

Comments
 (0)