rawdata.h

00001 /*
00002  * libopenraw - rawdata.h
00003  *
00004  * Copyright (C) 2007 Hubert Figuiere
00005  *
00006  * This library is free software; you can redistribute it and/or
00007  * modify it under the terms of the GNU Lesser General Public
00008  * License as published by the Free Software Foundation; either
00009  * version 2.1 of the License, or (at your option) any later version.
00010  *
00011  * This library is distributed in the hope that it will be useful,
00012  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00013  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00014  * Lesser General Public License for more details.
00015  *
00016  * You should have received a copy of the GNU Lesser General Public
00017  * License along with this library; if not, write to the Free Software
00018  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
00019  */
00020 
00021 
00022 #ifndef __OPENRAW_RAWDATA_H__
00023 #define __OPENRAW_RAWDATA_H__
00024 
00025 #include <vector>
00026 
00027 #include <libopenraw/libopenraw.h>
00028 #include <libopenraw++/bitmapdata.h>
00029 
00030 
00031 namespace OpenRaw {
00032 
00033     class RawData
00034         : public BitmapData
00035     {
00036     public:
00037         typedef or_cfa_pattern CfaPattern;
00038         static RawData * getAndExtractRawData(const char* filename, uint32_t options,
00039                                                                      or_error & err);
00040 
00041         RawData();
00042         virtual ~RawData();
00043 
00045         void swap(RawData & with);
00046 
00047         virtual void *allocData(const size_t s);
00048         virtual void setDimensions(uint32_t x, uint32_t y);
00049         void setCfaPattern(CfaPattern t);
00050         CfaPattern cfaPattern();
00051         uint32_t compression();
00052         void setCompression(uint32_t c);
00053 
00054         void setSlices(const std::vector<uint16_t> & slices);
00055 
00057 //      BitmapData &append(uint8_t c);
00059         RawData &append(uint16_t c);
00061         void nextRow();
00062     private:
00063         class Private;
00064         RawData::Private *d;
00065 
00067         RawData(const RawData& f);
00069         RawData & operator=(const RawData&);
00070     };
00071 
00072 }
00073 
00074 #endif

Generated on Tue Jun 17 11:47:19 2008 for libopenraw by  doxygen 1.5.6