title: How to flip and save Image
body: <p>My Image declaration:</p>
  
  <pre><code>ImageIcon imageIcon1 = new ImageIcon(main.class.getResource("image1.png"));
  Image image1 = imageIcon1.getImage();
  </code></pre>
  
  <p>How do I take image1, flip it along it's vertical axis and save it as another image?</p>
  
  <p>I have googled and every solution I have found has come with some type of casting error.
  Also, if there is a more efficient way to declare my image please let me know.</p>