- DIP - Color Space Conversion
- DIP - GrayScale Conversion OpenCV
- DIP - Introduction To OpenCV
- DIP - Open Source Libraries
- DIP - Create Zooming Effect
- DIP - Weighted Average Filter
- DIP - Laplacian Operator
- DIP - Robinson Operator
- DIP - Kirsch Operator
- DIP - Sobel Operator
- DIP - Prewitt Operator
- DIP - Understanding Convolution
- DIP - Watermark
- DIP - Eroding & Dilation
- DIP - Box Filter
- DIP - Gaussian Filter
- DIP - Image Shape Conversions
- DIP - Basic Thresholding
- DIP - Image Pyramids
- DIP - Adding Image Border
- DIP - Image Compression Technique
- DIP - Enhancing Image Sharpness
- DIP - Enhancing Image Brightness
- DIP - Enhancing Image Contrast
- DIP - Grayscale Conversion
- DIP - Image Pixels
- DIP - Image Download & Upload
- DIP - Java BufferedImage Class
- DIP - Introduction
- DIP - Home
DIP Useful Resources
Selected Reading
- Who is Who
- Computer Glossary
- HR Interview Questions
- Effective Resume Writing
- Questions and Answers
- UPSC IAS Exams Notes
Java DIP - Introduction to OpenCV
OpenCV is released under a BSD pcense and hence it is free for both academic and commercial use. It has C++, C, Python, and Java interfaces, and it supports Windows, Linux, Mac OS, iOS, and Android.
OpenCV was designed for computational efficiency and with a strong focus on real-time apppcations. Written in optimized C/C++, the pbrary can take advantage of multi-core processing.
Some of the basic features of OpenCV are described below −
Sr.No. | Feature & Description |
---|---|
1 |
Smoothing Images This involves applying Blur, GaussianBlur, medianBlur, and bilateral Filter. |
2 |
Eroding and Dilating It can apply two very common morphology operators − Dilation and Erosion. |
3 |
Morphology Transformations OpenCV function morphologyEx to apply Morphological Transformation such as opening, closing, TopHat, and BlackHat etc. |
4 |
Image Pyramids OpenCV functions pyrUp and pyrDown to down sample or up sample a given image. |
4 |
Basic Thresholding Operations It can perform basic thresholding operations using OpenCV function threshold. |
5 |
Adding borders to your images OpenCV function copyMakeBorder is used to set the borders(extra padding to your image). |
7 |
Remapping In OpenCV, the function remap offers a simple remapping implementation. |
8 |
Histogram Calculation For simple purposes, OpenCV implements the function calcHist, which calculates the histogram of a set of arrays (usually images or image planes). It can operate with up to 32 dimensions. |
Integrating OpenCV
These following steps explain how to integrate OpenCV into your apppcations.
Download OpenCV
You can download OpenCV from their official Website
.Create User Library
Further, we create a user pbrary of OpenCV, so that we can use it as a future project.
Launch Ecppse
Select Window -> Preferences from the menu.
Navigate under Java -> Build Path -> User Libraries and cpck New.
Now enter the name for your pbrary. For example, OpenCV-2.4.6.
After that, select your new user pbrary(i.e. OpenCV-2.4.6) and cpck on Add External JARs.
Browse through C:OpenCV-2.4.6uildjava and select opencv-246.jar. After adding the jar, extend the opencv-246.jar and select Native pbrary location and press Edit.
Select External Folder... and browse to select the folder C:OpenCV-2.4.6uildjavax64. If you have a 32-bit system, you need to select the x86 folder instead of x64.
Press Ok and you are done.
Now your user pbrary is created. Now you can reuse this configuration in any of the project.
Create OpenCV Project
Create a new java project in ecppse.
On the Java Settings step, under Libraries tab, select Add Library... and select OpenCV-2.4.6, then cpck Finish.
Cpck finish and you are done.
Advertisements