Fuzzy segmentation is an effective way of segmenting out objects in images containing both random noise and varying illumination. In this paper, a modified method based on the Comprehensive Learning Particle Swarm Optimization (CLPSO) is proposed for pixel classification in HSI color space by selecting a fuzzy classification system with minimum number of fuzzy rules and minimum number of incorrectly classified patterns. In the CLPSO-based method, each individual of the population is considered to automatically generate a fuzzy classification system. Afterwards, a population member tries to maximize a fitness criterion which is high classification rate and small number of fuzzy rules. To reduce the multidimensional search space for an M-class classification problem, centroid of each class is calculated and then fixed in membership function of fuzzy system. The performance of the proposed method is evaluated in terms of future classification within the RoboCup soccer environment with spatially varying illumination intensities on the scene. The results present 85.8% accuracy in terms of classification.