This file is indexed.

/usr/include/ossim/projection/ossimCoarseGridModel.h is in libossim-dev 2.2.2-1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
//*****************************************************************************
// FILE: ossimCoarseGridModel.h
//
// Copyright (C) 2001 ImageLinks, Inc.
//
// License:  MIT
// 
// See LICENSE.txt file in the top level directory for more details.
//
// AUTHOR: Oscar Kramer
//
// DESCRIPTION:
//   Contains declaration of class ossimCoarseGridModel. This is an
//   implementation of an interpolation sensor model.
//
//*****************************************************************************
//  $Id: ossimCoarseGridModel.h 22825 2014-07-07 23:14:52Z dburken $

#ifndef ossimCoarseGridModel_HEADER
#define ossimCoarseGridModel_HEADER 1

#include <ossim/projection/ossimSensorModel.h>
#include <ossim/base/ossimIpt.h>
#include <ossim/base/ossimDblGrid.h>
#include <ossim/base/ossimFilename.h>

class ossimImageGeometry;

/******************************************************************************
 *
 * CLASS:  ossimCoarseGridModel
 *
 *****************************************************************************/
class OSSIMDLLEXPORT ossimCoarseGridModel : public ossimSensorModel
{
public:
   ossimCoarseGridModel();
   ossimCoarseGridModel(const ossimCoarseGridModel& copy_this);

   /** Accepts name of geometry file. This can be either MET ECG geom file, or
    * OSSIM keywordlist geometry file.*/
   ossimCoarseGridModel(const ossimFilename& geom_file);

   /** Accepts OSSIM keywordlist geometry file. */
   ossimCoarseGridModel(const ossimKeywordlist& geom_kwl);
   
   ~ossimCoarseGridModel();

   /** This method will build a grid from any projector. The accuracy of the grid can be
    * controlled by the static method setInterpolationError().
    * @param imageBounds Must be the image space bounds for the projection.
    * @param proj The projector that will be used to approximate a bilinear grid over. */
   virtual void buildGrid(const ossimDrect& imageBounds,
                          ossimProjection* proj,
                          double heightDelta=500.0,
                          bool enableHeightFlag=false,
                          bool makeAdjustableFlag=true);
   virtual void buildGrid(const ossimDrect& imageBounds,
                          ossimImageGeometry* geom,
                          double heightDelta=500.0,
                          bool enableHeightFlag=false,
                          bool makeAdjustableFlag=true);
   
   /** This is used when building a grid from a projector. You can set the interpolation error.
    * The default is subpixel accuracy (within .1 of a pixel). */
   static void setInterpolationError(double error=.1);
   static void setMinGridSpacing(ossim_int32 minSpacing = 100);

   /** Extends base-class implementation. Dumps contents of object to ostream. */
   virtual std::ostream& print(std::ostream& out) const;
   
   /** Fulfills ossimObject base-class pure virtuals. Saves geometry KWL files.
    * @return Returns true if successful. */
   virtual bool saveState(ossimKeywordlist& kwl, const char* prefix=0) const;

   /** Fulfills ossimObject base-class pure virtuals. Loads geometry KWL files.
    * @return Returns true if successful. */
   virtual bool loadState(const ossimKeywordlist& kwl, const char* prefix=0);

   /** Writes a template of geometry keywords processed by loadState and
    * saveState to output stream. */
   static void writeGeomTemplate(ostream& os);

   /** Returns pointer to a new instance, copy of this. */
   virtual ossimObject* dup() const { return new ossimCoarseGridModel(*this); }
   
   /** Saves the coarse grid to the specified file.
    * @return Returns true if successful. */
   bool saveCoarseGrid(const ossimFilename& cgFileName) const;

   /** Loads the coarse grid from the specified file.
    * @return Returns true if successful. */
   bool loadCoarseGrid(const ossimFilename& cgFileName);

   virtual void imagingRay(const ossimDpt& image_point, ossimEcefRay& image_ray) const;

   
   virtual void lineSampleToWorld(const ossimDpt& image_point, ossimGpt& gpt) const;

   /** This is the virtual that performs the actual work of projecting the image point
    * to the earth at some specified elevation. */
   virtual void lineSampleHeightToWorld(const ossimDpt& image_point,
                                        const double&   heightEllipsoid,
                                        ossimGpt&       world_pt) const;

   virtual void initAdjustableParameters();

   /*!
    * ossimOptimizableProjection
    */
   inline virtual bool useForward()const {return false;} //!image to ground faster

   /** Overrides base ossimSensorModel::isAffectedByElevation method.
    * @return true if height enabled, false if not. */
   virtual bool isAffectedByElevation() const;
   
protected:

   /** Deletes existing allocated memory and reallocates
    * new space. This may happen if a new grid is loaded over an existing one. */
   void reallocateGrid(const ossimIpt& size);
   
   //! Initializes base class data members after grids have been assigned.
   void initializeModelParams(ossimIrect irect);

   //! Implements its own extrapolation since this can be handled by ossimDblGrid.
   virtual ossimGpt extrapolate (const ossimDpt& imgPt, const double& height=ossim::nan()) const;

   mutable ossimFilename theGridFilename;
   ossimDblGrid  theLatGrid;         // degrees
   ossimDblGrid  theLonGrid;         // degrees
   ossimDblGrid  theDlatDhGrid;      // degrees/meter
   ossimDblGrid  theDlonDhGrid;      // degrees/meter
   ossimDblGrid* theDlatDparamGrid;  // degrees/(units-of-param)
   ossimDblGrid* theDlonDparamGrid;  // degrees/(units-of-param)

   static double       theInterpolationError;
   static ossim_int32  theMinGridSpacing;
   ossimAdjustmentInfo theInitialAdjustment;
   bool                theHeightEnabledFlag;
   
   TYPE_DATA
};

#endif