I am looking for OpenCV java bindings, all the references point to the processing library. I know processing is java but isn't there a standalone java lib? or should just use processing libs?
I have just found this, a java wrapper of OpenCV :
https://github.com/bytedeco/javacv
Not tested, but I would love to have your point of view about this.
JavaCV is Java wrapper of OpenCV : https://github.com/bytedeco/javacv
Here is good tutorial on eclipse project configuration for JavaCV
And few applications using JavaCV is also posted there.
OpenCV now has an official Desktop Java port. It is still a work-in-progress and you have to compile opencv, but you should definitely take a look as it will be much friendly than JavaCV.
Take a look at these links for information:
http://answers.opencv.org/question/2137/wrapping-opencv-with-desktop-java-building-for-64/
And this:
http://code.opencv.org/projects/opencv/repository/revisions/fe0d07ae53ba9e6dcd1e470165ed0a85cbfce006
UPDATE (Fev 2013):
Java bindings have been released.
javacv looks pretty good, works with my webcam and images in a custom format. I'm just still looking for a possibility to performant create an IplImage from an array of floats.
I found this forum post where people are attempting pretty much the same thing:
http://nuigroup.com/forums/viewthread/3531/#44302
Related
I am trying to implement a face recognizer in java. I got this code example and made changes to fit my requirements on how the system should behave. It works but then when I have images of the same person in different light intensities its efficiency drops. I read that there is a library inserted in openCV for faceRecognizer but then its samples are implemented in c++. Is there any way i can use this library to code in java? and also if we can use it then will it increase the efficiency of the code?
Please do provide some help on this. Stuck on it badly...
You can create a C++ dll for java. You should write a wrapper class (in C++) which uses your C++ codes. Function definitions of the wrapper class should use JNI. This link here should be helpful (it was for me). After you implement the wrapper class, export it as a dll.
Just Use java cv so that you can use all c++ function in java.
Download all javacv jar files and try to install javacv to your system
Just look through how to setup javacv in your system.
I think this should do the magic in java
FaceRecognizer model=createFisherFaceRecognizer();
model.train(images,label);
For prediction
Int id=model.predict(img);
I want to develop a small Java program using some input like the pen of a Wacom graphictablet and found only the very active JPen project but are there some more possible alternatives without JNI or JNA (without any additional needed dll files), a pure Java implementation?
You can take a look at JTablet. From another SO thread.
It seems JPen moved to GitHub and this might be the best solution at the moment.
The other alternative solutions are not developed and maintained anymore.
https://github.com/nicarran/jpen
I'm looking to do a couple basic features with images and Java...
image resizing and cropping
possibly making composite images
What java library would be the easiest to use for that purpose?
thanks
Java Advanced Imaging API
http://java.sun.com/products/java-media/jai/forDevelopers/jaifaq.html
Have a look at the standard Java 2D graphics API first; it can do all the things you mention (resizing, cropping, compositing) without the need for exernal libraries such as Java Advanced Imaging.
See 2D Graphics in The Java Tutorials for an introduction.
Java Advanced Imaging (here is an FAQ for it).
See also this article.
Apache also has an implementation which aims to be a more portable than other frameworks (and is slower). See the sanselan page.
Catalano Framework. You can use the same code in Android too, contains several algorithm in parallel.
Project: https://code.google.com/p/catalano-framework/
Article: http://www.codeproject.com/Articles/656059/Catalano-Framework
I am working on a project which requires face detection through webcam.Suggest me any libraries that I can use to do this.i found one named openCV but it is for windows only.plz suggest some other methods also.Thank you.
OpenCV is almost a standard in computer vision. It works on both unix like and windows platforms - http://opencv.willowgarage.com/wiki/. Follow the installation manual and the basic tutorials to get started.
There is a processing library that calls OpenCV functions. That way you could use the OpenCV functionality without going down to c++ yourself. You can use the processing library with java without using the whole processing stuff.
Is there an easy way to use DirectX in Java? In particular, DirectX's video APIs.
I know that C# might be a more natural choice, but I have my devious reasons for wanting to do something so perverse.
I don't know about easy, but you could always use JNI to load the DirectX libs and invoke the methods.
Using something like Swig you could auto-generate a lot of the code.
Not sure how workable something like that would be though.
There seems to be a standard API about dealing with 3D inside Java.
It probably uses some kind of accelerating technology, may be even DirectX.
But I'm not sure about direct video support in this framework.
I create a library using BridJ (https://bridj.googlecode.com) that wrap DirectX classes, so you can use almost the same code than C++ examples.
You can find the library in https://bitbucket.org/fourthskyinteractive/directx-for-java.
Please, let me know about projects you develop.
There is a set of Direct3D bindings for Java available at http://java-direct3d.sourceforge.net/ but it seems that developement stopped in 2006 with DirectX 9.
Otherwise, there are OpenGL binding for java called JOGL.
The package that you want to investigate is the Java Media Framework (JMF). The core of it is pure Java, and per-platform "performance packs" provide acceleration via native libraries. It currently supports A/V capture and playback in a wide variety of data types as well as streaming via RTP and RTSP.
Sun's JMF home page
JMF SW/HW requirements
Minecraft is coded in Java with LWJGL, but Messiah Andrew's Renderer Wrapper converts the OpenGL to DirectX by using a modified version of the LWJGL libraries. Using these libraries, you should be able to code in LWJGL and have the game be running DirectX.
It seems that most are forgetting that JavaFX and Java3D support both DirectX and OpenGL using the best context for the machine you are on... well actually if you are on windows it attempts to load DirectX if it is newer than your OpenGL version.
I am not telling anyone to use either Java3D or JavaFX, but if you look at the source you can see how it is done.
GrepCode "good for looking for how things are implemented"
Open JavaFX "Open JavaFX project home" source
I should note that you want to look at the com.sun.prism package.
Java3D "Java3D project home" sources
I have been LEARNING development, LOL, for 20 years. Professionally for about 8 possible has never been the question, but how long, and/or is it worth it... Those are the questions.
Good luck my friend!
If you need any help I would be interested in creating a DirectX wrapper for java so
GIVE ME A SHOUT!