How to continue display From infrared to ultraviolet light using a TFTLCD

After I display a rainbow on TFTLCD using Due,
I have another awesome idea
dislay the full Visible spectrum from infrared to ultraviolet
this is my rainbow code
setColor_Red; for (int i=40; i<80; i++) myGLCD.drawLine(0, i, 479, i);
setColor_Orange; for (int i=80; i<120; i++) myGLCD.drawLine(0, i, 479, i);
setColor_Yellow; for (int i=120; i<160; i++) myGLCD.drawLine(0, i, 479, i);
setColor_Green; for (int i=160; i<200; i++) myGLCD.drawLine(0, i, 479, i);
setColor_Blue; for (int i=200; i<240; i++) myGLCD.drawLine(0, i, 479, i);
setColor_Indigo; for (int i=240; i<280; i++) myGLCD.drawLine(0, i, 479, i);
setColor_Violet; for (int i=280; i<320; i++) myGLCD.drawLine(0, i, 479, i);
How to improve this code to continue display Visible spectrum

My LCD is 480*320Pixes
I want to sample Visible spectrum by 320points to display continues
but what is the function between RGB value and Visible light

★function? Visible light(wavelength) -> RGBvalue