00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020 #ifndef __IMG_PLANE_INFO_H__
00021 #define __IMG_PLANE_INFO_H__
00022
00023 #include "IMG_API.h"
00024
00025 #include <SYS/SYS_Types.h>
00026 #include <UT/UT_String.h>
00027 #include <UT/UT_Rect.h>
00028
00029 #include "IMG_FileTypes.h"
00030
00031 class IMG_Stat;
00032
00033
00034
00035
00036
00037 class IMG_API IMG_Plane
00038 {
00039 public:
00040
00041
00042
00043 IMG_Plane();
00044 IMG_Plane(const IMG_Plane &p);
00045 IMG_Plane(const char *name, IMG_DataType dt, IMG_ColorModel cm,
00046 int index);
00047
00048
00049
00050
00051 void setName(const char *name);
00052 const char *getName() const;
00053
00054
00055
00056
00057 void setDataType(IMG_DataType dt);
00058 IMG_DataType getDataType() const;
00059
00060
00061
00062
00063
00064 void setColorModel(IMG_ColorModel cm);
00065 IMG_ColorModel getColorModel() const;
00066
00067
00068
00069
00070
00071 void setComponentNames(const char *c1,
00072 const char *c2=0,
00073 const char *c3=0,
00074 const char *c4=0,
00075 bool only_if_not_set = false);
00076 void setComponentName(int comp, const char *name);
00077
00078
00079 const char *getComponentName(int comp) const;
00080
00081
00082
00083
00084
00085
00086
00087
00088
00089 void setBlackWhitePoints(int64 b, int64 w);
00090 bool hasBlackWhitePoints() const;
00091 void getBlackWhitePoints(int64 &b, int64 &w) const;
00092
00093
00094
00095
00096 int getPixelSize() const;
00097
00098
00099
00100 int getPlaneIndex() const { return myIndex; }
00101
00102 private:
00103
00104 void setParentStat(IMG_Stat *stat) { myStat = stat; }
00105 void setPlaneIndex(int index) { myIndex = index; }
00106
00107
00108 UT_String myName;
00109 UT_String myComponentNames[4];
00110 int myIndex;
00111
00112 IMG_DataType myDataType;
00113 IMG_ColorModel myColorModel;
00114 int64 myBlackPoint;
00115 int64 myWhitePoint;
00116 IMG_Stat *myStat;
00117
00118 friend class IMG_Stat;
00119 };
00120
00121
00122
00123 #endif