Confocal Raman microscopy (CRM) is a promising in-situ visual technique that provides detailed insights into multiple lignocellulosic components and structures in plant cell walls at the micro-nano scale. In this study, we propose a novel CRM cosine similarity (CS) mapping strategy for the simultaneous in-situ visual profiling of lignin, cellulose, and hemicellulose in plant cell walls. The main stages of this strategy include: 1) a modified Otsu algorithm for extracting the regions of interest (ROI); 2) a modified subtraction method for cleaning the background signals in the ROI spectra; 3) a lignin signal subtraction method based on the pixel correction factor for eliminating the interference of strong lignin signals with weak cellulose and hemicellulose signals in the Raman full spectra of the cell walls; 4) second-order derivative spectral preprocessing for enhancing the discrimination between the characteristic peaks of cellulose and hemicellulose; 5) a CS mapping algorithm for simultaneous in-situ profiling of lignin, cellulose, and hemicellulose in plant cell walls. The effectiveness of the strategy is verified by characterizing the Brittle Culm1 (BC1) gene-mutant rice stem (IL349-BC1-KO) with known bioinformatics. This approach provides methodological support for in-situ visualization and analysis in fields such as plant or crop science at the micro-nano scale.