Commit 23242834 authored by Makayla Shepherd's avatar Makayla Shepherd
Browse files

Merged trunk into ipce

git-svn-id: http://subversion.wr.usgs.gov/repos/prog/isis3/branches/ipce@8291 41f8697f-d340-4b68-9986-7bafba869bb8
parents d22dee38 b4535440
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
@@ -77,7 +77,6 @@ libs:
	fi

license:
	echo $(CURTIMESTAMP) "  Obtaining licenses";                         \
	$(RSYNC) -a $(THIRDPARTYLICPATH)                                     \
	  $(ISISROOT)/3rdParty/license/

+22 −0
Original line number Diff line number Diff line
@@ -49,6 +49,28 @@ Group = ErrorFacility
  StackTrace = Off
EndGroup

########################################################
# Specify which ray-tracing engine to use for shape
# models.
# 
# Leave the ShapeModel Group commented-out to continue
# using the ISIS3 default. 
#
# RayTraceEngine = Bullet | Embree
# OnError = Continue | Fail
# Tolerance = { numerical value that will be set as the
#           tolerance for the Bullet or Embree shape
#           model } 
# 
########################################################

#Group = ShapeModel
#  RayTraceEngine = Embree
#  OnError = Continue
#  CubeSupported = False
#  Tolerance = DBL_MAX
#EndGroup

########################################################
# Customize how session logging is handled
#
+2 −2
Original line number Diff line number Diff line
@@ -172,9 +172,9 @@ JAMALIB =
#---------------------------------------------------------------------------
# Set up for GEOS
#---------------------------------------------------------------------------
GEOSINCDIR = -isystem $(ISIS3LOCAL)/include/geos/geos3.5.0
GEOSINCDIR = -isystem $(ISIS3LOCAL)/include/geos/geos3.5.1
GEOSLIBDIR = -L$(ISIS3LOCAL)/lib
GEOSLIB    = -lgeos-3.5.0 -lgeos_c
GEOSLIB    = -lgeos-3.5.1 -lgeos_c

#---------------------------------------------------------------------------
# Set up for the GNU Scientific Library (GSL).  Note that this setup
+66 −3
Original line number Diff line number Diff line
@@ -36,6 +36,7 @@ UniversalGroundMap *gmap;
int currentBand = 0;
bool recalculateForEachBand = false; 
bool walkBoundary = false;
bool extendGrid = false; 
Latitude minLat, maxLat;
Longitude minLon, maxLon;

