Home Content Sublime Text OpenCV C++ Build System

Sublime Text OpenCV C++ Build System

by Jack Simpson

If you want to compile and run a C++ program using OpenCV in Sublime Text, then copy and paste the code below into a build system file. If you’re not interested in explicitly using C++11 you can delete the “-std=c++0x” section.


{
"shell_cmd": "g++ -std=c++0x ${file} -o ${file_base_name} `pkg-config --cflags --libs opencv` && ./${file_base_name}"
}

Sign up to my newsletter

Sign up to receive the latest articles straight to your inbox

You may also like

Leave a Comment