This program should be run with 3 arguments:
template-matching original.bmp template.bmp out.bmp
The 3 arguments correspond to the path for input image, template image and output image.
There are template-matching.exe and template-matching-cpu.exe in the bin directory, which are GPU and CPU version built for Windows x64.
- Open
template-matching.slnwith VS 2015 - Compile & Run
nvcc -O3 -g -o template-matching bmp_util.c kernel.cu main.cu utils.cu --compiler-options -Wall,-Wextra,-Wno-unused-result
gcc -o template-matching-cpu cpumain.c bmp_util.c
bin/: compiled binary executable
images/: images and templates for testing
includes/: headers
bmp_util.c: functions to read and write BMP
kernel.cu: main logic and kernels
main.cu: main function and starting code
utils.cu: some CUDA helper functions
template-matching.sln: solution file for VS 2015
template-matching.vcxproj: project file for VS 2015
cpumain.c: code for CPU matching