@@ -54,6 +55,7 @@ void IsisMain() {

  outline = ui.GetBoolean("OUTLINE");
  ticks = ui.GetBoolean("TICKS");
  extendGrid = ui.GetBoolean("EXTENDGRID");

  if (ticks) {
    tickSize = ui.GetInteger("TICKSIZE") / 2;
@@ -130,7 +132,8 @@ void IsisMain() {

    gmap = new UniversalGroundMap(*icube, UniversalGroundMap::ProjectionFirst);

    latLonGrid = new GroundGrid(gmap, ticks, icube->sampleCount(), icube->lineCount());
    latLonGrid = new GroundGrid(gmap, ticks, extendGrid,
                                icube->sampleCount(), icube->lineCount());

    baseLat = Latitude(ui.GetDouble("BASELAT"),
        *latLonGrid->GetMappingGroup(), Angle::Degrees);
@@ -160,6 +163,35 @@ void IsisMain() {

    latLonGrid->SetGroundLimits(minLat, minLon, maxLat, maxLon);

    // If the grid is not going to reach the min/max lon warn the user.
    if (!extendGrid) {
      // Check that the min/max lon values match the lon domain
      if ( latLonGrid->GetMappingGroup()->findKeyword("LongitudeDomain")[0] == "360" &&
          (latLonGrid->minLongitude().degrees() < 0.0 ||
            latLonGrid->maxLongitude().degrees() > 360.0) ) {
        QString msg = "**WARNING** minimum longitude ["
                      + toString( latLonGrid->minLongitude().degrees() )
                      + "] and maximum longitude ["
                      + toString( latLonGrid->maxLongitude().degrees() )
                      + "] are not in the 360 degree longitude domain and "
                        "the EXTENDGRID parameter is set to false. "
                        "Output grid may not cover the entire map projection.";
        std::cerr << msg << std::endl;
      }
      else if ( latLonGrid->GetMappingGroup()->findKeyword("LongitudeDomain")[0] == "180" &&
                (latLonGrid->minLongitude().degrees() < -180.0 ||
                latLonGrid->maxLongitude().degrees() > 180.0) ) {
        QString msg = "**WARNING** minimum longitude ["
                      + toString( latLonGrid->minLongitude().degrees() )
                      + "] and maximum longitude ["
                      + toString( latLonGrid->maxLongitude().degrees() )
                      + "] are not in the 180 degree longitude domain and "
                        "the EXTENDGRID parameter is set to false. "
                        "Output grid may not cover the entire map projection.";
        std::cerr << msg << std::endl;
      }
    }

    latLonGrid->CreateGrid(baseLat, baseLon, latInc, lonInc, &progress);

    if (ui.GetBoolean("BOUNDARY")) {
@@ -313,10 +345,41 @@ void changeBand(int band){
  gmap->SetBand(band);

  //update latLonGrid to use new UniversalGroundMap
  latLonGrid = new GroundGrid(gmap, ticks, icube->sampleCount(), icube->lineCount());
  latLonGrid = new GroundGrid(gmap, ticks, extendGrid,
                              icube->sampleCount(), icube->lineCount());

  //re-set old ground limits from GUI
  latLonGrid->SetGroundLimits(minLat, minLon, maxLat, maxLon);
  // If the grid is not going to reach the min/max lon warn the user.
  if (!extendGrid) {
    // Check that the min/max lon values match the lon domain
    if ( latLonGrid->GetMappingGroup()->findKeyword("LongitudeDomain")[0] == "360" &&
        (latLonGrid->minLongitude().degrees() < 0.0 ||
          latLonGrid->maxLongitude().degrees() > 360.0) ) {
      QString msg = "**WARNING** minimum longitude ["
                    + toString( latLonGrid->minLongitude().degrees() )
                    + "] and maximum longitude ["
                    + toString( latLonGrid->maxLongitude().degrees() )
                    + "] are not in the 360 degree longitude domain and "
                      "the EXTENDGRID parameter is set to false. "
                      "Output grid may not cover the entire map projection for band["
                    + toString(band) + "].";
      std::cerr << msg << std::endl;
    }
    else if ( latLonGrid->GetMappingGroup()->findKeyword("LongitudeDomain")[0] == "180" &&
              (latLonGrid->minLongitude().degrees() < -180.0 ||
              latLonGrid->maxLongitude().degrees() > 180.0) ) {
      QString msg = "**WARNING** minimum longitude ["
                    + toString( latLonGrid->minLongitude().degrees() )
                    + "] and maximum longitude ["
                    + toString( latLonGrid->maxLongitude().degrees() )
                    + "] are not in the 180 degree longitude domain and "
                      "the EXTENDGRID parameter is set to false. "
                      "Output grid may not cover the entire map projection for band["
                    + toString(band) + "].";
      std::cerr << msg << std::endl;
    }
  }

  QString progressMessage = QString("Recalculating grid for band %1").arg(band);
  progress.SetText(progressMessage);
+15 −0
Original line number Diff line number Diff line
@@ -170,6 +170,9 @@
      Fixed error introduced in last change which caused grid to no longer work on multi-band 
      cubes without camera models (for example: a mosaic will not have a camera model.) Fixes #4586. 
    </change>
    <change name="Jesse Mapel" date="2017-06-26">
      Added a flag to extend the grid past the longitude domain boundary. Fixes #2185. 
    </change>
  </history>

  <groups>
@@ -279,6 +282,18 @@
          MINLON, and MAXLON.
        </description>
      </parameter>

      <parameter name="EXTENDGRID">
        <type>boolean</type>
        <default><item>false</item></default>
        <brief>If the grid should be extended past the longitude domain boundary.</brief>
        <description>
          If false, the grid will stop at the longitude domain boundary, -180
          to 180 or 0 to 360, if the minimum or maximum longitude values are
          outside of the domain range. If true, the grid will extend all the
          way to the minimum and maximum longitudes regardless of the domain.
        </description>
      </parameter>
    </group>

    <group name="Image Grid Parameters">
Loading