/usr/include/ossim/imaging/ossimGridRemapSource.h is in libossim-dev 1.8.16-3+b1.
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 | //*****************************************************************************
// FILE: ossimGridRemapSource.h
//
// Copyright (C) 2001 ImageLinks, Inc.
//
// License: LGPL
//
// See LICENSE.txt file in the top level directory for more details.
//
// AUTHOR: Oscar Kramer
//
// DESCRIPTION: Contains declaration of class ossimGridRemapSource. This is
// a spacially variant remapper that utilizes a grid for interpolating the
// remap value given an image x, y.
//
// LIMITATIONS: None.
//
//*****************************************************************************
// $Id: ossimGridRemapSource.h 15766 2009-10-20 12:37:09Z gpotts $
#ifndef ossimGridRemapSource_HEADER
#define ossimGridRemapSource_HEADER
#include <ossim/imaging/ossimImageSourceFilter.h>
#include <vector>
#include <ossim/imaging/ossimGridRemapEngine.h>
#include <ossim/base/ossimFilename.h>
class ossimDblGrid;
class ossimDrect;
class ossimDpt;
class ossimImageData;
/*!****************************************************************************
*
* CLASS: ossimGridRemapSource
*
*****************************************************************************/
class ossimGridRemapSource : public ossimImageSourceFilter
{
public:
/*!
* Constructors:
*/
ossimGridRemapSource();
ossimGridRemapSource(ossimImageSource* inputSource,
ossimGridRemapEngine* engine);
/*!ossimAtbPointSource
* Initializes the remap engine. This object implements specific algorithms
* for interpreting the grids owned by this remapper. It actually performs
* the remapping.
*/
void setRemapEngine(ossimGridRemapEngine* engine);
/*!
* Provides access to the remap engine:
*/
ossimGridRemapEngine* getRemapEngine() { return theRemapEngine; }
/*!
* Permits initializing the remap grid after construction.
*/
virtual void initialize(const ossimDrect& uv_rect,
const ossimDpt& grid_spacing);
/*!
* Sets a node of the member grid to the value specified. The grid is flagged
* as unfilled.
*/
void setGridNode(const ossimDpt& view_pt,
const double* value);
/*!
* Implementation of virtual method to return remapped tile.
*/
virtual ossimRefPtr<ossimImageData> getTile(const ossimIrect& origin,
ossim_uint32 resLevel=0);
/*!
* Restore the state of the object from a keywordlist.
*/
virtual bool loadState(const ossimKeywordlist& kwl,
const char* prefix=0);
/*!
* Save the state of the object to a keywordlist.
*/
virtual bool saveState(ossimKeywordlist& kwl,
const char* prefix=0)const;
/*!
* Locks the image to prevent grid adjustment. The remapper continues to
* remap given the current grid (if enabled), but all target values computed
* are such that no change in the grids will occur in an adjsutment. If more
* than one overlapping image is locked, the target will may be influenced
* by all locked images, but the remap grids will not be updated.
*/
void lock() { theRemapIsLockedFlag = true; }
/*!
* Unlocks the grids for adjustment.
*/
void unlock() { theRemapIsLockedFlag = false; }
/*!
* Returns the status of the lock flag.
*/
bool isLocked() const { return theRemapIsLockedFlag; }
/*!
* Provides access to individual grids (pointer) given an index. Null pointer
* returned if index out of range.
*/
ossimDblGrid* getGrid(unsigned int index);
/*!
* Returns grid filename (may be empty)
*/
const ossimFilename& getGridFilename() const { return theGridFilename; }
/*!
* Sets the grid filename and initiates read.
*/
void setGridFilename(const ossimFilename& grid_filename);
protected:
virtual ~ossimGridRemapSource();
/*!
* Deallocates grid memory.
*/
void deallocateGrids();
vector<ossimDblGrid*> theGrids;
ossimFilename theGridFilename;
ossimGridRemapEngine* theRemapEngine;
bool theRemapIsLockedFlag;
bool theGridIsFilled;
TYPE_DATA
};
#endif
|