/usr/include/ossim/imaging/ossimGeneralRasterWriter.h is in libossim-dev 1.7.21-4.
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 | //*******************************************************************
// Copyright (C) 2001 ImageLinks Inc.
//
// License: See top level LICENSE.txt file.
//
// Author: David Burken
//
// Description:
//
// Contains class declaration for ossimGeneralRasterWriter.
//
//*******************************************************************
// $Id: ossimGeneralRasterWriter.h 9094 2006-06-13 19:12:40Z dburken $
#ifndef ossimGeneralRasterWriter_HEADER
#define ossimGeneralRasterWriter_HEADER
#include <ossim/imaging/ossimImageFileWriter.h>
#include <ossim/base/ossimIrect.h>
#include <ossim/base/ossimFilename.h>
#include <ossim/base/ossimKeywordlist.h>
#include <ossim/base/ossimKeyword.h>
class ossimGeneralRasterWriter : public ossimImageFileWriter
{
public:
ossimGeneralRasterWriter();
ossimGeneralRasterWriter(ossimImageSource* inputSource,
const ossimFilename& file=ossimFilename(""));
virtual ~ossimGeneralRasterWriter();
/**
* void getImageTypeList(std::vector<ossimString>& imageTypeList)const
*
* Appends this writer image types to list "imageTypeList".
*
* This writer has the following types:
* general_raster_bip
* general_raster_bil
* general_raster_bsq
*
* @param imageTypeList stl::vector<ossimString> list to append to.
*/
virtual void getImageTypeList(std::vector<ossimString>& imageTypeList)const;
virtual void set_rr_level(ossim_uint32 rr) { theRlevel = rr; }
virtual bool isOpen()const;
virtual bool open();
virtual void close();
/**
* saves the state of the object.
*/
virtual bool saveState(ossimKeywordlist& kwl,
const char* prefix=0)const;
/**
* Method to the load (recreate) the state of an object from a keyword
* list. Return true if ok or false on error.
*/
virtual bool loadState(const ossimKeywordlist& kwl,
const char* prefix=0);
private:
virtual bool writeFile();
/**
* Writes image data to output file in BIP(Band Interleaved by Pixel)
* format.
* @return true on success, false on error.
*/
bool writeToBip();
/**
* Writes image data to output file in BIL(Band Interleaved by Line)
* format.
* @return true on success, false on error.
*/
bool writeToBil();
/**
* Writes image data to output file in BSQ(Band Sequential) format.
* @return true on success, false on error.
*/
bool writeToBsq();
/**
* Writes an ossim header file which can be used to load file in ossim.
* Returns true on success, false on error.
*/
void writeHeader() const;
/**
* Writes an envi header file which can be used to load file in envi.
* If the output image file is "foo.ras" then the ossim header file will
* be "foo.hdr".
*/
void writeEnviHeader() const;
/**
* @return The interleave as a string of either: bil, bip, or bsq
*/
ossimString getInterleaveString() const;
std::ofstream theFileStream;
bool theOverviewFlag;
ossim_uint32 theRlevel;
ossimByteOrder theOutputByteOrder;
/**
* Populated while writting the data
*/
std::vector<double> theMinPerBand;
std::vector<double> theMaxPerBand;
TYPE_DATA
};
#endif
|