Quantcast
Channel: OpenCV Q&A Forum - Latest question feed
Viewing all articles
Browse latest Browse all 19555

Translating code from C++

$
0
0
Hello, I'm trying to learn OpenCV in JAVA, but I have really bad time searching for any source of information. I want to load and display an image using OpenCV exacly like in this tutorial below, but using JAVA: http://docs.opencv.org/trunk/db/deb/tutorial_display_image.html int main( int argc, char** argv ) { String imageName( "../data/HappyFish.jpg" ); // by default if( argc > 1) { imageName = argv[1]; } Mat image; image = imread( imageName, IMREAD_COLOR ); // Read the file if( image.empty() ) // Check for invalid input { cout << "Could not open or find the image" << std::endl ; return -1; } namedWindow( "Display window", WINDOW_AUTOSIZE ); // Create a window for display. imshow( "Display window", image ); // Show our image inside it. waitKey(0); // Wait for a keystroke in the window return 0; } If you know any tutorials for OpenCV using JAVA I would be grateful if you could link them.

Viewing all articles
Browse latest Browse all 19555

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>