title: C#/WPF image handling problem
body: <p>I'm trying to make my C# code add an image to my (WPF) application's canvas. However, my code does not work.</p>
  
  <pre><code>Image I = new Image();
  I.Source = System.IO.File.Open(@"C:\Users\Public\Pictures\Sample Pictures\Penguins.jpg", System.IO.FileMode.Open);
  </code></pre>
  
  <p>I get the error:</p>
  
  <pre><code>Cannot implicitly convert type 'System.IO.FileStream' to 'System.Windows.Media.ImageSource'
  </code></pre>
  
  <p>I see why this is: The Image object wants the raw bitmap (or jpg or whatever), and my code is giving it an output stream from the file. How do I convert between the two?</p>