Issue 2139: extended camconst.json to handle raw crop

This commit is contained in:
torger
2013-12-18 14:27:57 +01:00
parent 803bef6b35
commit e90ab032f2
4 changed files with 147 additions and 13 deletions

6
rtengine/camconst.h Normal file → Executable file
View File

@@ -17,6 +17,8 @@ class CameraConst {
private:
Glib::ustring make_model;
short dcraw_matrix[12];
int raw_crop[4];
int raw_mask[8][4];
int white_max;
std::map<int, struct camera_const_levels> mLevels[2];
std::map<float, float> mApertureScaling;
@@ -32,6 +34,10 @@ class CameraConst {
bool has_dcrawMatrix(void);
void update_dcrawMatrix(const short *other);
const short *get_dcrawMatrix(void);
bool has_rawCrop(void);
void get_rawCrop(int& left_margin, int& top_margin, int& width, int& height);
bool has_rawMask(int idx);
void get_rawMask(int idx, int& top, int& left, int& bottom, int& right);
int get_BlackLevel(int idx, int iso_speed);
int get_WhiteLevel(int idx, int iso_speed, float fnumber);
void update_Levels(const CameraConst *other);