#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/stat.h>
#include <errno.h>
#include <ctype.h>
#include <math.h>
#include <limits.h>
#include "../include/jhead.h"
#include "../include/clens.h"
Classes | |
struct | Data1 |
Measurement of 35mm film format diagonal. More... | |
Functions | |
double | getHfov (double foc) |
Calculate the Horizontal Field Of View (HFOV) for a given focal length, width, height, and multiplier. | |
void | coefD () |
Calculate coefficient "d". Result put into the global variable coef1.d. | |
int | getCoefs () |
Calculate the lens correction coefficients (a,b,c) for a particular focal length of a particular lens by linear interpolation of known coefficients for the lens. The global variable "thisLens" must be pointing to the lens of interest. | |
double | rad (double x) |
Convert degrees to radians. | |
double | deg (double x) |
Convert radians to degrees. | |
int | prepareScript (char *inFile) |
Write the script the stitching program will use to warp the image (ie remove the lens distortion). | |
Variables | |
const double | diag35 = 43.266615 |
Measurement of 35mm film format diagonal. | |
Data1 | coef1 |
Holds hfov and correction coefficients for current image. | |
ExifInfo | exif |
Data structure to hold EXIF information. | |
CamNode | pCurCam |
Current camera being read in from profiles. | |
prefType | pref |
Data structure to hold program preferences. | |
CoefType | coef [] |
Array of lens correction coefficient data types. | |
LnsNode * | thisLens |
Pointer to lens for current correction. | |
CamNode * | thisCamera |
Pointer to camera for current correction. |
|
Convert radians to degrees.
|
|
Calculate the lens correction coefficients (a,b,c) for a particular focal length of a particular lens by linear interpolation of known coefficients for the lens. The global variable "thisLens" must be pointing to the lens of interest.
|
|
Calculate the Horizontal Field Of View (HFOV) for a given focal length, width, height, and multiplier.
|
|
Write the script the stitching program will use to warp the image (ie remove the lens distortion).
|
|
Convert degrees to radians.
|
|
Measurement of 35mm film format diagonal. if assuming 23.3 x 35 (phil's web site) then diag35 = 42.046284 if assuming 36 x 24 diag35 = 43.266615 |