Ticket #51460: patch-pHash.cpp.diff
File patch-pHash.cpp.diff, 711 bytes (added by toy, 8 years ago) |
---|
-
src/pHash.cpp
369 369 if (src.spectrum() == 3){ 370 370 img = src.RGBtoYCbCr().channel(0).get_convolve(meanfilter); 371 371 } else if (src.spectrum() == 4){ 372 int width = img.width(); 373 int height = img.height(); 374 int depth = img.depth(); 375 img = src.crop(0,0,0,0,width-1,height-1,depth-1,2).RGBtoYCbCr().channel(0).get_convolve(meanfilter); 372 int width = src.width(); 373 int height = src.height(); 374 img = src.crop(0,0,0,0,width-1,height-1,0,2).RGBtoYCbCr().channel(0).get_convolve(meanfilter); 376 375 } else { 377 376 img = src.channel(0).get_convolve(meanfilter); 378 377 }