1. Introduction
Silk fiber, a versatile bioresource, finds extensive utility across agriculture, the textile industry, and biomedical engineering [
1]. The most used silk is obtained from the cocoons of the larvae of the mulberry silkworm
Bombyx mori. The history of silk dates to ancient China, where it was first developed and used for clothing and other textiles [
2]. With high mechanical strength and excellent optical transparency, silk also functions as a biomaterial in various biological and medical fields [
3]. The breeding of silkworms to yield new varieties has been an ongoing process for centuries to improve the quality and quantity of silk produced [
4,
5]. The breeding of silkworms stands as a crucial element in the creation of valuable textile materials [
5]. One of the objectives of silkworm breeding is to improve the quality and quantity of silk production, as well as the health of the silkworms. To achieve this, silkworm breeders need to monitor and measure various traits of the silkworms and their cocoons, such as weight, size, color, texture, and strength. Among these traits, cocoon color is particularly important, as it affects the appearance and value of silk products. During this process, optical sensing techniques have been employed to distinguish the colors of silk cocoons, aiming to assess their improved suitability across diverse industries [
6,
7,
8,
9]. A silk cocoon color measurement system can also help silkworm breeders understand the genetic and environmental factors that influence cocoon color, such as temperature, humidity, nutrition, and disease [
10,
11]. By using this system, silkworm breeders can optimize their breeding conditions and strategies to produce silkworms with desirable cocoon colors [
12].
The surface texture of silk cocoons exhibits a remarkable and intricate pattern characterized by an uneven and corrugated microstructure [
13]. This corrugated microstructure is defined by a series of undulating wrinkles that traverse the surface of the silk cocoon [
14]. These wrinkles create variations in height and depth, resulting in a textured landscape reminiscent of undulating hills and valleys. This unique topography can lead to color distortion and inconsistent color perception when viewed from different angles.
Figure 1a displays a comprehensive photograph capturing the entirety of the silk cocoon. This image shows a clear view of the cocoon’s external surface texture, characterized by the presence of distinct corrugations.
Figure 1b zooms in on a precisely cut 1 cm diameter section from the silk cocoon. This allows for a closer examination of both the external surface (left) and a cross-sectional view (right), revealing the intricate corrugated microstructure responsible for the cocoon’s unique texture.
Figure 1c presents a confocal image of cross-sections from the silk cocoon, showcasing the detailed and woven nature of the heterogeneously structured corrugated microstructure of the silk cocoon surface [
14].
Several methods are currently employed to discern the colors of silk fibers derived from silk cocoons, facilitating their versatile industry applications. Previous techniques for evaluating the color characteristics of silk cocoons have employed various techniques. Spectrophotometry has been used to analyze the reflected light spectrum from silk fibers to ascertain their color [
15], while chemical tests investigate color-related chemical properties [
16]. An existing method involved utilizing a Data-color 650 colorimeter to analyze the color index of both gold cocoon silk and gold-like cocoon silk [
17]. Another widely employed approach utilized digital cameras to comprehensively examine the color and external features of silk cocoons [
8,
18,
19,
20]. A distinct method involved cutting and scanning multiple cocoons using an integrating sphere over a wavelength range of 260 nm to 700 nm with a white cocoon serving as a control [
21]. Additionally, researchers have utilized the RGB color component difference as a threshold to discern the color variations in silk cocoons [
22]. In another study, visible spectroscopy was employed to evaluate the yellowish index of non-woven silk fabrics according to the CIE 1931 color space [
23]. This method involves analyzing the spectral properties of light reflected from the silk fabrics, particularly focusing on the yellowish hue within the color space.
These diverse techniques employed for ascertaining the color of silk cocoons exhibit several limitations, such as the cost and susceptibility to external factors affecting imaging conditions, thereby impeding the attainment of absolute color measurements. The current techniques fall short of providing an absolute depiction of the color of silk cocoons, primarily due to inherent constraints in calibration precision and variations in external environmental conditions during imaging processes.
Moreover, most of these methods assess the color only after extracting the silk fibers from the cocoons. If color could be determined at the silk cocoon level, it would enable the selective breeding of silk cocoons with desired colors, thereby streamlining the extraction process. While visual comparison remains the predominant method for distinguishing differently colored silk cocoons [
24], the uneven texture of the silk cocoon, with its corrugated microstructure, creates shadows and color distortion during conventional color measurement methods. Consequently, current visual color discrimination methods result in unnecessary fiber waste in the textile industry and potential experimental errors in medical fields.
When a directional light from any light source is used to shine on the uneven surface of a silk cocoon, the brightness (luminance in cd/m
2) is not the same everywhere on the silk cocoon surface. This happens because the luminance on the uneven surface of the silk cocoon with a corrugated microstructure is proportional to the cosine of the angle between the surface and the light source (
Figure 2a). Therefore, when the corrugated microstructures on the surface of the silk cocoon are at an oblique angle to the directional light, the luminance is reduced, resulting in shadows and highlights on the rough areas and making some parts look brighter or darker than others (
Figure 2b). This uneven distribution of luminance can make color measurement challenging and less reliable.
Uneven luminance distribution can affect the color measurement by causing variations in the perceived color due to differences in lighting across the sample [
25,
26]. The uneven luminance distribution can lead to shadowing and highlights, which may affect the perceived color of the silk cocoon. To mitigate this, uniform illumination techniques such as diffuse lighting or multiple light sources can be employed to ensure consistent and accurate color measurement. Thus, uneven luminance distribution can lead to inaccurate color measurements, impacting the quality assessment of silk cocoons. Employing uniform illumination techniques is essential to ensure accurate and reliable color measurement in the evaluation of silk cocoon quality.
A promising solution to this problem is utilizing an integrating sphere. The integrating sphere scatters light in all directions, resulting in a diffused and evenly distributed illumination across the silk cocoon surface (see
Figure 2c). Furthermore, this unique illumination system has the advantage of eliminating shadows originating from the uneven surface, as light arriving from multiple directions counteracts any shadow effects. Consequently, the corrugated microstructure of the silk cocoon’s surface appears smoother, enabling precise color extraction through mathematical analysis. This uniform illumination significantly enhances the accuracy and consistency of color measurements.
The relationship between luminance and the angle between the surface and the rays of the light source can be expressed mathematically as:
where
Lv is the luminance on the surface,
Lvo is the luminance of the light source, and
θ is the angle between the surface and the light source. This equation shows that the luminance on the surface decreases as the angle between the surface and the light source increases, resulting in shadows and highlights on the rough areas. The use of an integrating sphere eliminates these shadows and provides a diffused and evenly distributed illumination, resulting in more accurate and consistent color measurements.
To determine the absolute color of silk cocoons with their corrugated microstructures, we developed an optical setup consisting of a customized integrating sphere, a color reference standard (ColorChecker), and a camera. Opting for a digital camera combined with a customized integrating sphere to measure silk cocoon color, as opposed to prior use of fiber spectrometer setups [
12,
15], was due to the intricate way silk cocoons scatter and reflect light. The reflected light from the surface of silk cocoons is significantly influenced by the surface heterogeneities and measuring geometry. The customized integrating sphere serves to uniformly illuminate the textured surface of silk cocoons, enabling precise capture by the digital camera. Additionally, the high resolution of the camera, versatility, and affordability facilitate the absolute color measurement of the silk cocoons, crucial for understanding unique cocoon traits. Next, we employed the ColorChecker and performed a color calibration using MATLAB R2022b to precisely calibrate the RGB values obtained from the ColorChecker within the integrating sphere. Once calibration was complete, we computed the absolute color RGB values of the silk cocoons using the calibrated functions.
Obtaining the absolute color of silk cocoons is imperative for accurate and reliable analysis in various fields, including textile industry quality control and scientific research. Absolute color measurement ensures a standardized and consistent basis for comparison, enabling researchers and industry professionals to precisely evaluate color variations in silk cocoons. This is particularly crucial in applications where subtle color distinctions may carry significant implications, such as in the assessment of silk quality or the identification of specific characteristics related to cocoon health. Therefore, addressing the limitations of current methods is essential for enhancing the accuracy and robustness of silk cocoon color analysis.
3. Results
Figure 6 presents a thorough comparative analysis of the silk cocoon samples under different illumination conditions. In
Figure 6a, we observe an image of the silk cocoon sample under indoor lighting, revealing how indoor illumination affects its visual characteristics.
Figure 6b shows the same silk cocoon sample placed within an integrating sphere, ensuring uniform illumination. These images allow for a visual comparison of the sample’s color and texture under different lighting conditions.
Figure 6c provides further insights by presenting the intensity profiles of the red–green–blue (RGB) channels for images taken under indoor lighting conditions. The corresponding standard deviations for each channel are reported as R (SD—29.25%), G (SD—29.11%), and B (SD—22.29%). These standard deviations offer a measure of the variations in color intensity within the captured images, indicating the sensitivity of the sample’s appearance to indoor lighting conditions. In contrast,
Figure 6d displays the intensity profiles of the RGB channels for images captured under uniform illumination inside the integrating sphere. Here, the standard deviations for each channel are reported as R (SD—12.37%), G (SD—9.68%), and B (SD—14.46%). The significantly reduced standard deviations indicate that the uniform illumination provided by the integrating sphere results in a more consistent color representation of the silk cocoon sample.
This comparison substantiates the efficacy of the devised optical system with the integrating sphere. The images captured under uniform illumination exhibit a smooth surface texture, minimizing the visible hills and valleys compared to the images captured under uneven illumination conditions. It highlights how the uniform illumination provided by the system minimizes color variations caused by uneven lighting, thereby ensuring a more accurate and consistent extraction of absolute RGB values from silk cocoon samples. Ultimately, this finding not only aids in understanding the intricate colors of silk cocoons but also presents an innovative approach applicable to various specimens with uneven surface textures.
The color profiles of the silk cocoon samples under indoor lighting exhibited significant variability, primarily attributed to the uneven surface texture of the cocoons and the viewing angle. This observation underscores the challenges in accurately assessing the colors of silk cocoons. When we captured the samples under indoor lighting conditions and extracted their RGB values using MATLAB R2022b, we observed that the extracted RGB values appeared darker than expected. We attributed this discrepancy to the shadowing effects caused by the wrinkled surface of the silk cocoons, featuring corrugated microstructures, resulting in color distortion.
To determine the absolute colors of silk cocoon samples, we employed our integrating sphere imaging setup. The samples were illuminated inside the integrating sphere and placed alongside the ColorChecker, using an array of white LEDs operating at 2.7 V. Subsequently, we extracted the RGB values from the photographed ColorChecker (Rmeas, Gmeas, Bmeas) and compared them with the original RGB values of the ColorChecker (Rorig, Gorig, Borig). For the analysis, we utilized a curve-fitting process with a Power function to calibrate the RGB functions (f_R, f_G, f_B). The results of this curve-fitting procedure for our three sample sets demonstrate a linear relationship between the R, G, and B values.
By substituting the measured raw RGB values of the silk cocoons into the calibrated functions (f_R, f_G, f_B), we calculated the absolute RGB values (Rabs, Gabs, Babs) of silk cocoons. The resulting graph showed a linear relationship between the RGB values and the corresponding colors of the silk cocoon samples within the integrating sphere setup. Notably, the calibrated RGB values obtained from the Power function fitting curve exhibited a smooth transition and closely matched the expected values of the ColorChecker. This agreement serves to validate the effectiveness of our calibration procedure and strengthens the credibility of the absolute RGB values of the silk cocoon samples we obtained.
The three silk cocoon samples in the apricot color series were labeled as AP1, AP2, and AP3. We captured images of the entire silk cocoon from the control group with the upper section of the integrating sphere open, allowing indoor lighting to illuminate the samples (see
Figure 7). These lighting conditions revealed subtle variations in the apricot-colored silk cocoons, influenced by changes in light intensities, incident light angles, and viewing perspectives. In contrast, the treatment group images were taken with the upper section of the integrating sphere closed, resulting in uniform light illumination from all directions. Notably, the raw colors extracted from the control group appeared relatively darker, a phenomenon attributed to the shadowing effects caused by the silk cocoon’s uneven and corrugated surface. However, colors extracted from images captured under uniform illumination using a color calibration procedure showed absolute representative colors of silk cocoons consistent across all three apricot samples. This observation suggests that our customized integrating sphere setup, providing uniform illumination, effectively addressed the physical limitations associated with the uneven surface texture of the silk cocoons featuring a corrugated microstructure.
The camera settings for these captures were configured as follows: exposure 1.2 EV, sharpness 1024, shutter 66 ms, gain 8.868, white balance (red) 669, white balance (blue) 771, and gamma OFF. During raw data measurement and absolute color calculation, we defined a region of interest (ROI) measuring 0.5 cm × 0.5 cm from the silk cocoon sample.
To determine the absolute color of the apricot series silk cocoons shown in
Figure 7, we subdivided the region of interest (ROI) of the measured silk cocoon samples and extracted the RGB values. These RGB values were then input into the calibrated power functions (f_R, f_G, f_B) represented by the red lines (
Figure 8). The calibrated function for each sample in the apricot series of silk cocoons is summarized in
Table 1. The obtained absolute color of the silk cocoons, represented as the corrected RGB values for each sample in the apricot series, is as follows: AP1 = R: 251, G: 232, B: 200; AP2 = R: 254, G: 234, B: 200; AP3 = R: 251, G: 231, B: 195.
The three silk cocoon samples within the light green series of silk cocoons were labeled as LG1, LG2, and LG3. We captured the images of the prepared silk cocoon samples of the control group (see
Figure 9). In the control group images, the upper section of the integrating sphere was open, allowing indoor lighting to illuminate the silk cocoon samples. These images unveiled subtle variations among the light green series of silk cocoon samples, influenced by various factors such as differing light intensities, angles of incident light, and viewing perspectives. In contrast, the treated group images were captured with the upper section of the integrating sphere firmly attached to the bottom section, ensuring uniform light exposure from all directions. Notably, the raw colors extracted from the control group appear relatively darker, primarily due to the shadowing effect resulting from the uneven textured surface of the silk cocoon. Conversely, colors extracted from treated images, subjected to uniform illumination, exhibited consistent absolute colors among all three light green silk cocoon samples. This observation suggests that the physical limitations associated with silk cocoons, stemming from their corrugated microstructure, were effectively addressed in the treated group. The camera settings used for these captures were configured as follows: exposure 1.2 EV, sharpness 1024, shutter 66 ms, gain 8.868, white balance (red) 669, white balance (blue) 771, and gamma OFF. In our color analysis, we selected a region of interest (ROI) measuring 0.5 cm × 0.5 cm. This meticulous ROI selection ensured both the accuracy and consistency of our absolute color measurement across all samples of the light green series of silk cocoons.
We proceeded to perform a calibration of the RGB values and calculation of the absolute color of the light green series silk cocoons, as shown in
Figure 10. We chose a 0.5 cm × 0.5 cm region of interest (ROI) and extracted RGB values from these ROIs. These RGB values were then input into the calibrated power functions (f_R, f_G, f_B) represented by the red line (see
Figure 10). The calibrated function for each sample in the light green series is summarized in
Table 2. The resulting absolute colors for the light green silk cocoons are presented as the corrected RGB values for each sample, as follows: LG1 = R: 244, G: 234, B: 193. LG2 = R: 250, G: 241, B: 209. LG3 = R: 242, G: 232, B: 192.
The three silk cocoon samples within the yellow series were labeled as Y1, Y2, and Y3. We captured control group images under indoor lighting conditions. Color variations became noticeable in the images of the yellow color series of silk cocoon samples and became apparent under varying lighting intensities, incident light angles, and viewing perspectives (see
Figure 11). The raw color extracted from the control group appeared darker, attributed to the shadowing caused by the corrugated microstructure of the silk cocoon. On the other hand, the treated group images were acquired with the upper section of the integrating sphere attached to the bottom section, ensuring uniform light illumination from all directions. The images taken under uniform illumination exhibited smoother surface characteristics, indicating that physical limitations associated with the uneven silk cocoon surface were addressed in the treated group.
Our camera settings for these captures included exposure at 1.2 EV, sharpness at 1024, shutter speed of 66 ms, gain set at 8.868, white balance (red) adjusted to 669, white balance (blue) at 771, and gamma turned OFF. During the measurement of raw RGB values and calculation of the absolute colors, we defined a 0.5 cm × 0.5 cm region of interest (ROI).
To determine the absolute colors of the yellow silk cocoons, we selected the region of interest (ROI) measuring 0.5 cm × 0.5 cm from the measured silk cocoon samples. From this ROI, we extracted the RGB values and applied calibrated power functions (f_R, f_G, f_B) represented by the red lines (see
Figure 12). The calibrated function for each sample in the yellow series silk of cocoons is summarized in
Table 3. The absolute colors of silk cocoons, presented as the corrected RGB values for each sample, are as follows: Y1 = R: 247, G: 216, B: 137. Y2 = R: 247, G: 220, B: 138. Y3 = R: 247, G: 224, B: 164.
4. Discussion
The main objective of this study was to address the challenges posed by the intricate surface texture of the silk cocoons, which often resulted in inaccuracies when capturing their true RGB values. Notably, when silk cocoon images were taken under conventional indoor lighting conditions (as shown in
Figure 8,
Figure 10, and
Figure 12), a substantial disparity was observed between the RGB values recorded from the photographed images and the actual colors. This disparity was attributed to the complex wrinkled surface of silk cocoons with corrugated microstructures, making precise color measurements difficult. Additionally, real-world observations revealed that color variations were influenced by factors such as differing light intensities, angles of incident light, and viewing perspectives.
To overcome these challenges, a computational approach was devised to extract the absolute colors of silk cocoons. To minimize color distortion caused by the uneven surface of the silk cocoon’s corrugated microstructure, a customized integrating sphere system was designed and 3D printed. The inner walls of the sphere were coated with a mixture of commercially available white paint and water to maximize light reflection. As a result, the customized integrating sphere system provided uniform light distribution and irradiation from all angles by enabling multiple scattering and reflection of incident light.
The core of this study focused on the calibration process, which involved calibrating the colors of the ColorChecker images captured within the integrating sphere system using MATLAB R2022b. It is noteworthy that the RGB values within the integrating sphere setup deviated from the original ColorChecker’s true RGB values due to varying imaging conditions, such as illumination intensity. Therefore, the measured RGB values of the ColorChecker (R
meas, G
meas, B
meas) within the integrating sphere setup were compared with the original RGB values of the ColorChecker (R
orig, G
orig, B
orig) to assess deviations. A power function was applied using MATLAB 2022b’s curve fitting module to align the original and measured ColorChecker RGB values. The enhanced power function model was used to adjust the linear offset between ‘
x’ and ‘
y’. This curve-fitting process resulted in the calibration of the RGB functions (f_R, f_G, f_B). This calibration effectively linearized the RGB values, as demonstrated in
Figure 9,
Figure 11, and
Figure 12. This linearization enabled the extraction of absolute RGB values under specific imaging conditions. Furthermore, the silk cocoons captured within the integrating sphere setup exhibited a smoother and more linear surface compared to those captured under conventional indoor lighting conditions.
This study effectively employed a computational approach to mitigate color variation issues associated with silk cocoons’ corrugated microstructure. The newly developed system significantly streamlines color determination and eliminates the inaccuracies caused by shadowing and viewing angle distortions. By developing a more precise method for measuring the absolute color of silk cocoons, this research could greatly impact both the textile industry and the agriculture sector. In the textile industry, improved color measurement techniques could lead to more efficient breeding and extraction processes, reducing waste and increasing product quality. In medical fields, enhancing the accuracy of silk cocoon color measurement could minimize experimental errors, thereby increasing the reliability of applications such as biosensing and bioimaging. Additionally, by providing a standardized method for color measurement, this research may facilitate comparison and collaboration between different research efforts, advancing the overall field of silk cocoon utilization. We hope that this work will contribute to the more effective and wide-ranging use of this remarkable biomaterial.
Comparative Assessment of the Developed System to Existing Systems
In the pursuit of accurate color assessment for silk cocoons, various methodologies have been explored, each having distinct strengths and limitations. One widely adopted approach involves the use of UV–visible spectroscopy, as demonstrated by Cheng, L., et al. [
17,
45]. While this method attains high accuracy in color assessment, its prohibitively expensive nature poses a significant barrier, limiting its practical application on a broader scale. An alternative avenue explored in the literature involves digital camera-based techniques, as evidenced by several studies [
8,
18,
19,
20]. These techniques leverage digital images for color analysis, offering a more accessible option. However, a notable drawback lies in the reliance on the proportions of RGB values without adequate color calibration. This limitation becomes a focal point in our discussion, as it impedes the measurement of absolute color, a challenge effectively addressed by our proposed method.
Also, an integrating sphere has been utilized in conjunction with a colorimeter to obtain color index measurements for silk cocoons [
21]. Despite the valuable insights gained, the use of a white cocoon as a control introduces complexity in assessing the absolute color of silk cocoons. This limitation underscores the need for methodologies that overcome such challenges, paving the way for more comprehensive color evaluation. Another approach centers on the RGB color component difference for silk cocoon color identification [
16]. However, this method is not without its limitations. Issues arise from the reliance on data peak density and assumptions about ambient light conditions, aspects that our proposed technique successfully addresses through the incorporation of absolute color measurement. Visible spectroscopy, as employed by Kim et al. in [
23], to measure the yellowish index of non-woven silk fabrics in CIE 1931 color space. However, the high cost and demanding experimental conditions associated with the utilization of a spectrophotometer, render it impractical for applications such as small- to medium-sized silkworm breeding and sorting processes. This limitation emphasizes the necessity for more cost-effective user-friendly alternatives (see
Table 4).
Our developed technique introduces an optical system utilizing an integrating sphere, ensuring consistent and uniform illumination from all orientations. The calibration of RGB values using a ColorChecker enhances precision, facilitating the accurate extraction of absolute RGB values for absolute color measurement. Importantly, our method stands out for its cost-effectiveness, making it a practical choice for various applications. Furthermore, the in-house fabrication of the integrating sphere allowed for customization, enabling tailored sample staging and adjustments to the light input port at a reduced cost. This adaptability enhances the versatility of our technique, making it applicable to a broader range of scenarios.
While the use of an integrating sphere, which is traditionally associated with absolute measurements, might seem at odds with the comparative aspect introduced by employing a ColorChecker, it is important to note its significance. Integrating spheres are renowned for their precision through uniform illumination and total light collection, typically associated with absolute measurement techniques. However, when dealing with materials like silk cocoons characterized by their corrugated microstructure, this requires adopting a color calibration process, which differs from the usual procedure. This calibration is not a limitation but a vital step in ensuring accuracy and comparability amidst the inherent surface variability of materials like silk cocoons. By establishing a calibrated reference using ColorChecker, we can effectively address material-specific nuances, enabling consistent and reliable color measurements across diverse samples and varied conditions.