Camera tilt checkerboard calibration full record vs200+opencv installation

The reference of the paper is this
Geiger A, Moosmann F, Car Ö, et al. Automatic camera and range sensor calibration using a single shot[C]//Robotics and Automation (ICRA), 2012 IEEE International Conference on. IEEE, 2012: 3936- 3943.The
code is this github

It took me a whole morning to configure the c++ environment. . . . . Yours, the windows system is really not suitable for C++ programming. The next opencv is so complicated, compiling and changing this configuration and changing that configuration. I really want to vomit if I have been using python.
Finally, I used vs2022, which seems to be OK, yours. Depend on.

vs2022+opencv_4_5_2
reference link
The main reason is that when adding dependent libraries, it is troublesome to add paths. Bin, lib, and dll must be added in a mess.

  1. First, right-click the project folder and click Properties at the bottom.
    Insert image description here
  2. Then click the vc++ directory, include the directory, the drop-down triangle on the right, and click Edit
    Insert image description here
  3. Enter the following two paths of your opencv build. I have not checked these two paths to find any use.
    Insert image description here
  4. Then click on the library directory under VC++, the same operation
    Insert image description here
  5. Then the additional dependencies inside link/input
    Insert image description here
  6. Enter the path of a lib file
    Insert image description here
    . See this friend's answer:
    Insert image description here
    Your version number is here: \build\x64\vc14\bin in the opencv directory, find opencv_worldyour version number.dll
    Xiaoxu said that I need to copy it, but I didn’t copy it. I just changed the version number, and then added...\opencv\build\x64\vc15\lib to the VC++/library directory (that’s the fourth step above, If you have already added the lib folder, don’t worry about it).

Then how to run a local folder page took me some time. Currently, I created a new project, copied the folder there, then clicked Show All Files, then right-clicked your folder and clicked Include to Project.
Insert image description here
Insert image description here
But the problem now is that opencv cannot read my pictures, which is very troublesome. It's okay. My path was wrong. . . . . . . .

C++17 file system library filestream.h

#include <filesystem>
namespace fs = std::filesystem;
...
...
...
	//********************读取文件夹下所有文件名******************************

	std::string currentPath = fs::current_path().string();
	std::cout << "Current Path: " << currentPath << std::endl;

	for (const auto& entry : fs::directory_iterator(currentPath)) {
    
    
		if (entry.is_regular_file()) {
    
    
			std::cout << entry.path().filename().string() << std::endl;
		}
	}

It’s really funny. After a day of matching the environment, this is the corner detection?
Insert image description here
Funny?

A code for checkerboard recognition, cnn implementation code
opencv official document. address

Guess you like

Origin blog.csdn.net/onlyyoujojo/article/details/134992876