This paper presents a novel two-stage system that detects diabetic retinopathy (DR) using fundus photographs. The first-stage of this system masks out the background consisting of the optic disc, using a novel Minimum Intensity Maximum Solidity (MinIMaS) overlap algorithm that is 99.7% accurate in segmenting the optic disc region on public data sets named DIARETDB0, DIARETDB1, DRIVE, and STARE. Receiver operating characteristic (ROC) analysis on the DIARETDB1 data set depicts that the second-stage of the system classifies bright lesions with 82.87% sensitivity, 94.36% specificity, 0.9593 area under ROC curves (AUC), and it detects red lesions with 75.5% sensitivity, 93.73% specificity, 0.8663 AUC using the Gaussian Mixture Models. Also, for DIARETDB1, free-response receiver operating characteristic (FROC) analysis shows that the proposed detection system achieves a sensitivity of 80% for bright lesion detection, and 64% for red lesion detection at 0.5 false positives per image. Thus, the proposed DR detection system outperforms existing works by lowering false positives in lesion classification, and hence it can be applied to enhance the effectiveness in screening patients for diabetic retinopathy.