From: Oscar L. K. <osc...@sp...> - 2011-01-21 20:43:29
|
Jim, (Garrett, Dave, et. al.) That's OK. The transform is typically used when the image file is a sub-image of a larger image space or is rotated relative to its map projection. It provides a way of transforming the image file pixel into an x, y the map projection understands. Most of the time, the image file pixel x, y can be used directly in the map projection without a transform (hence the identity transform) We know there is a problem with GSD. Unfortunately the GSD computation is scattered all over the place. Sometimes the map projection computes it, other times the parent ImageGeometry object computes it, sometimes the sensor model (if available) computes it. And the GSD depends on where you compute it (center, edge, corner, average of all, etc.) This was the only way back when we didn't have the ossimImageGeometry class. But now that we do, we really need to consolidate a few things into the geom object. We need to discuss a plan for this and get it done. Oscar From: jim hopper [mailto:JAM...@sa...] Sent: Friday, January 21, 2011 14:25 To: oss...@li... Subject: [OSSIM] Identity transform? The small program below dumps the image geometry from a nitf frame file. The printout of the geometry has something I don't remember seeing before: type: ossimImageGeometry No transform defined. Using identity transform. m_projection: // ossimMapProjection::print type: ossimEquDistCylProjection Is this something that is new and expected, or does it mean I have something wrong in my program? best jim #include <iostream> #include <ossim/init/ossimInit.h> #include <ossim/elevation/ossimElevManager.h> #include <ossim/base/ossimKeywordlist.h> #include <ossim/imaging/ossimCibCadrgTileSource.h> #include <ossim/base/ossimIrect.h> #include <ossim/support_data/ossimInfoBase.h> #include <ossim/support_data/ossimInfoFactoryRegistry.h> #include "ossim/imaging/ossimImageHandlerRegistry.h" #include "ossim/imaging/ossimImageGeometry.h" int main (int argc, char *argv[]) { ossimElevManager::instance()->disableSource(); ossimInit::instance()->initialize(argc, argv); ossimRefPtr<ossimImageHandler> handler = ossimImageHandlerRegistry::instance()->open(ossimFilename(argv[1])); if(handler.valid()) { ossimIrect bounds = handler->getBoundingRect(0); ossimRefPtr<ossimImageGeometry>geom = handler->getImageGeometry(); cout << *geom << endl; } else { cout << "Unable to open image = " << argv[1] << endl; } return 0; } |