title: Leaflet.js Is Rotating Big Size Images
body: <p>I'm using Leaflet.js for putting markers on floor plans in my web app. But when I upload images that has big sizes (for example 2363*3390) to map control, it rotates image out of my control. When I change rotation of image from windows image viewer anything changes. Why leaflet rotates it automatically ?</p>
  
  <pre><code>    function LoadMap(_base64Data, boundHeight, boundWidth) {
          mapLoadCount = mapLoadCount + 1;
  
          var w = boundWidth,
              h = boundHeight,
              url = '';
  
          if (mapLoadCount == 1) {
              map = L.map('map', {
                  minZoom: 7,
                  maxZoom: 18,
                  center: [0, 0],
                  crs: L.CRS.Simple
              }).setView([50.4333, 30.5167], 16);
  
  
              var southWest = map.unproject([0, h], map.getMaxZoom() - 1);
              var northEast = map.unproject([w, 0], map.getMaxZoom() - 1);
              bounds = new L.LatLngBounds(southWest, northEast);
  
              overlay = L.imageOverlay(url, bounds);
              overlay.addTo(map);
  
              map.setMaxBounds(bounds);
  
              markerLayer = new L.FeatureGroup();
              deletedMarkers = new L.FeatureGroup();
              map.addLayer(markerLayer);
          }
          else {
              var southWest = map.unproject([0, h], map.getMaxZoom() - 1);
              var northEast = map.unproject([w, 0], map.getMaxZoom() - 1);
              bounds = new L.LatLngBounds(southWest, northEast);
  
              map.removeLayer(overlay);
  
              overlay = L.imageOverlay(_base64Data, bounds);
              overlay.addTo(map);
  
              map.setMaxBounds(bounds);
          }
      }
  </code></pre>