dim x as double dim y as double dim z as double dim d as integer dim yellow as double dim cyan as double dim mag as double dim r as integer dim g as integer dim b as integer dim m as double dim n as double dim p as double dim q as integer d = 140 'decrease this number from 255 to 0 to look at darker colors q = 0 'change this from 1 to 0 to go from CYM to BYR color space screen 18, 32 window (-1,1)-(1,-1) for x = 0 to 1 step .0005 for y = 0 to 1 step .0005 b = d r = int(d-y*d) g = int(d-x*d) 'color rgb(r,g,b) m = 255 - r n = 2*255 - m - 2*g p = 2*255 - n - 2*b if (m>=0 and n >=0 and p >=0) or q = 1 then color rgb(r,g,b) pset (y,-x) else color rgb (0,0,0) 'color rgb(r,g,b) end if if q = 1 then color rgb(r,g,b) 'pset (y,-x) next next for x = 0 to 1 step .0005 for z = 0 to 1 step .0005 b = int(d-z*d) r = d g = int(d-x*d) m = 255 - r n = 2*255 - m - 2*g p = 2*255 - n - 2*b if (m>=0 and n >=0 and p >=0) or q = 1 then color rgb(r,g,b) pset (-x,z) else color rgb (0,0,0) 'color rgb(r,g,b) end if if q = 1 then color rgb(r,g,b) 'pset (-x,z) next next for y = 0 to 1 step .0005 for z = 0 to 1 step .0005 b = int(d-z*d) r = int(d-y*d) g = d 'color rgb(r,g,b) 'm = 255 - r 'n = 255 - m - g 'p = 255 - n - b m = 255 - r n = 2*255 - m - 2*g p = 2*255 - n - 2*b if (m>=0 and n >=0 and p >=0) or q = 1 then color rgb(r,g,b) pset (y,z) else 'color rgb(r,g,b) color rgb (0,0,0) end if if q = 1 then color rgb(r,g,b) 'pset (y,z) next next do loop while inkey = ""