"

Cookies ussage consent

Our site saves small pieces of text information (cookies) on your device in order to deliver better content and for statistical purposes. You can disable the usage of cookies by changing the settings of your browser. By browsing our site without changing the browser settings you grant us permission to store that information on your device.

I agree, do not show this message again.

A computational framework for rendering sRGB color from physical light spectra

B. SARIKAVAK-LISESIVDIN1, S. B. LISESIVDIN1,*

Affiliation

  1. Gazi University, Faculty of Science, Department of Physics, 06500, Teknikokullar, Ankara, Türkiye

Abstract

This study introduces a computational method to convert any spectral power distribution (SPD) into its corresponding sRGB color, with practical applications in photonics, material science, and display engineering. Using Python libraries for numerical calculations, interpolation, and visualization, spectral data with the CIE color-matching functions were computed to derive tristimulus values. A matrix transformation from XYZ to the sRGB color space is then applied, followed by normalization and gamma correction to ensure precision. The method shows consistent results across various test spectra with different peak features. Four illustrative examples are provided to demonstrate the accuracy and adaptability of the approach..

Keywords

Spectral power distribution, CIE 1931 color space, XYZ to sRGB conversion.

Submitted at: Sept. 15, 2025
Accepted at: June 2, 2026

Citation

B. SARIKAVAK-LISESIVDIN, S. B. LISESIVDIN, A computational framework for rendering sRGB color from physical light spectra, Journal of Optoelectronics and Advanced Materials Vol. 28, Iss. 5-6, pp. 251-260 (2026)