# Recipe 34: Color replacement in a range / area

def turnRedInRange():
  brown = makeColor(57,16,8)
  file=r"/Users/abx/Computing/comp2720/2007/lectures/pics/alina.jpg"
  picture=makePicture(file)
  for x in range(70,168):
    for y in range(56,190):
      px=getPixel(picture,x,y)
      color = getColor(px)
      if distance(color,brown)<50.0:
        redness=getRed(px)*1.5
        setRed(px,redness)
  show(picture)
  return(picture)

