image displaying through FPGA(BASYS3)
You are not allowed to use 'when' in that form in a process. 
Only in assignments outside.
(You can use 'when' with a case statement)

Also that code is rather unusual. How do you want to make an image of let's say 640x480 or 1024x768? 
You should store your image in a memory and then read it out using x, &amp; y for the address.