我#正在阅读两张图片,并希望获得第三张图片,这只是两张图片的组合。img_object 和 img_scene 的大小不同。
int main( int argc, char** argv )
Mat combine;
Mat img_object = imread( object_filename, CV_LOAD_IMAGE_GRAYSCALE );
Mat img_scene = imread( scene_filename , CV_LOAD_IMAGE_GRAYSCALE );
if( !img_object.data || !img_scene.data )
{ std::cout<< " --(!) Error reading images " << std::endl; return -1; }
namedWindow( "Display window oject", 0 );// Create a window for display.
namedWindow( "Display window scene ", 0 );
namedWindow( "Display window combine ", 0 );
imshow( "Display window oject", img_object );
imshow( "Display window scene", img_scene );
imshow( "Display window scene", combine );
waitKey(0);
return 0;
}