/usr/include/ossim/imaging/ossimCodecBase.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 | //----------------------------------------------------------------------------
//
// License: LGPL
//
// See LICENSE.txt file in the top level directory for more details.
//
// Description: class declaration for base codec(encoder/decoder).
//
//----------------------------------------------------------------------------
// $Id$
#ifndef ossimCodecBase_HEADER
#define ossimCodecBase_HEADER 1
#include <ossim/base/ossimObject.h>
#include <ossim/base/ossimPropertyInterface.h>
#include <ossim/imaging/ossimImageData.h>
class OSSIM_DLL ossimCodecBase
: public ossimObject, public ossimPropertyInterface
{
public:
/**
* Will return the identifier used to identify the codec type. For example the Jpeg codec
* will have "jpeg" as the identifier
*
* @return Codec identifier
*/
virtual ossimString getCodecType()const=0;
/**
* @brief Encode method.
*
* Pure virtual method that encodes the passed in buffer to this codec.
*
* @param in Input data to encode.
*
* @param out Encoded output data.
*
* @return true on success, false on failure.
*/
virtual bool encode( const ossimRefPtr<ossimImageData>& in,
std::vector<ossim_uint8>& out ) const=0;
/**
* @brief Decode method.
*
* @param in Input data to decode.
*
* @param out Output tile. If the pointer to ossimImageData is null
* internally it will be created. For code loops it is better to pre
* initialized to correct size.
*
* @note Caller should set "out's" image rectangle upon successful
* decode.
*
* @return true on success, false on failure.
*/
virtual bool decode( const std::vector<ossim_uint8>& in,
ossimRefPtr<ossimImageData>& out ) const=0;
virtual const std::string& getExtension() const=0;
};
#endif
|