| 57 | } |
| 58 | |
| 59 | bool NucleiDetectionFilterPlugin::initialize(const ImageSource* img) { |
| 60 | if (img->getColorType() == pathology::ColorType::RGB || img->getColorType() == pathology::ColorType::RGBA || img->getColorType() == pathology::ColorType::Monochrome) { |
| 61 | if (img->getColorType() == pathology::ColorType::Monochrome) { |
| 62 | _monochromeInput = true; |
| 63 | } |
| 64 | else { |
| 65 | _monochromeInput = false; |
| 66 | } |
| 67 | return true; |
| 68 | } |
| 69 | else { |
| 70 | return false; |
| 71 | } |
| 72 | } |
| 73 | |
| 74 | void NucleiDetectionFilterPlugin::filter(const Patch<double> &input, QVariant &output) { |
| 75 | NucleiDetectionFilter<double>* filter = dynamic_cast<NucleiDetectionFilter<double>* >(_filter.get()); |
no test coverage detected