title: Cannot rotate imageBitmap creates error
body: <p>So I am attempting to rotate a picture taken with the rear facing camera and then rotating it. However when I attempt to rotate it it the app crashes.</p>
  
  <p>Code I am using to rotate the picture from file</p>
  
  <pre><code>private Bitmap rotatePhoto(File f)
  {
          bmp = BitmapFactory.decodeFile(f.getAbsolutePath());
          matrix = new Matrix();
          matrix.setRotate(270);
          bmp = Bitmap.createBitmap(bmp, 0, 0, bmp.getWidth(), bmp.getHeight(), matrix, true);
          return bmp;
  }
  </code></pre>
  
  <p>logcat</p>
  
  <pre><code>09-21 10:24:55.112: E/QCameraHWI_Parm(24875): android::status_t android::QCameraHardwareInterface::setFocusAreas(const android::CameraParameters&amp;): no autofocus support
  09-21 10:24:55.112: W/QCameraHWI_Parm(24875): Auto Focus 6
  09-21 10:24:55.112: E/QCameraHWI_Parm(24875):  auto exposure value: NULL
  09-21 10:24:57.174: W/QCameraHWI_Parm(24875): Auto Focus 0
  09-21 10:24:57.204: E/QCameraHWI_Parm(24875):  auto exposure value: NULL
  09-21 10:25:01.509: E/QCameraHWI_Parm(24875): android::status_t android::QCameraHardwareInterface::setFocusAreas(const android::CameraParameters&amp;): no autofocus support
  09-21 10:25:01.509: W/QCameraHWI_Parm(24875): Auto Focus 6
  09-21 10:25:01.509: E/QCameraHWI_Parm(24875):  auto exposure value: NULL
  09-21 10:25:03.791: I/dalvikvm(28721):   at com.example.autotakecamera.ImagePreview.rotatePhoto(ImagePreview.java:54)
  09-21 10:25:03.791: I/dalvikvm(28721):   at com.example.autotakecamera.ImagePreview.initUI(ImagePreview.java:46)
  09-21 10:25:03.791: I/dalvikvm(28721):   at com.example.autotakecamera.ImagePreview.onCreate(ImagePreview.java:29)
  09-21 10:25:03.801: E/AndroidRuntime(28721):    at com.example.autotakecamera.ImagePreview.rotatePhoto(ImagePreview.java:54)
  09-21 10:25:03.801: E/AndroidRuntime(28721):    at com.example.autotakecamera.ImagePreview.initUI(ImagePreview.java:46)
  09-21 10:25:03.801: E/AndroidRuntime(28721):    at com.example.autotakecamera.ImagePreview.onCreate(ImagePreview.java:29)
  </code></pre>