How about creating an 800x600 2D canvas, load the huge photo to an Image() object, drawImage() to the canvas at 800x600, then upload via toDataURL()?
TBH this seems to me to be more of a StackOverflow question than Ask HN though.
TBH this seems to me to be more of a StackOverflow question than Ask HN though.