Loading isis/src/hayabusa/apps/amica2isis/amica2isis.cpp +19 −0 Original line number Diff line number Diff line Loading @@ -4,6 +4,7 @@ #include <QString> #include <algorithm> #include "AlphaCube.h" #include "Brick.h" #include "FileName.h" #include "ImportFits.h" Loading Loading @@ -144,6 +145,24 @@ void IsisMain () OriginalLabel oldLabel(label); outcube->write(oldLabel); // Check for subimage and create an AlphaCube that describes thes subarea and // update the cube labels. DO NOT adjust for scale. Camera model will handle // that. Coordinates in label are 0-based. if ( (1024 != nsamps) || (1024 != nlines) ) { PvlGroup inst = outLabel.findGroup("Instrument",Pvl::Traverse); int starting_samp = (int) inst["FirstSample"] + 1; int starting_line = (int) inst["FirstLine"] + 1; int ending_samp = (int) inst["LastSample"] + 1; int ending_line = (int) inst["LastLine"] + 1; AlphaCube subarea(1024, 1024, nsamps, nlines, starting_samp - 0.5, starting_line - 0.5, ending_samp + 0.5, ending_line + 0.5); subarea.UpdateGroup(*outcube); } // All done... p.EndProcess(); } Loading isis/src/hayabusa/apps/amica2isis/amica2isis.xml +5 −0 Original line number Diff line number Diff line Loading @@ -199,6 +199,11 @@ <change name="Kris Becker" date="2013-11-27"> Original version </change> <change name="Kris Becker" date="2014-04-03"> Added support for subimage areas. This was done by using the AlphaCube (or crop) feature which provides necessary elements for the AMICA camera model to work properly. Fixes #2056. </change> </history> <category> Loading isis/src/hayabusa/apps/amica2isis/tsts/subimage/Makefile 0 → 100644 +8 −0 Original line number Diff line number Diff line APPNAME = amica2isis include $(ISISROOT)/make/isismake.tsts commands: $(APPNAME) from=$(INPUT)/st_2489244561_v.lbl \ to=$(OUTPUT)/st_2489244561_v.cub > /dev/null catlab from=$(OUTPUT)/st_2489244561_v.cub to=$(OUTPUT)/st_2489244561_v.pvl > /dev/null; Loading
isis/src/hayabusa/apps/amica2isis/amica2isis.cpp +19 −0 Original line number Diff line number Diff line Loading @@ -4,6 +4,7 @@ #include <QString> #include <algorithm> #include "AlphaCube.h" #include "Brick.h" #include "FileName.h" #include "ImportFits.h" Loading Loading @@ -144,6 +145,24 @@ void IsisMain () OriginalLabel oldLabel(label); outcube->write(oldLabel); // Check for subimage and create an AlphaCube that describes thes subarea and // update the cube labels. DO NOT adjust for scale. Camera model will handle // that. Coordinates in label are 0-based. if ( (1024 != nsamps) || (1024 != nlines) ) { PvlGroup inst = outLabel.findGroup("Instrument",Pvl::Traverse); int starting_samp = (int) inst["FirstSample"] + 1; int starting_line = (int) inst["FirstLine"] + 1; int ending_samp = (int) inst["LastSample"] + 1; int ending_line = (int) inst["LastLine"] + 1; AlphaCube subarea(1024, 1024, nsamps, nlines, starting_samp - 0.5, starting_line - 0.5, ending_samp + 0.5, ending_line + 0.5); subarea.UpdateGroup(*outcube); } // All done... p.EndProcess(); } Loading
isis/src/hayabusa/apps/amica2isis/amica2isis.xml +5 −0 Original line number Diff line number Diff line Loading @@ -199,6 +199,11 @@ <change name="Kris Becker" date="2013-11-27"> Original version </change> <change name="Kris Becker" date="2014-04-03"> Added support for subimage areas. This was done by using the AlphaCube (or crop) feature which provides necessary elements for the AMICA camera model to work properly. Fixes #2056. </change> </history> <category> Loading
isis/src/hayabusa/apps/amica2isis/tsts/subimage/Makefile 0 → 100644 +8 −0 Original line number Diff line number Diff line APPNAME = amica2isis include $(ISISROOT)/make/isismake.tsts commands: $(APPNAME) from=$(INPUT)/st_2489244561_v.lbl \ to=$(OUTPUT)/st_2489244561_v.cub > /dev/null catlab from=$(OUTPUT)/st_2489244561_v.cub to=$(OUTPUT)/st_2489244561_v.pvl > /dev/null;