Can OpenCV be downloaded & built for Angstrom (BeagleBoard) not as part of the toolchain? - opencv

Simple question: can I build OpenCV on Angstrom (BeagleBoard) without downloading it as part of the toolchain ? meaning by downloading the code of the Unix version and building it
(of course, the build process itself would have to be done via the toolchain, but do I have to download the OpenCV as part of the toolchain rather than later, as separated files) ?

You can download OpenCV source code and use the toolchain to compile it. You might have to do some patching yourself, but you wouldn't be first to succeed.

Related

Build Opencv 3.1.0 with IPP ippicv_windows_20151201.zip

I'm trying to build OpenCV 3.1.0 on a stand alone computer (there is no internet access).
I have an Intel composer 2015 installed, which include IPP v8.
During CMake build configuration, I get the following message:
Cmake error at 3rdparty/downloader.cmake.73
for file: [..... /ippicv_windows_20151201.zip]
expected hash [...] actual hash [...]
I figure out that I need to manually download ippicv_windows_20151201.zip and place it in the sources sub - folder.
Do you know where I can download it from?
I can exclude the build flag: "WITH_IPP" , In that case, I'd not build with IPP at all, which is something I don't want.
I'd rather like to build OpenCV with my pre-installed IPP (Intel Composer), not the downloaded free version from OpenCV, Do you know how I can do that ?
BWT, What is the difference between build WITH_IPP and WITH_IPP_A flags ?
P.S. I posted the same question on OpenCV forum
If the downloader.cmake is not finding the hash perhaps is not available yet or there is some error when reaching the URL (downloading protocol maybe?). Download the previous version from here, it'll do the work. Just need to place it in the correct folder. I'm using OpenCV 3.1.0 with the 20141027 with no problem at all.
In case you have an Intel composer which includes IPP library.
Go to your Opencv CMake --> Add entry (right side) --> Insert variable as a path:
IPP_ROOT
Set with the library location
Thus, would compile Opencv with IPP library from the Intel Composer
IPP_A comes for asynchronous IPP which is currently experimental

How to cross compile OpenCV with ffmpeg

I want to cross compile opencv with ffmpeg for arm.
I have cross compiled ffmpeg, how do I configure cmake to see the ffmpeg?
Edit: I am cross compiling for AR Drone 2.0. I use toolchain under platform/linux.
The answer to your specific problem is to use cmake-gui which provides you a visual interface to ease the process of setting up variables, like your ffmpeg package location.
However I have 2 recommendations:
Download the most updated toolchain.
DO NOT USE THIS GUIDE. Use instead the toolchain that you find in the package in sources\platforms\android\android.toolchain.cmake: read inside, you'll find the correct instructions at the beginning of the file.
Another optional recommendation: use ninja as build system, much faster.
I was successful in cross compiling OpenCV with ffmpeg for AR Drone's ARM processor by writing my own toolchain file where I explicitly set all the linker, pkg_config and compiler paths to relevant directories containing the cross-compiled stuff.
I have written a blog post detailing the entire process here:
How to Cross-Compile OpenCV with FFmpeg for AR Drone (ARM Processor).

How to cross-compile opencv

I'm trying (with no success) to cross-compile OpenCV on a embedded board.
I followed this: http://docs.opencv.org/doc/tutorials/introduction/crosscompilation/arm_crosscompile_with_cmake.html.
To summarize I installed the cross compilation tools for ARM, the I ran the cmake (providing the proper toolchain file), the make and the make install commands.
I next copied the lib/ include and bin/ directories with the opencv installation in the embedded board.
However, when I try to compile a simple hello world with opencv I get undefined reference to __gnu_thumb1_case_uqi and other similar symbols.
Does anybody faced this problem and know how to solve it?
Alternative approach
Just take some embedded distro like Buildroot, OpenEmbedded or Debian. They all provide OpenCV.
As I'm mostly experienced in Buildroot, I'd like to point to the newly introduced feature to keep your project separate from BR: http://nightly.buildroot.org/manual.html#outside-br-custom. This will give you a main idea on how to compile your software against BR's OpenCV.

What do we need to install for developing with JavaCV?

I want to use and learn JavaCV.
• So, I read some articles about how to set up JavaCV development environment in Window 7. At first they download and install OpenCV and adding some directory paths to System Variable, After that ,they extract javacv-0.7-bin.zip and javacv-0.7-cppjars.zip packages to somewhere(probably C:) and add some .jar files to their projects.
My Question : Do I need to install OpenCV for developing in JavaCV? because I wrote some JavaCV programs and my JavaCV programs compile and run properly (without installing OpenCV).
According to a javacv developer, the answer is NO. It comes bundled. Source: javacv issue 406 on GitHub.

OpenCV as a static library (cmake options)

I want to use OpenCV library in an embedded system and I need to compile my project using OpenCV as a static library.
How can I create the library using cmake options ?
To build OpenCV as static library you need to set BUILD_SHARED_LIBS flag to false/off:
cmake -DBUILD_SHARED_LIBS=OFF ..
But I think it is not enough for your task because you actually need to cross-compile library for you architecture. In case of Android or IOS such port already exists and you can simply use it. In case of another platform you need to create your own cmake toolchain file for cross-compiling and probably make a number of fixes in OpenCV build system.
The BUILD_SHARED_LIBS=OFF cmake option will create static libraries.
It should be noted that at the time of writing this, OpenCV does not really support static build, in that the result will not be useable when installed somewhere.
https://github.com/opencv/opencv/issues/21447#issuecomment-1013088996

Resources