title: Change color of a single pixel - Golang image
body: <p>I want to open jpeg image file, encode it, change some pixel colors, and then save it back as it was.</p>
  
  <p>I'd like to do something like this</p>
  
  <pre><code>imgfile, err := os.Open("unchanged.jpeg")
  defer imgfile.Close()
  if err != nil {
      fmt.Println(err.Error())
  }
  
  img,err := jpeg.Decode(imgfile)
  if err != nil {
      fmt.Println(err.Error())
  }
  img.Set(0, 0, color.RGBA{85, 165, 34, 1})
  img.Set(1,0,....)
  
  outFile, _ := os.Create("changed.jpeg")
  defer outFile.Close()
  jpeg.Encode(outFile, img, nil)
  </code></pre>
  
  <p>I just can't come up with a working solution, since default image type that I get after encoding image-file doesn't have Set method.</p>
  
  <p>Can anyone explain how to do this? Thanks a lot.</p>