Giter VIP home page Giter VIP logo

apriltags-cpp's Introduction

apriltags-cpp

C++ port of the APRIL tags library, using OpenCV (and optionally, CGAL).

Requirements

Currently, apriltags-cpp requires the following to build:

  • OpenCV >= 2.3
  • GLUT or freeglut (optional, used for test program)
  • Cairo (optional, used to print tags)
  • CGAL (optional, used for new quad detection algorithm)

You must have cmake installed to build the software as well.

Building

To compile the code,

cd /path/to/apriltags-cpp
mkdir build
cd build
cmake .. -DCMAKE_BUILD_TYPE=Release
make

Demo/utility programs

The APRIL tags library is intended to be used as a library, from C++, but there are also five demo/utility programs included in this distribution:

  • tagtest - Demonstrate tag recognition and time profiling.

  • camtest - Demonstrate 3D tag locations using OpenCV to visualize, with an attached camera.

  • gltest - Demonstrate 3D tag locations using OpenGL to visualize, with an attached camera.

  • quadtest - Demonstrate/test tag position refinement using a template tracking approach.

  • maketags - Create PDF files for printing tags.

There are some test images in the images directory, that may be useful to use with the tagtest program.

apriltags-cpp's People

Contributors

airfield20 avatar davelkan avatar mzucker avatar psigen avatar varandaas avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

apriltags-cpp's Issues

Cannot make it work withKinect v2

Hello,
I wrote a code that parses the rgb stream from the kinectv2 and i'm trying to recognize the tags but it does not work.
I also tried to resize the frame to 640x480 but nothing changed.
i'm not passing any parameter to the command line.
I think the detector is running normally because sometimes it recognizes something random.
Do you have an idea of what it might be the problem?
Thanks

this project doesn't update?

hi,professor:
this project is alsome, but doesn't update for a long time, apriltag 3 has evolved, it has better detection algorithm that more fast and accurate, but it dosen't use C++ and it just run on CPU,
so , can please let this project going on? make it better!
PLEASE!

how to run the demo??

i have installed it and I tried to run the demo camtest. But it shows:

edison@edison-Vostro-3668:~/kinect/apriltags-cpp/build$ ./camtest
family.minimumHammingDistance = 11
family.errorRecoveryBits = 5
Set camera to resolution: 0x0
no frames!

there is no window for detecting, can you please help me? thank you

Need clearer licensing

The headers of the source files say this code is distributed under GPL, but the original apriltags-cpp was LGPL v2. Is this source code GPL, LGPL, or something else? The complete text of the license should appear at the top of every source file, and in the README.

how to get the pose information

After running ./camtest. I can see the apriltags have been detected by have red boxes. Now, how to get the pose information(x,y,z,w) of the apriltags?
please give me some helps, thank you

Error

Hello I'm new to april tags and need a bit of help. Using your repository I've been able to compile as mentioned, but when i try to write a small snippet for another application (where i need to extract the center of the tag, I am facing a small issue and need `advise.The following is the code i've included all header files accordingly.

`using namespace std;
using namespace AprilTags;
using namespace cv;

int main(int argc, char* argv[])
{
VideoCapture cap(1); // open the default camera
if(!cap.isOpened()) // check if we succeeded
return -1;

namedWindow("view",1);
TagDetector detector(AprilTags::tagCodes36h11);

for(;;)
{
    Mat frame;
    cap >> frame; // get a new frame from camera
    std::vector< TagDetection> detector.extractTags(frame);
     imshow("view", frame);
    if(waitKey(30) >= 0) break;
}
// the camera will be deinitialized automatically in VideoCapture destructor
return 0;

}`

and am getting the following error which i am not able to solve.

In function main': /home/shashank/catkin_ws/src/apriltags-cpp/src/my_tag.cpp:39: undefined reference to AprilTags::TagDetector::extractTags(cv::Mat const&)'
CMakeFiles/my_tag.dir/my_tag.cpp.o: In function AprilTags::TagDetector::TagDetector(AprilTags::TagCodes const&)': /usr/local/include/AprilTags/TagDetector.h:21: undefined reference to AprilTags::TagFamily::TagFamily(AprilTags::TagCodes const&)'
collect2: error: ld returned 1 exit status
make[2]: *** [my_tag] Error 1
make[1]: *** [src/CMakeFiles/my_tag.dir/all] Error 2
make: *** [all] Error 2

could you plz help me on this.
Thnk you

how to cal the distance between the tag and camera?

At first, i appreciate you sincerely.just i have some question about apriltag that how dose it calcuate the distance between the tag and camera in 3D? in other words,how to know the tag`s pose?Its x,y,z in coordinate system.

Install Command

It would be great to have an install command in the CMakeLists that puts the library in the standard lib directory (i.e. make install works)

Missing CUDA link directories

When compiling using cuda-enabled OpenCV, I get the following:

/usr/bin/ld: cannot find -lcufft
/usr/bin/ld: cannot find -lnpps
/usr/bin/ld: cannot find -lnppi
/usr/bin/ld: cannot find -lnppc

I solved this on my own machine by adding this at line 18 to CMakeLists.txt:

  link_directories(/usr/local/cuda-7.0/lib64)

Ideally, the CMakeLists.txt file should deal with this automatically by detecting if CUDA is enabled and linking against it if it is.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.