From 0e52247373acad9572440624c41846efd3a573d1 Mon Sep 17 00:00:00 2001 From: Johannes Hofmann Date: Fri, 27 Oct 2006 22:18:48 +0200 Subject: add initial ImageMetaData classes --- src/ImageMetaData.H | 56 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 src/ImageMetaData.H (limited to 'src/ImageMetaData.H') diff --git a/src/ImageMetaData.H b/src/ImageMetaData.H new file mode 100644 index 0000000..79495f4 --- /dev/null +++ b/src/ImageMetaData.H @@ -0,0 +1,56 @@ +// +// Copyright 2006 by Johannes Hofmann +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU General Public +// License as published by the Free Software Foundation; either +// version 2 of the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Library General Public License for more details. +// +// You should have received a copy of the GNU Library General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 +// USA. +// + +#ifndef IMAGE_META_DATA_H +#define IMAGE_META_DATA_H + +class ImageMetaData { + protected: + double longitude; + double latitude; + double height; + double direction; + double nick; + double tilt; + double focallength_sensor_ratio; + int projection_type; + + public: + virtual int load_image(const char *name); + virtual int save_image(const char *name); + + double get_longitude(); + double get_latitude(); + double get_height(); + double get_direction(); + double get_nick(); + double get_tilt(); + double get_focallength_sensor_ratio(); + int get_projection_type(); + + void set_longitude(double v); + void set_latitude(double v); + void set_height(double v); + void set_direction(double v); + void set_nick(double v); + void set_tilt(double v); + void set_focallength_sensor_ratio(double v); + int set_projection_type(int v); +}; +#endif -- cgit v1.2.3 From 8e2ebc4de19e6956549413a599f6e27daa498303 Mon Sep 17 00:00:00 2001 From: Johannes Hofmann Date: Fri, 27 Oct 2006 23:24:13 +0200 Subject: implement ImageMetaData classes --- src/ExifImageMetaData.H | 25 ++---------- src/ExifImageMetaData.cxx | 70 ++++++++++++++++++++++++++++++++++ src/ImageMetaData.H | 6 ++- src/JpgcomImageMetaData.H | 30 +++------------ src/JpgcomImageMetaData.cxx | 93 +++++++++++++++++++++++++++++++++++++++++++++ 5 files changed, 177 insertions(+), 47 deletions(-) create mode 100644 src/ExifImageMetaData.cxx create mode 100644 src/JpgcomImageMetaData.cxx (limited to 'src/ImageMetaData.H') diff --git a/src/ExifImageMetaData.H b/src/ExifImageMetaData.H index b959dd3..bc567ff 100644 --- a/src/ExifImageMetaData.H +++ b/src/ExifImageMetaData.H @@ -20,27 +20,10 @@ #ifndef EXIF_IMAGE_META_DATA_H #define EXIF_IMAGE_META_DATA_H -class ExifImageMetaData { - ExifImageMetaData(); +#include "ImageMetaData.H" - virtual int load_image(const char *name); - - virtual double get_longitude(); - virtual double get_latitude(); - virtual double get_height(); - virtual double get_direction(); - virtual double get_nick(); - virtual double get_tilt(); - virtual double get_focallength_sensor_ratio(); - virtual int get_projection_type(); - - virtual void set_longitude(double v); - virtual void set_latitude(double v); - virtual void set_height(double v); - virtual void set_direction(double v); - virtual void set_nick(double v); - virtual void set_tilt(double v); - virtual void set_focallength_sensor_ratio(double v); - virtual int set_projection_type(int v); +class ExifImageMetaData : ImageMetaData { + virtual int load_image(char *name); + virtual int save_image(char *name); }; #endif diff --git a/src/ExifImageMetaData.cxx b/src/ExifImageMetaData.cxx new file mode 100644 index 0000000..05a43d5 --- /dev/null +++ b/src/ExifImageMetaData.cxx @@ -0,0 +1,70 @@ +// +// Copyright 2006 by Johannes Hofmann +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Library General Public +// License as published by the Free Software Foundation; either +// version 2 of the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Library General Public License for more details. +// +// You should have received a copy of the GNU Library General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 +// USA. +// + +#include +#include +#include + +#include "util.h" + +#include "ExifImageMetaData.H" + +#define FOCAL_LENGTH_IN_35MM_FILM 0xa405 + +int +ExifImageMetaData::load_image(char *name) { + char * args[32]; + FILE *p; + pid_t pid; + int status; + char buf[1024]; + char val[1024]; + int id; + + args[0] = "exif"; + args[1] = "-i"; + args[2] = "-m"; + args[3] = name; + args[4] = NULL; + + p = pexecvp(args[0], args, &pid, "r"); + + if (p) { + while (fgets(buf, sizeof(buf), p) != NULL) { + if (sscanf(buf, "%d\t%s", &id, val) != 2) { + continue; + } + + switch(id) { + case FOCAL_LENGTH_IN_35MM_FILM: + focallength_sensor_ratio = atof(val) / 35; + break; + } + } + } + + fclose(p); + waitpid(pid, &status, 0); + if (WEXITSTATUS(status) == 127 || WEXITSTATUS(status) == 126) { + fprintf(stderr, "%s not found\n", args[0]); + } + + return 0; +} + diff --git a/src/ImageMetaData.H b/src/ImageMetaData.H index 79495f4..3349cab 100644 --- a/src/ImageMetaData.H +++ b/src/ImageMetaData.H @@ -32,8 +32,10 @@ class ImageMetaData { int projection_type; public: - virtual int load_image(const char *name); - virtual int save_image(const char *name); + ImageMetaData(); + + virtual int load_image(char *name); + virtual int save_image(char *name); double get_longitude(); double get_latitude(); diff --git a/src/JpgcomImageMetaData.H b/src/JpgcomImageMetaData.H index bb701b5..3d063c6 100644 --- a/src/JpgcomImageMetaData.H +++ b/src/JpgcomImageMetaData.H @@ -17,31 +17,13 @@ // USA. // -#ifndef IMAGE_META_DATA_H -#define IMAGE_META_DATA_H +#ifndef JPGCOM_IMAGE_META_DATA_H +#define JPGCOM_IMAGE_META_DATA_H -class ImageMetaData { - ImageMetaData(); - - virtual int load_image(const char *name); - - virtual double get_longitude(); - virtual double get_latitude(); - virtual double get_height(); - virtual double get_direction(); - virtual double get_nick(); - virtual double get_tilt(); - virtual double get_focallength_sensor_ratio(); - virtual int get_projection_type(); - - virtual void set_longitude(double v); - virtual void set_latitude(double v); - virtual void set_height(double v); - virtual void set_direction(double v); - virtual void set_nick(double v); - virtual void set_tilt(double v); - virtual void set_focallength_sensor_ratio(double v); - virtual int set_projection_type(int v); +#include "ImageMetaData.H" +class JpgcomImageMetaData : ImageMetaData { + virtual int load_image(char *name); + virtual int save_image(char *name); }; #endif diff --git a/src/JpgcomImageMetaData.cxx b/src/JpgcomImageMetaData.cxx new file mode 100644 index 0000000..39fb2b8 --- /dev/null +++ b/src/JpgcomImageMetaData.cxx @@ -0,0 +1,93 @@ +// +// Copyright 2006 by Johannes Hofmann +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Library General Public +// License as published by the Free Software Foundation; either +// version 2 of the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Library General Public License for more details. +// +// You should have received a copy of the GNU Library General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 +// USA. +// + +#include +#include +#include + +#include "util.h" + +#include "JpgcomImageMetaData.H" + +#define GIPFEL_FORMAT_1 "gipfel: longitude %lf, latitude %lf, height %lf, direction %lf, nick %lf, tilt %lf, scale %lf, projection type %d" +#define GIPFEL_FORMAT_2 "gipfel: longitude %lf, latitude %lf, height %lf, direction %lf, nick %lf, tilt %lf, focallength_sensor_ratio %lf, projection type %d" + +int +JpgcomImageMetaData::load_image(char *name) { + char * args[32]; + FILE *p; + pid_t pid; + int status; + char buf[1024]; + double lo, la, he, dir, ni, ti, fr; + int pt; + int ret = 1; + + args[0] = "rdjpgcom"; + args[1] = name; + args[2] = NULL; + + p = pexecvp(args[0], args, &pid, "r"); + + if (p) { + while (fgets(buf, sizeof(buf), p) != NULL) { + if (sscanf(buf, GIPFEL_FORMAT_2, + &lo, &la, &he, &dir, &ni, &ti, &fr, &pt) >= 7) { + + longitude = lo; + latitude = la; + height = he; + direction = dir; + nick = ni; + tilt = ti; + focallength_sensor_ratio = fr; + projection_type = pt; + + ret = 0; + + break; + } else if (sscanf(buf, GIPFEL_FORMAT_1, + &lo, &la, &he, &dir, &ni, &ti, &fr, &pt) >= 7) { + + longitude = lo; + latitude = la; + height = he; + direction = dir; + nick = ni; + tilt = ti; + focallength_sensor_ratio = fr; + projection_type = pt; + + ret = 2; // special return value for compatibility with + // old format + + break; + } + } + + fclose(p); + waitpid(pid, &status, 0); + if (WEXITSTATUS(status) == 127 || WEXITSTATUS(status) == 126) { + fprintf(stderr, "%s not found\n", args[0]); + } + } + + return ret; +} + -- cgit v1.2.3 From 3863aa643f604f17b79684093fd34e7a67b093fa Mon Sep 17 00:00:00 2001 From: Johannes Hofmann Date: Sat, 28 Oct 2006 00:03:29 +0200 Subject: fix ImageMetaData classes --- src/ExifImageMetaData.H | 2 +- src/ExifImageMetaData.cxx | 11 ++++++--- src/GipfelWidget.cxx | 58 ++++++++++++++++++++++----------------------- src/ImageMetaData.H | 2 +- src/ImageMetaData.cxx | 16 ++++++++++++- src/JpgcomImageMetaData.H | 2 +- src/JpgcomImageMetaData.cxx | 3 +++ src/Makefile.am | 2 +- 8 files changed, 58 insertions(+), 38 deletions(-) (limited to 'src/ImageMetaData.H') diff --git a/src/ExifImageMetaData.H b/src/ExifImageMetaData.H index bc567ff..dd17871 100644 --- a/src/ExifImageMetaData.H +++ b/src/ExifImageMetaData.H @@ -22,7 +22,7 @@ #include "ImageMetaData.H" -class ExifImageMetaData : ImageMetaData { +class ExifImageMetaData : public ImageMetaData { virtual int load_image(char *name); virtual int save_image(char *name); }; diff --git a/src/ExifImageMetaData.cxx b/src/ExifImageMetaData.cxx index 05a43d5..1ba215e 100644 --- a/src/ExifImageMetaData.cxx +++ b/src/ExifImageMetaData.cxx @@ -47,13 +47,13 @@ ExifImageMetaData::load_image(char *name) { if (p) { while (fgets(buf, sizeof(buf), p) != NULL) { - if (sscanf(buf, "%d\t%s", &id, val) != 2) { + if (sscanf(buf, "%x\t%s", &id, val) != 2) { continue; } - + switch(id) { case FOCAL_LENGTH_IN_35MM_FILM: - focallength_sensor_ratio = atof(val) / 35; + focallength_sensor_ratio = atof(val) / 35.0; break; } } @@ -68,3 +68,8 @@ ExifImageMetaData::load_image(char *name) { return 0; } + +int +ExifImageMetaData::save_image(char *name) { +} + diff --git a/src/GipfelWidget.cxx b/src/GipfelWidget.cxx index 75451ec..8314222 100644 --- a/src/GipfelWidget.cxx +++ b/src/GipfelWidget.cxx @@ -35,6 +35,8 @@ #include #include +#include "ExifImageMetaData.H" +#include "JpgcomImageMetaData.H" #include "Fl_Search_Chooser.H" #include "choose_hill.H" #include "util.h" @@ -76,14 +78,9 @@ GipfelWidget::GipfelWidget(int X,int Y,int W, int H): Fl_Widget(X, Y, W, H) { int GipfelWidget::load_image(char *file) { - char * args[32]; - FILE *p; - pid_t pid; - char buf[1024]; - double lo, la, he, dir, ni, ti, sc; - int status; - Projection::Projection_t pt = Projection::TANGENTIAL; Fl_Image *new_img; + ImageMetaData *md; + int ret; new_img = new Fl_JPEG_Image(file); @@ -112,32 +109,33 @@ GipfelWidget::load_image(char *file) { mb->add("Center Peak", 0, (Fl_Callback*) center_cb, this); // try to retrieve gipfel data from JPEG comment section - args[0] = "rdjpgcom"; - args[1] = file; - args[2] = NULL; - - p = pexecvp(args[0], args, &pid, "r"); - if (p) { - while (fgets(buf, sizeof(buf), p) != NULL) { - if (sscanf(buf, GIPFEL_FORMAT, &lo, &la, &he, &dir, &ni, &ti, &sc, &pt) >= 7) { - set_view_long(lo); - set_view_lat(la); - set_view_height(he); - set_center_angle(dir); - set_nick_angle(ni); - set_tilt_angle(ti); - set_scale(sc); - set_projection(pt); - - break; - } + md = new JpgcomImageMetaData(); + ret = md->load_image(file); + if (ret != 1) { + set_view_long(md->get_longitude()); + set_view_lat(md->get_latitude()); + set_view_height(md->get_height()); + set_center_angle(md->get_direction()); + set_nick_angle(md->get_nick()); + set_tilt_angle(md->get_tilt()); + set_projection((Projection::Projection_t) md->get_projection_type()); + if (ret == 2) { // special compatibility return code for old format + set_scale(md->get_focallength_sensor_ratio()); + } else { + set_scale(md->get_focallength_sensor_ratio() * img->w()); } - fclose(p); - waitpid(pid, &status, 0); - if (WEXITSTATUS(status) == 127 || WEXITSTATUS(status) == 126) { - fprintf(stderr, "%s not found\n", args[0]); + } + + delete md; + + if (ret == 1) { + md = new ExifImageMetaData(); + ret = md->load_image(file); + if (ret == 0) { + set_scale(md->get_focallength_sensor_ratio() * img->w()); } + delete md; } return 0; diff --git a/src/ImageMetaData.H b/src/ImageMetaData.H index 3349cab..1318e10 100644 --- a/src/ImageMetaData.H +++ b/src/ImageMetaData.H @@ -53,6 +53,6 @@ class ImageMetaData { void set_nick(double v); void set_tilt(double v); void set_focallength_sensor_ratio(double v); - int set_projection_type(int v); + void set_projection_type(int v); }; #endif diff --git a/src/ImageMetaData.cxx b/src/ImageMetaData.cxx index 0c868bd..745529b 100644 --- a/src/ImageMetaData.cxx +++ b/src/ImageMetaData.cxx @@ -33,6 +33,15 @@ ImageMetaData::ImageMetaData() { projection_type = -1; } +int +ImageMetaData::load_image(char *name) { + return 1; +} + +int +ImageMetaData::save_image(char *name) { + return 1; +} double ImageMetaData::get_longitude() { @@ -69,6 +78,10 @@ ImageMetaData::get_focallength_sensor_ratio() { return focallength_sensor_ratio; } +int +ImageMetaData::get_projection_type() { + return projection_type; +} void ImageMetaData::set_longitude(double v) { @@ -105,6 +118,7 @@ ImageMetaData::set_focallength_sensor_ratio(double v) { focallength_sensor_ratio = v; } -int ImageMetaData::set_projection_type(int v) { +void +ImageMetaData::set_projection_type(int v) { projection_type = v; } diff --git a/src/JpgcomImageMetaData.H b/src/JpgcomImageMetaData.H index 3d063c6..70e266e 100644 --- a/src/JpgcomImageMetaData.H +++ b/src/JpgcomImageMetaData.H @@ -22,7 +22,7 @@ #include "ImageMetaData.H" -class JpgcomImageMetaData : ImageMetaData { +class JpgcomImageMetaData : public ImageMetaData { virtual int load_image(char *name); virtual int save_image(char *name); }; diff --git a/src/JpgcomImageMetaData.cxx b/src/JpgcomImageMetaData.cxx index 39fb2b8..8dcd54e 100644 --- a/src/JpgcomImageMetaData.cxx +++ b/src/JpgcomImageMetaData.cxx @@ -91,3 +91,6 @@ JpgcomImageMetaData::load_image(char *name) { return ret; } +int +JpgcomImageMetaData::save_image(char *name) { +} diff --git a/src/Makefile.am b/src/Makefile.am index 4b54bc8..a730123 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -16,7 +16,7 @@ gipfel_SOURCES = \ OutputImage.cxx \ JPEGOutputImage.cxx \ TIFFOutputImage.cxx \ - PreviewOutputImage.cxx + PreviewOutputImage.cxx \ ImageMetaData.cxx \ JpgcomImageMetaData.cxx \ ExifImageMetaData.cxx -- cgit v1.2.3 From 20286c5a434580d38dc0a85981503d6310b9e55a Mon Sep 17 00:00:00 2001 From: Johannes Hofmann Date: Sat, 28 Oct 2006 00:36:32 +0200 Subject: move Jpeg header writing to JpgcomImageMetaData class update NEWS --- NEWS | 7 ++++ src/ExifImageMetaData.H | 2 +- src/ExifImageMetaData.cxx | 3 +- src/GipfelWidget.cxx | 82 +++++++++------------------------------------ src/ImageMetaData.H | 2 +- src/ImageMetaData.cxx | 2 +- src/JpgcomImageMetaData.H | 2 +- src/JpgcomImageMetaData.cxx | 69 +++++++++++++++++++++++++++++++++++++- 8 files changed, 96 insertions(+), 73 deletions(-) (limited to 'src/ImageMetaData.H') diff --git a/NEWS b/NEWS index 7a4cfa5..e672b42 100644 --- a/NEWS +++ b/NEWS @@ -1,5 +1,12 @@ gipfel ChangeLog ================= +gipfel-0.2.0 + - Change orientation format in jpeg header to make it independent + of the image size. One can now scale an already oriented image + without invalidating the orientation information. + - gipfel now tries to find a reasonable default for the scale value + when opening new images based on the "Focal Length In 35mm" Exif + tag, if it exists. gipfel-0.1.3 - Add stitching mode (gipfel -s). See README for details. diff --git a/src/ExifImageMetaData.H b/src/ExifImageMetaData.H index dd17871..f864b0f 100644 --- a/src/ExifImageMetaData.H +++ b/src/ExifImageMetaData.H @@ -24,6 +24,6 @@ class ExifImageMetaData : public ImageMetaData { virtual int load_image(char *name); - virtual int save_image(char *name); + virtual int save_image(char *in_img, char *out_img); }; #endif diff --git a/src/ExifImageMetaData.cxx b/src/ExifImageMetaData.cxx index 1ba215e..0de7478 100644 --- a/src/ExifImageMetaData.cxx +++ b/src/ExifImageMetaData.cxx @@ -70,6 +70,7 @@ ExifImageMetaData::load_image(char *name) { int -ExifImageMetaData::save_image(char *name) { +ExifImageMetaData::save_image(char *in_img, char *out_img) { + return 1; } diff --git a/src/GipfelWidget.cxx b/src/GipfelWidget.cxx index 8314222..33a3987 100644 --- a/src/GipfelWidget.cxx +++ b/src/GipfelWidget.cxx @@ -39,7 +39,6 @@ #include "JpgcomImageMetaData.H" #include "Fl_Search_Chooser.H" #include "choose_hill.H" -#include "util.h" #include "GipfelWidget.H" #define CROSS_SIZE 2 @@ -74,8 +73,6 @@ GipfelWidget::GipfelWidget(int X,int Y,int W, int H): Fl_Widget(X, Y, W, H) { fl_register_images(); } -#define GIPFEL_FORMAT "gipfel: longitude %lf, latitude %lf, height %lf, direction %lf, nick %lf, tilt %lf, scale %lf, projection type %d" - int GipfelWidget::load_image(char *file) { Fl_Image *new_img; @@ -108,8 +105,7 @@ GipfelWidget::load_image(char *file) { mb->box(FL_NO_BOX); mb->add("Center Peak", 0, (Fl_Callback*) center_cb, this); -// try to retrieve gipfel data from JPEG comment section - + // try to retrieve gipfel data from JPEG comment section md = new JpgcomImageMetaData(); ret = md->load_image(file); if (ret != 1) { @@ -148,79 +144,31 @@ GipfelWidget::get_image_filename() { int GipfelWidget::save_image(char *file) { - char * args[32]; - FILE *p, *out; - pid_t pid; - char buf[1024]; - int status; - size_t n; - struct stat in_stat, out_stat; + ImageMetaData *md; + int ret; if (img_file == NULL) { fprintf(stderr, "Nothing to save\n"); return 1; } - if (stat(img_file, &in_stat) != 0) { - perror("stat"); - return 1; - } - - if (stat(file, &out_stat) == 0) { - if (in_stat.st_ino == out_stat.st_ino) { - fprintf(stderr, "Input image %s and output image %s are the same file\n", - img_file, file); - return 1; - } - } + md = new JpgcomImageMetaData(); - out = fopen(file, "w"); - if (out == NULL) { - perror("fopen"); - return 1; - } + md->set_longitude(get_view_long()); + md->set_latitude(get_view_lat()); + md->set_height(get_view_height()); + md->set_direction(get_center_angle()); + md->set_nick(get_nick_angle()); + md->set_tilt(get_tilt_angle()); + md->set_focallength_sensor_ratio(get_scale() / (double) img->w()); + md->set_projection_type((int) get_projection()); - snprintf(buf, sizeof(buf), GIPFEL_FORMAT, - get_view_long(), - get_view_lat(), - get_view_height(), - get_center_angle(), - get_nick_angle(), - get_tilt_angle(), - get_scale(), - (int) get_projection()); - -// try to save gipfel data in JPEG comment section - args[0] = "wrjpgcom"; - args[1] = "-replace"; - args[2] = "-comment"; - args[3] = buf; - args[4] = img_file; - args[5] = NULL; - - p = pexecvp(args[0], args, &pid, "r"); - - if (p) { - while ((n = fread(buf, 1, sizeof(buf), p)) != 0) { - if (fwrite(buf, 1, n, out) != n) { - perror("fwrite"); - fclose(out); - fclose(p); - waitpid(pid, &status, 0); - } - } - fclose(p); - waitpid(pid, &status, 0); - if (WEXITSTATUS(status) == 127 || WEXITSTATUS(status) == 126) { - fprintf(stderr, "%s not found\n", args[0]); - } - } + ret = md->save_image(img_file, file); + delete md; - fclose(out); - return 0; + return ret; } - int GipfelWidget::load_data(const char *file) { int r; diff --git a/src/ImageMetaData.H b/src/ImageMetaData.H index 1318e10..637b758 100644 --- a/src/ImageMetaData.H +++ b/src/ImageMetaData.H @@ -35,7 +35,7 @@ class ImageMetaData { ImageMetaData(); virtual int load_image(char *name); - virtual int save_image(char *name); + virtual int save_image(char *in_img, char *out_img); double get_longitude(); double get_latitude(); diff --git a/src/ImageMetaData.cxx b/src/ImageMetaData.cxx index 745529b..5c54a17 100644 --- a/src/ImageMetaData.cxx +++ b/src/ImageMetaData.cxx @@ -39,7 +39,7 @@ ImageMetaData::load_image(char *name) { } int -ImageMetaData::save_image(char *name) { +ImageMetaData::save_image(char *in_img, char *out_img) { return 1; } diff --git a/src/JpgcomImageMetaData.H b/src/JpgcomImageMetaData.H index 70e266e..944833a 100644 --- a/src/JpgcomImageMetaData.H +++ b/src/JpgcomImageMetaData.H @@ -24,6 +24,6 @@ class JpgcomImageMetaData : public ImageMetaData { virtual int load_image(char *name); - virtual int save_image(char *name); + virtual int save_image(char *in_img, char *out_img); }; #endif diff --git a/src/JpgcomImageMetaData.cxx b/src/JpgcomImageMetaData.cxx index 8dcd54e..407b6af 100644 --- a/src/JpgcomImageMetaData.cxx +++ b/src/JpgcomImageMetaData.cxx @@ -19,7 +19,9 @@ #include #include +#include #include +#include #include "util.h" @@ -92,5 +94,70 @@ JpgcomImageMetaData::load_image(char *name) { } int -JpgcomImageMetaData::save_image(char *name) { +JpgcomImageMetaData::save_image(char *in_img, char *out_img) { + char * args[32]; + FILE *p, *out; + pid_t pid; + char buf[1024]; + int status; + size_t n; + struct stat in_stat, out_stat; + + if (stat(in_img, &in_stat) != 0) { + perror("stat"); + return 1; + } + + if (stat(out_img, &out_stat) == 0) { + if (in_stat.st_ino == out_stat.st_ino) { + fprintf(stderr, "Input image %s and output image %s are the same file\n", + in_img, out_img); + return 1; + } + } + + out = fopen(out_img, "w"); + if (out == NULL) { + perror("fopen"); + return 1; + } + + snprintf(buf, sizeof(buf), GIPFEL_FORMAT_2, + longitude, + latitude, + height, + direction, + nick, + tilt, + focallength_sensor_ratio, + projection_type); + + // try to save gipfel data in JPEG comment section + args[0] = "wrjpgcom"; + args[1] = "-replace"; + args[2] = "-comment"; + args[3] = buf; + args[4] = in_img; + args[5] = NULL; + + p = pexecvp(args[0], args, &pid, "r"); + + if (p) { + while ((n = fread(buf, 1, sizeof(buf), p)) != 0) { + if (fwrite(buf, 1, n, out) != n) { + perror("fwrite"); + fclose(out); + fclose(p); + waitpid(pid, &status, 0); + } + } + fclose(p); + waitpid(pid, &status, 0); + if (WEXITSTATUS(status) == 127 || WEXITSTATUS(status) == 126) { + fprintf(stderr, "%s not found\n", args[0]); + } + } + + fclose(out); + return 0; } -- cgit v1.2.3 From da5192170bb7ed19a8eadbc8ac393b0fa222c7df Mon Sep 17 00:00:00 2001 From: Johannes Hofmann Date: Mon, 30 Oct 2006 18:18:57 +0100 Subject: consolidate ExifImageMetaData and src/JpgcomImageMetaData into ImageMetaData --- src/ExifImageMetaData.H | 29 ------ src/ExifImageMetaData.cxx | 109 -------------------- src/GipfelWidget.cxx | 19 +--- src/ImageMetaData.H | 10 +- src/ImageMetaData.cxx | 242 ++++++++++++++++++++++++++++++++++++++++++-- src/JpgcomImageMetaData.H | 29 ------ src/JpgcomImageMetaData.cxx | 163 ----------------------------- src/Makefile.am | 6 +- src/gipfel.cxx | 3 +- 9 files changed, 247 insertions(+), 363 deletions(-) delete mode 100644 src/ExifImageMetaData.H delete mode 100644 src/ExifImageMetaData.cxx delete mode 100644 src/JpgcomImageMetaData.H delete mode 100644 src/JpgcomImageMetaData.cxx (limited to 'src/ImageMetaData.H') diff --git a/src/ExifImageMetaData.H b/src/ExifImageMetaData.H deleted file mode 100644 index f864b0f..0000000 --- a/src/ExifImageMetaData.H +++ /dev/null @@ -1,29 +0,0 @@ -// -// Copyright 2006 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// - -#ifndef EXIF_IMAGE_META_DATA_H -#define EXIF_IMAGE_META_DATA_H - -#include "ImageMetaData.H" - -class ExifImageMetaData : public ImageMetaData { - virtual int load_image(char *name); - virtual int save_image(char *in_img, char *out_img); -}; -#endif diff --git a/src/ExifImageMetaData.cxx b/src/ExifImageMetaData.cxx deleted file mode 100644 index 4002e97..0000000 --- a/src/ExifImageMetaData.cxx +++ /dev/null @@ -1,109 +0,0 @@ -// -// Copyright 2006 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// - -#include -#include -#include -#include - -#include "util.h" - -#include "ExifImageMetaData.H" - -#define FOCAL_LENGTH_IN_35MM_FILM 0xa405 -#define GPS_LATIITUDE 0x0002 -#define GPS_LONGITUDE 0x0004 -#define GPS_ALTITUDE 0x0006 - - -static double -degminsecstr2double(char *val) { - double ret, dv; - - ret = 0.0; - for (dv=1.0; dv <= 3600.0; dv = dv * 60.0) { - ret = ret + atof(val) / dv; - val = strchr(val, ','); - if (!val || val[1] == '\0') { - break; - } else { - val++; - } - } - - return ret; -} - - -int -ExifImageMetaData::load_image(char *name) { - char * args[32]; - FILE *p; - pid_t pid; - int status; - char buf[1024]; - char val[1024]; - int id; - - args[0] = "exif"; - args[1] = "-i"; - args[2] = "-m"; - args[3] = name; - args[4] = NULL; - - p = pexecvp(args[0], args, &pid, "r"); - - if (p) { - while (fgets(buf, sizeof(buf), p) != NULL) { - if (sscanf(buf, "%x\t%[^\n]\n", &id, val) != 2) { - continue; - } - - switch(id) { - case FOCAL_LENGTH_IN_35MM_FILM: - focallength_sensor_ratio = atof(val) / 35.0; - break; - case GPS_LONGITUDE: - longitude = degminsecstr2double(val); - break; - case GPS_LATIITUDE: - latitude = degminsecstr2double(val); - break; - case GPS_ALTITUDE: - height = atof(val); - break; - } - } - } - - fclose(p); - waitpid(pid, &status, 0); - if (WEXITSTATUS(status) == 127 || WEXITSTATUS(status) == 126) { - fprintf(stderr, "%s not found\n", args[0]); - } - - return 0; -} - - -int -ExifImageMetaData::save_image(char *in_img, char *out_img) { - return 1; -} - diff --git a/src/GipfelWidget.cxx b/src/GipfelWidget.cxx index b8ebc79..2efd231 100644 --- a/src/GipfelWidget.cxx +++ b/src/GipfelWidget.cxx @@ -35,8 +35,7 @@ #include #include -#include "ExifImageMetaData.H" -#include "JpgcomImageMetaData.H" +#include "ImageMetaData.H" #include "Fl_Search_Chooser.H" #include "choose_hill.H" #include "GipfelWidget.H" @@ -106,7 +105,7 @@ GipfelWidget::load_image(char *file) { mb->add("Center Peak", 0, (Fl_Callback*) center_cb, this); // try to retrieve gipfel data from JPEG comment section - md = new JpgcomImageMetaData(); + md = new ImageMetaData(); ret = md->load_image(file); if (ret != 1) { set_view_long(md->get_longitude()); @@ -125,18 +124,6 @@ GipfelWidget::load_image(char *file) { delete md; - if (ret == 1) { - md = new ExifImageMetaData(); - ret = md->load_image(file); - if (ret == 0) { - set_scale(md->get_focallength_sensor_ratio() * img->w()); - set_view_long(md->get_longitude()); - set_view_lat(md->get_latitude()); - set_view_height(md->get_height()); - } - delete md; - } - return 0; } @@ -155,7 +142,7 @@ GipfelWidget::save_image(char *file) { return 1; } - md = new JpgcomImageMetaData(); + md = new ImageMetaData(); md->set_longitude(get_view_long()); md->set_latitude(get_view_lat()); diff --git a/src/ImageMetaData.H b/src/ImageMetaData.H index 637b758..442aaef 100644 --- a/src/ImageMetaData.H +++ b/src/ImageMetaData.H @@ -21,7 +21,7 @@ #define IMAGE_META_DATA_H class ImageMetaData { - protected: + private: double longitude; double latitude; double height; @@ -31,11 +31,15 @@ class ImageMetaData { double focallength_sensor_ratio; int projection_type; + int load_image_jpgcom(char *name); + int save_image_jpgcom(char *in_img, char *out_img); + int load_image_exif(char *name); + public: ImageMetaData(); - virtual int load_image(char *name); - virtual int save_image(char *in_img, char *out_img); + int load_image(char *name); + int save_image(char *in_img, char *out_img); double get_longitude(); double get_latitude(); diff --git a/src/ImageMetaData.cxx b/src/ImageMetaData.cxx index 5c54a17..424a792 100644 --- a/src/ImageMetaData.cxx +++ b/src/ImageMetaData.cxx @@ -17,32 +17,258 @@ // USA. // +#include #include #include +#include +#include +#include +#include + + +#include "util.h" #include "ImageMetaData.H" ImageMetaData::ImageMetaData() { longitude = NAN; latitude = NAN; - height = NAN; - direction = NAN; - nick = NAN; - tilt = NAN; - focallength_sensor_ratio = NAN; - projection_type = -1; + height = 0.0; + direction = 0.0; + nick = 0.0; + tilt = 0.0; + focallength_sensor_ratio = 1.0; + projection_type = 1; } + int ImageMetaData::load_image(char *name) { - return 1; + int ret; + + ret = load_image_jpgcom(name); + if (ret != 0) { + ret = load_image_exif(name); + } + + return ret; } int ImageMetaData::save_image(char *in_img, char *out_img) { - return 1; + return save_image_jpgcom(in_img, out_img); +} + +static double +degminsecstr2double(char *val) { + double ret, dv; + + ret = 0.0; + for (dv=1.0; dv <= 3600.0; dv = dv * 60.0) { + ret = ret + atof(val) / dv; + val = strchr(val, ','); + if (!val || val[1] == '\0') { + break; + } else { + val++; + } + } + + return ret; +} + +#define EXIF_FOCAL_LENGTH_IN_35MM_FILM 0xa405 +#define EXIF_GPS_LATIITUDE 0x0002 +#define EXIF_GPS_LONGITUDE 0x0004 +#define EXIF_GPS_ALTITUDE 0x0006 + +int +ImageMetaData::load_image_exif(char *name) { + char * args[32]; + FILE *p; + pid_t pid; + int status; + char buf[1024]; + char val[1024]; + int id; + + args[0] = "exif"; + args[1] = "-i"; + args[2] = "-m"; + args[3] = name; + args[4] = NULL; + + p = pexecvp(args[0], args, &pid, "r"); + + if (p) { + while (fgets(buf, sizeof(buf), p) != NULL) { + if (sscanf(buf, "%x\t%[^\n]\n", &id, val) != 2) { + continue; + } + + switch(id) { + case EXIF_FOCAL_LENGTH_IN_35MM_FILM: + focallength_sensor_ratio = atof(val) / 35.0; + break; + case EXIF_GPS_LONGITUDE: + longitude = degminsecstr2double(val); + break; + case EXIF_GPS_LATIITUDE: + latitude = degminsecstr2double(val); + break; + case EXIF_GPS_ALTITUDE: + height = atof(val); + break; + } + } + } + + fclose(p); + waitpid(pid, &status, 0); + if (WEXITSTATUS(status) == 127 || WEXITSTATUS(status) == 126) { + fprintf(stderr, "%s not found\n", args[0]); + } + + return 0; +} + + +#define GIPFEL_FORMAT_1 "gipfel: longitude %lf, latitude %lf, height %lf, direction %lf, nick %lf, tilt %lf, scale %lf, projection type %d" +#define GIPFEL_FORMAT_2 "gipfel: longitude %lf, latitude %lf, height %lf, direction %lf, nick %lf, tilt %lf, focallength_sensor_ratio %lf, projection type %d" + +int +ImageMetaData::load_image_jpgcom(char *name) { + char * args[32]; + FILE *p; + pid_t pid; + int status; + char buf[1024]; + double lo, la, he, dir, ni, ti, fr; + int pt; + int ret = 1; + + args[0] = "rdjpgcom"; + args[1] = name; + args[2] = NULL; + + p = pexecvp(args[0], args, &pid, "r"); + + if (p) { + while (fgets(buf, sizeof(buf), p) != NULL) { + if (sscanf(buf, GIPFEL_FORMAT_2, + &lo, &la, &he, &dir, &ni, &ti, &fr, &pt) >= 7) { + + longitude = lo; + latitude = la; + height = he; + direction = dir; + nick = ni; + tilt = ti; + focallength_sensor_ratio = fr; + projection_type = pt; + + ret = 0; + + break; + } else if (sscanf(buf, GIPFEL_FORMAT_1, + &lo, &la, &he, &dir, &ni, &ti, &fr, &pt) >= 7) { + + longitude = lo; + latitude = la; + height = he; + direction = dir; + nick = ni; + tilt = ti; + focallength_sensor_ratio = fr; + projection_type = pt; + + ret = 2; // special return value for compatibility with + // old format + + break; + } + } + + fclose(p); + waitpid(pid, &status, 0); + if (WEXITSTATUS(status) == 127 || WEXITSTATUS(status) == 126) { + fprintf(stderr, "%s not found\n", args[0]); + } + } + + return ret; } +int +ImageMetaData::save_image_jpgcom(char *in_img, char *out_img) { + char * args[32]; + FILE *p, *out; + pid_t pid; + char buf[1024]; + int status; + size_t n; + struct stat in_stat, out_stat; + + if (stat(in_img, &in_stat) != 0) { + perror("stat"); + return 1; + } + + if (stat(out_img, &out_stat) == 0) { + if (in_stat.st_ino == out_stat.st_ino) { + fprintf(stderr, "Input image %s and output image %s are the same file\n", + in_img, out_img); + return 1; + } + } + + out = fopen(out_img, "w"); + if (out == NULL) { + perror("fopen"); + return 1; + } + + snprintf(buf, sizeof(buf), GIPFEL_FORMAT_2, + longitude, + latitude, + height, + direction, + nick, + tilt, + focallength_sensor_ratio, + projection_type); + + // try to save gipfel data in JPEG comment section + args[0] = "wrjpgcom"; + args[1] = "-replace"; + args[2] = "-comment"; + args[3] = buf; + args[4] = in_img; + args[5] = NULL; + + p = pexecvp(args[0], args, &pid, "r"); + + if (p) { + while ((n = fread(buf, 1, sizeof(buf), p)) != 0) { + if (fwrite(buf, 1, n, out) != n) { + perror("fwrite"); + fclose(out); + fclose(p); + waitpid(pid, &status, 0); + } + } + fclose(p); + waitpid(pid, &status, 0); + if (WEXITSTATUS(status) == 127 || WEXITSTATUS(status) == 126) { + fprintf(stderr, "%s not found\n", args[0]); + } + } + + fclose(out); + return 0; +} + + double ImageMetaData::get_longitude() { return longitude; diff --git a/src/JpgcomImageMetaData.H b/src/JpgcomImageMetaData.H deleted file mode 100644 index 944833a..0000000 --- a/src/JpgcomImageMetaData.H +++ /dev/null @@ -1,29 +0,0 @@ -// -// Copyright 2006 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// - -#ifndef JPGCOM_IMAGE_META_DATA_H -#define JPGCOM_IMAGE_META_DATA_H - -#include "ImageMetaData.H" - -class JpgcomImageMetaData : public ImageMetaData { - virtual int load_image(char *name); - virtual int save_image(char *in_img, char *out_img); -}; -#endif diff --git a/src/JpgcomImageMetaData.cxx b/src/JpgcomImageMetaData.cxx deleted file mode 100644 index 407b6af..0000000 --- a/src/JpgcomImageMetaData.cxx +++ /dev/null @@ -1,163 +0,0 @@ -// -// Copyright 2006 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// - -#include -#include -#include -#include -#include - -#include "util.h" - -#include "JpgcomImageMetaData.H" - -#define GIPFEL_FORMAT_1 "gipfel: longitude %lf, latitude %lf, height %lf, direction %lf, nick %lf, tilt %lf, scale %lf, projection type %d" -#define GIPFEL_FORMAT_2 "gipfel: longitude %lf, latitude %lf, height %lf, direction %lf, nick %lf, tilt %lf, focallength_sensor_ratio %lf, projection type %d" - -int -JpgcomImageMetaData::load_image(char *name) { - char * args[32]; - FILE *p; - pid_t pid; - int status; - char buf[1024]; - double lo, la, he, dir, ni, ti, fr; - int pt; - int ret = 1; - - args[0] = "rdjpgcom"; - args[1] = name; - args[2] = NULL; - - p = pexecvp(args[0], args, &pid, "r"); - - if (p) { - while (fgets(buf, sizeof(buf), p) != NULL) { - if (sscanf(buf, GIPFEL_FORMAT_2, - &lo, &la, &he, &dir, &ni, &ti, &fr, &pt) >= 7) { - - longitude = lo; - latitude = la; - height = he; - direction = dir; - nick = ni; - tilt = ti; - focallength_sensor_ratio = fr; - projection_type = pt; - - ret = 0; - - break; - } else if (sscanf(buf, GIPFEL_FORMAT_1, - &lo, &la, &he, &dir, &ni, &ti, &fr, &pt) >= 7) { - - longitude = lo; - latitude = la; - height = he; - direction = dir; - nick = ni; - tilt = ti; - focallength_sensor_ratio = fr; - projection_type = pt; - - ret = 2; // special return value for compatibility with - // old format - - break; - } - } - - fclose(p); - waitpid(pid, &status, 0); - if (WEXITSTATUS(status) == 127 || WEXITSTATUS(status) == 126) { - fprintf(stderr, "%s not found\n", args[0]); - } - } - - return ret; -} - -int -JpgcomImageMetaData::save_image(char *in_img, char *out_img) { - char * args[32]; - FILE *p, *out; - pid_t pid; - char buf[1024]; - int status; - size_t n; - struct stat in_stat, out_stat; - - if (stat(in_img, &in_stat) != 0) { - perror("stat"); - return 1; - } - - if (stat(out_img, &out_stat) == 0) { - if (in_stat.st_ino == out_stat.st_ino) { - fprintf(stderr, "Input image %s and output image %s are the same file\n", - in_img, out_img); - return 1; - } - } - - out = fopen(out_img, "w"); - if (out == NULL) { - perror("fopen"); - return 1; - } - - snprintf(buf, sizeof(buf), GIPFEL_FORMAT_2, - longitude, - latitude, - height, - direction, - nick, - tilt, - focallength_sensor_ratio, - projection_type); - - // try to save gipfel data in JPEG comment section - args[0] = "wrjpgcom"; - args[1] = "-replace"; - args[2] = "-comment"; - args[3] = buf; - args[4] = in_img; - args[5] = NULL; - - p = pexecvp(args[0], args, &pid, "r"); - - if (p) { - while ((n = fread(buf, 1, sizeof(buf), p)) != 0) { - if (fwrite(buf, 1, n, out) != n) { - perror("fwrite"); - fclose(out); - fclose(p); - waitpid(pid, &status, 0); - } - } - fclose(p); - waitpid(pid, &status, 0); - if (WEXITSTATUS(status) == 127 || WEXITSTATUS(status) == 126) { - fprintf(stderr, "%s not found\n", args[0]); - } - } - - fclose(out); - return 0; -} diff --git a/src/Makefile.am b/src/Makefile.am index a730123..8ba69c1 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -17,9 +17,7 @@ gipfel_SOURCES = \ JPEGOutputImage.cxx \ TIFFOutputImage.cxx \ PreviewOutputImage.cxx \ - ImageMetaData.cxx \ - JpgcomImageMetaData.cxx \ - ExifImageMetaData.cxx + ImageMetaData.cxx noinst_HEADERS = \ GipfelWidget.H \ @@ -38,6 +36,4 @@ noinst_HEADERS = \ TIFFOutputImage.H \ PreviewOutputImage.H \ ImageMetaData.H \ - JpgcomImageMetaData.H \ - ExifImageMetaData.H \ util.h diff --git a/src/gipfel.cxx b/src/gipfel.cxx index 1106c48..13ef3e5 100644 --- a/src/gipfel.cxx +++ b/src/gipfel.cxx @@ -23,6 +23,7 @@ #include #include #include +#include #include #include @@ -438,7 +439,7 @@ int main(int argc, char** argv) { if (view_point) { gipf->set_viewpoint(view_point); } else if (img_file && - gipf->get_view_lat()==0.0 && gipf->get_view_long()==0.0) { + (isnan(gipf->get_view_lat()) || isnan(gipf->get_view_long()))) { viewpoint_cb(NULL, NULL); } -- cgit v1.2.3 From 19bec8bde89fc08f6497a346b2121bcd96d1f528 Mon Sep 17 00:00:00 2001 From: Johannes Hofmann Date: Mon, 30 Oct 2006 18:37:27 +0100 Subject: fix problem with compatibility code --- src/GipfelWidget.cxx | 26 ++++++++++---------------- src/ImageMetaData.H | 3 ++- src/ImageMetaData.cxx | 11 +++++++---- 3 files changed, 19 insertions(+), 21 deletions(-) (limited to 'src/ImageMetaData.H') diff --git a/src/GipfelWidget.cxx b/src/GipfelWidget.cxx index 2efd231..a1982d5 100644 --- a/src/GipfelWidget.cxx +++ b/src/GipfelWidget.cxx @@ -104,23 +104,17 @@ GipfelWidget::load_image(char *file) { mb->box(FL_NO_BOX); mb->add("Center Peak", 0, (Fl_Callback*) center_cb, this); - // try to retrieve gipfel data from JPEG comment section + // try to retrieve gipfel data from JPEG meta data md = new ImageMetaData(); - ret = md->load_image(file); - if (ret != 1) { - set_view_long(md->get_longitude()); - set_view_lat(md->get_latitude()); - set_view_height(md->get_height()); - set_center_angle(md->get_direction()); - set_nick_angle(md->get_nick()); - set_tilt_angle(md->get_tilt()); - set_projection((Projection::Projection_t) md->get_projection_type()); - if (ret == 2) { // special compatibility return code for old format - set_scale(md->get_focallength_sensor_ratio()); - } else { - set_scale(md->get_focallength_sensor_ratio() * img->w()); - } - } + md->load_image(file, img->w()); + set_view_long(md->get_longitude()); + set_view_lat(md->get_latitude()); + set_view_height(md->get_height()); + set_center_angle(md->get_direction()); + set_nick_angle(md->get_nick()); + set_tilt_angle(md->get_tilt()); + set_projection((Projection::Projection_t) md->get_projection_type()); + set_scale(md->get_focallength_sensor_ratio() * img->w()); delete md; diff --git a/src/ImageMetaData.H b/src/ImageMetaData.H index 442aaef..7116d98 100644 --- a/src/ImageMetaData.H +++ b/src/ImageMetaData.H @@ -29,6 +29,7 @@ class ImageMetaData { double nick; double tilt; double focallength_sensor_ratio; + double scale; int projection_type; int load_image_jpgcom(char *name); @@ -38,7 +39,7 @@ class ImageMetaData { public: ImageMetaData(); - int load_image(char *name); + int load_image(char *name, int img_width); int save_image(char *in_img, char *out_img); double get_longitude(); diff --git a/src/ImageMetaData.cxx b/src/ImageMetaData.cxx index 424a792..d78493d 100644 --- a/src/ImageMetaData.cxx +++ b/src/ImageMetaData.cxx @@ -38,16 +38,19 @@ ImageMetaData::ImageMetaData() { nick = 0.0; tilt = 0.0; focallength_sensor_ratio = 1.0; - projection_type = 1; + scale = NAN; + projection_type = 0; } int -ImageMetaData::load_image(char *name) { +ImageMetaData::load_image(char *name, int img_width) { int ret; ret = load_image_jpgcom(name); - if (ret != 0) { + if (ret == 2) { // old format + focallength_sensor_ratio = scale / (double) img_width; + } else if (ret == 1) { // get reasonable defaults from exif data ret = load_image_exif(name); } @@ -179,7 +182,7 @@ ImageMetaData::load_image_jpgcom(char *name) { direction = dir; nick = ni; tilt = ti; - focallength_sensor_ratio = fr; + scale = fr; projection_type = pt; ret = 2; // special return value for compatibility with -- cgit v1.2.3 From 4188cb198bec8a83cfeb893608af2bd39d515449 Mon Sep 17 00:00:00 2001 From: Johannes Hofmann Date: Mon, 30 Oct 2006 19:21:16 +0100 Subject: scale -> focal_length_35mm --- src/GipfelWidget.H | 4 ++-- src/GipfelWidget.cxx | 12 ++++++------ src/ImageMetaData.H | 6 +++--- src/ImageMetaData.cxx | 20 ++++++++++---------- src/gipfel.cxx | 26 +++++++++++++------------- 5 files changed, 34 insertions(+), 34 deletions(-) (limited to 'src/ImageMetaData.H') diff --git a/src/GipfelWidget.H b/src/GipfelWidget.H index 7bcd3c0..f4c2850 100644 --- a/src/GipfelWidget.H +++ b/src/GipfelWidget.H @@ -78,7 +78,7 @@ class GipfelWidget : public Fl_Widget { void set_tilt_angle(double a); - void set_scale(double s); + void set_focal_length_35mm(double s); void set_height_dist_ratio(double r); @@ -100,7 +100,7 @@ class GipfelWidget : public Fl_Widget { double get_tilt_angle(); - double get_scale(); + double get_focal_length_35mm(); double get_height_dist_ratio(); diff --git a/src/GipfelWidget.cxx b/src/GipfelWidget.cxx index a1982d5..f38b21c 100644 --- a/src/GipfelWidget.cxx +++ b/src/GipfelWidget.cxx @@ -114,7 +114,7 @@ GipfelWidget::load_image(char *file) { set_nick_angle(md->get_nick()); set_tilt_angle(md->get_tilt()); set_projection((Projection::Projection_t) md->get_projection_type()); - set_scale(md->get_focallength_sensor_ratio() * img->w()); + set_focal_length_35mm(md->get_focal_length_35mm()); delete md; @@ -144,7 +144,7 @@ GipfelWidget::save_image(char *file) { md->set_direction(get_center_angle()); md->set_nick(get_nick_angle()); md->set_tilt(get_tilt_angle()); - md->set_focallength_sensor_ratio(get_scale() / (double) img->w()); + md->set_focal_length_35mm(get_focal_length_35mm()); md->set_projection_type((int) get_projection()); ret = md->save_image(img_file, file); @@ -469,8 +469,8 @@ GipfelWidget::set_tilt_angle(double a) { } void -GipfelWidget::set_scale(double s) { - pan->set_scale(s); +GipfelWidget::set_focal_length_35mm(double s) { + pan->set_scale(s * (double) img->w() / 35.0); set_labels(pan->get_visible_mountains()); redraw(); } @@ -503,8 +503,8 @@ GipfelWidget::get_tilt_angle() { } double -GipfelWidget::get_scale() { - return pan->get_scale(); +GipfelWidget::get_focal_length_35mm() { + return pan->get_scale() * 35.0 / (double) img->w(); } double diff --git a/src/ImageMetaData.H b/src/ImageMetaData.H index 7116d98..48d5043 100644 --- a/src/ImageMetaData.H +++ b/src/ImageMetaData.H @@ -28,7 +28,7 @@ class ImageMetaData { double direction; double nick; double tilt; - double focallength_sensor_ratio; + double focal_length_35mm; double scale; int projection_type; @@ -48,7 +48,7 @@ class ImageMetaData { double get_direction(); double get_nick(); double get_tilt(); - double get_focallength_sensor_ratio(); + double get_focal_length_35mm(); int get_projection_type(); void set_longitude(double v); @@ -57,7 +57,7 @@ class ImageMetaData { void set_direction(double v); void set_nick(double v); void set_tilt(double v); - void set_focallength_sensor_ratio(double v); + void set_focal_length_35mm(double v); void set_projection_type(int v); }; #endif diff --git a/src/ImageMetaData.cxx b/src/ImageMetaData.cxx index d78493d..a5d3726 100644 --- a/src/ImageMetaData.cxx +++ b/src/ImageMetaData.cxx @@ -37,7 +37,7 @@ ImageMetaData::ImageMetaData() { direction = 0.0; nick = 0.0; tilt = 0.0; - focallength_sensor_ratio = 1.0; + focal_length_35mm = 35.0; scale = NAN; projection_type = 0; } @@ -49,7 +49,7 @@ ImageMetaData::load_image(char *name, int img_width) { ret = load_image_jpgcom(name); if (ret == 2) { // old format - focallength_sensor_ratio = scale / (double) img_width; + focal_length_35mm = scale * 35.0 / (double) img_width; } else if (ret == 1) { // get reasonable defaults from exif data ret = load_image_exif(name); } @@ -111,7 +111,7 @@ ImageMetaData::load_image_exif(char *name) { switch(id) { case EXIF_FOCAL_LENGTH_IN_35MM_FILM: - focallength_sensor_ratio = atof(val) / 35.0; + focal_length_35mm = atof(val); break; case EXIF_GPS_LONGITUDE: longitude = degminsecstr2double(val); @@ -137,7 +137,7 @@ ImageMetaData::load_image_exif(char *name) { #define GIPFEL_FORMAT_1 "gipfel: longitude %lf, latitude %lf, height %lf, direction %lf, nick %lf, tilt %lf, scale %lf, projection type %d" -#define GIPFEL_FORMAT_2 "gipfel: longitude %lf, latitude %lf, height %lf, direction %lf, nick %lf, tilt %lf, focallength_sensor_ratio %lf, projection type %d" +#define GIPFEL_FORMAT_2 "gipfel: longitude %lf, latitude %lf, height %lf, direction %lf, nick %lf, tilt %lf, focal_length_35mm %lf, projection type %d" int ImageMetaData::load_image_jpgcom(char *name) { @@ -167,7 +167,7 @@ ImageMetaData::load_image_jpgcom(char *name) { direction = dir; nick = ni; tilt = ti; - focallength_sensor_ratio = fr; + focal_length_35mm = fr; projection_type = pt; ret = 0; @@ -238,7 +238,7 @@ ImageMetaData::save_image_jpgcom(char *in_img, char *out_img) { direction, nick, tilt, - focallength_sensor_ratio, + focal_length_35mm, projection_type); // try to save gipfel data in JPEG comment section @@ -303,8 +303,8 @@ ImageMetaData::get_tilt() { } double -ImageMetaData::get_focallength_sensor_ratio() { - return focallength_sensor_ratio; +ImageMetaData::get_focal_length_35mm() { + return focal_length_35mm; } int @@ -343,8 +343,8 @@ ImageMetaData::set_tilt(double v) { } void -ImageMetaData::set_focallength_sensor_ratio(double v) { - focallength_sensor_ratio = v; +ImageMetaData::set_focal_length_35mm(double v) { + focal_length_35mm = v; } void diff --git a/src/gipfel.cxx b/src/gipfel.cxx index 13ef3e5..dc15d8e 100644 --- a/src/gipfel.cxx +++ b/src/gipfel.cxx @@ -58,7 +58,7 @@ char *data_file = DEFAULT_DATAFILE; GipfelWidget *gipf = NULL; Fl_Dial *s_center = NULL; -Fl_Slider *s_nick, *s_scale, *s_tilt, *s_height_dist, *s_track_width; +Fl_Slider *s_nick, *s_focal_length, *s_tilt, *s_height_dist, *s_track_width; Fl_Value_Input *i_view_lat, *i_view_long, *i_view_height; Fl_Box *b_viewpoint; Fl_Menu_Bar *mb; @@ -72,7 +72,7 @@ static int stitch(int stitch_w, int stitch_h, int type, const char *path, void set_values() { s_center->value(gipf->get_center_angle()); s_nick->value(gipf->get_nick_angle()); - s_scale->value(gipf->get_scale()); + s_focal_length->value(gipf->get_focal_length_35mm()); s_tilt->value(gipf->get_tilt_angle()); s_height_dist->value(gipf->get_height_dist_ratio()); i_view_lat->value(gipf->get_view_lat()); @@ -114,8 +114,8 @@ void save_cb() { } } -void scale_cb(Fl_Slider* o, void*) { - gipf->set_scale(o->value()); +void focal_length_cb(Fl_Slider* o, void*) { + gipf->set_focal_length_35mm(o->value()); } void angle_cb(Fl_Slider* o, void*) { @@ -245,15 +245,15 @@ create_control_window() { Fl_Box *west = new Fl_Box(0, 125, 40, 20, "West"); - s_scale = new Fl_Value_Slider(235, 60, 160, 15, "Scale"); - s_scale->type(1); - s_scale->box(FL_THIN_DOWN_BOX); - s_scale->labelsize(10); - s_scale->step(5.0); - s_scale->bounds(0.0, 10000.0); - s_scale->slider(FL_UP_BOX); - s_scale->callback((Fl_Callback*)scale_cb); - s_scale->align(FL_ALIGN_TOP); + s_focal_length = new Fl_Value_Slider(235, 60, 160, 15, "Focal Length In 35mm"); + s_focal_length->type(1); + s_focal_length->box(FL_THIN_DOWN_BOX); + s_focal_length->labelsize(10); + s_focal_length->step(0.01); + s_focal_length->bounds(1.0, 200.0); + s_focal_length->slider(FL_UP_BOX); + s_focal_length->callback((Fl_Callback*)focal_length_cb); + s_focal_length->align(FL_ALIGN_TOP); s_nick = new Fl_Value_Slider(235, 90, 160, 15, "Nick (deg.)"); s_nick->type(1); -- cgit v1.2.3 From 364fadcbea5f37799bb42e663106e3a007746984 Mon Sep 17 00:00:00 2001 From: Johannes Hofmann Date: Mon, 30 Oct 2006 20:45:53 +0100 Subject: strip copyright --- src/Fl_Search_Chooser.H | 20 -------------------- src/Fl_Search_Chooser.cxx | 21 --------------------- src/Fl_Value_Dial.H | 20 -------------------- src/Fl_Value_Dial.cxx | 20 -------------------- src/GipfelWidget.H | 18 ------------------ src/GipfelWidget.cxx | 18 ------------------ src/Hill.H | 18 ------------------ src/Hill.cxx | 18 ------------------ src/ImageMetaData.H | 18 ------------------ src/ImageMetaData.cxx | 18 ------------------ src/JPEGOutputImage.H | 18 ------------------ src/JPEGOutputImage.cxx | 18 ------------------ src/OutputImage.H | 18 ------------------ src/OutputImage.cxx | 18 ------------------ src/Panorama.H | 18 ------------------ src/Panorama.cxx | 18 ------------------ src/PreviewOutputImage.H | 18 ------------------ src/PreviewOutputImage.cxx | 18 ------------------ src/Projection.H | 18 ------------------ src/Projection.cxx | 18 ------------------ src/ProjectionSphaeric.H | 18 ------------------ src/ProjectionSphaeric.cxx | 19 ------------------- src/ProjectionTangential.H | 18 ------------------ src/ProjectionTangential.cxx | 18 ------------------ src/Stitch.H | 18 ------------------ src/Stitch.cxx | 18 ------------------ src/TIFFOutputImage.H | 18 ------------------ src/TIFFOutputImage.cxx | 18 ------------------ src/ViewParams.H | 18 ------------------ src/choose_hill.H | 18 ------------------ src/choose_hill.cxx | 21 --------------------- src/gipfel.cxx | 20 -------------------- 32 files changed, 591 deletions(-) (limited to 'src/ImageMetaData.H') diff --git a/src/Fl_Search_Chooser.H b/src/Fl_Search_Chooser.H index c87f0de..c5e88d9 100644 --- a/src/Fl_Search_Chooser.H +++ b/src/Fl_Search_Chooser.H @@ -1,23 +1,3 @@ -// -// Value dial header file for the Fast Light Tool Kit (FLTK). -// -// Copyright 1998-2004 by Bill Spitzak and others. -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #ifndef FL_SEARCH_CHOOSER_H #define FL_SEARCH_CHOOSER_H diff --git a/src/Fl_Search_Chooser.cxx b/src/Fl_Search_Chooser.cxx index 62aa7d1..f1cd6c3 100644 --- a/src/Fl_Search_Chooser.cxx +++ b/src/Fl_Search_Chooser.cxx @@ -1,24 +1,3 @@ -// -// Search Chooser widget for the Fast Light Tool Kit (FLTK). -// -// Copyright by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// -// #include #include diff --git a/src/Fl_Value_Dial.H b/src/Fl_Value_Dial.H index f9ac18c..71e32a4 100644 --- a/src/Fl_Value_Dial.H +++ b/src/Fl_Value_Dial.H @@ -1,23 +1,3 @@ -// -// Value dial header file for the Fast Light Tool Kit (FLTK). -// -// Copyright 1998-2004 by Bill Spitzak and others. -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #ifndef Fl_Value_Dial_H #define Fl_Value_Dial_H diff --git a/src/Fl_Value_Dial.cxx b/src/Fl_Value_Dial.cxx index c837930..482ec2e 100644 --- a/src/Fl_Value_Dial.cxx +++ b/src/Fl_Value_Dial.cxx @@ -1,23 +1,3 @@ -// -// Value dial widget for the Fast Light Tool Kit (FLTK). -// -// Copyright 1998-2004 by Bill Spitzak and others. -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #include #include diff --git a/src/GipfelWidget.H b/src/GipfelWidget.H index f4c2850..86e8d07 100644 --- a/src/GipfelWidget.H +++ b/src/GipfelWidget.H @@ -1,21 +1,3 @@ -// -// Copyright 2006 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #ifndef GipfelWidget_H #define GipfelWidget_H diff --git a/src/GipfelWidget.cxx b/src/GipfelWidget.cxx index f38b21c..30320de 100644 --- a/src/GipfelWidget.cxx +++ b/src/GipfelWidget.cxx @@ -1,21 +1,3 @@ -// -// Copyright 2006 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #include #include diff --git a/src/Hill.H b/src/Hill.H index 13d7d64..5c8aca7 100644 --- a/src/Hill.H +++ b/src/Hill.H @@ -1,21 +1,3 @@ -// -// Copyright 2005 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #ifndef HILL_H #define HILL_H diff --git a/src/Hill.cxx b/src/Hill.cxx index 277cefe..5ec35ee 100644 --- a/src/Hill.cxx +++ b/src/Hill.cxx @@ -1,21 +1,3 @@ -// -// Copyright 2005 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #include #include diff --git a/src/ImageMetaData.H b/src/ImageMetaData.H index 48d5043..6cb16fe 100644 --- a/src/ImageMetaData.H +++ b/src/ImageMetaData.H @@ -1,21 +1,3 @@ -// -// Copyright 2006 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #ifndef IMAGE_META_DATA_H #define IMAGE_META_DATA_H diff --git a/src/ImageMetaData.cxx b/src/ImageMetaData.cxx index a5d3726..6d66954 100644 --- a/src/ImageMetaData.cxx +++ b/src/ImageMetaData.cxx @@ -1,21 +1,3 @@ -// -// Copyright 2006 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #include #include diff --git a/src/JPEGOutputImage.H b/src/JPEGOutputImage.H index 50570e5..4a9e60f 100644 --- a/src/JPEGOutputImage.H +++ b/src/JPEGOutputImage.H @@ -1,21 +1,3 @@ -// -// Copyright 2006 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #ifndef JPEGOUTPUTIMAGE_H #define JPEGOUTPUTIMAGE_H diff --git a/src/JPEGOutputImage.cxx b/src/JPEGOutputImage.cxx index 3f7fd11..7ca4cb5 100644 --- a/src/JPEGOutputImage.cxx +++ b/src/JPEGOutputImage.cxx @@ -1,21 +1,3 @@ -// -// Copyright 2006 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #include #include diff --git a/src/OutputImage.H b/src/OutputImage.H index 8792eb6..bae0ff5 100644 --- a/src/OutputImage.H +++ b/src/OutputImage.H @@ -1,21 +1,3 @@ -// -// Copyright 2006 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #ifndef OUTPUTIMAGE_H #define OUTPUTIMAGE_H diff --git a/src/OutputImage.cxx b/src/OutputImage.cxx index f2e7296..e4da537 100644 --- a/src/OutputImage.cxx +++ b/src/OutputImage.cxx @@ -1,21 +1,3 @@ -// -// Copyright 2006 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #include #include diff --git a/src/Panorama.H b/src/Panorama.H index a538809..3f8312a 100644 --- a/src/Panorama.H +++ b/src/Panorama.H @@ -1,21 +1,3 @@ -// -// Copyright 2005 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #ifndef PANORAMA_H #define PANORAMA_H diff --git a/src/Panorama.cxx b/src/Panorama.cxx index ebf0b5b..f964e40 100644 --- a/src/Panorama.cxx +++ b/src/Panorama.cxx @@ -1,21 +1,3 @@ -// -// Copyright 2005 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #include #include diff --git a/src/PreviewOutputImage.H b/src/PreviewOutputImage.H index 7095999..5852730 100644 --- a/src/PreviewOutputImage.H +++ b/src/PreviewOutputImage.H @@ -1,21 +1,3 @@ -// -// Copyright 2006 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #ifndef PREVIEWOUTPUTIMAGE_H #define PREVIEWOUTPUTIMAGE_H diff --git a/src/PreviewOutputImage.cxx b/src/PreviewOutputImage.cxx index 8b09e80..3caef7f 100644 --- a/src/PreviewOutputImage.cxx +++ b/src/PreviewOutputImage.cxx @@ -1,21 +1,3 @@ -// -// Copyright 2006 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #include #include diff --git a/src/Projection.H b/src/Projection.H index 0a6ec81..cb9bc7e 100644 --- a/src/Projection.H +++ b/src/Projection.H @@ -1,21 +1,3 @@ -// -// Copyright 2006 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #ifndef PROJECTION_H #define PROJECTION_H diff --git a/src/Projection.cxx b/src/Projection.cxx index 1916d55..d6dbd34 100644 --- a/src/Projection.cxx +++ b/src/Projection.cxx @@ -1,21 +1,3 @@ -// -// Copyright 2006 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #include #include diff --git a/src/ProjectionSphaeric.H b/src/ProjectionSphaeric.H index 06396f1..49fc74d 100644 --- a/src/ProjectionSphaeric.H +++ b/src/ProjectionSphaeric.H @@ -1,21 +1,3 @@ -// -// Copyright 2005 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #ifndef PROJECTIONSPHAERIC_H #define PROJECTIONSPHAERIC_H diff --git a/src/ProjectionSphaeric.cxx b/src/ProjectionSphaeric.cxx index e69882b..dbbcec6 100644 --- a/src/ProjectionSphaeric.cxx +++ b/src/ProjectionSphaeric.cxx @@ -1,22 +1,3 @@ -// -// Copyright 2005 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// - #include #include #include diff --git a/src/ProjectionTangential.H b/src/ProjectionTangential.H index e74511f..77c10d7 100644 --- a/src/ProjectionTangential.H +++ b/src/ProjectionTangential.H @@ -1,21 +1,3 @@ -// -// Copyright 2005 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #ifndef PROJECTIONTANGENTIAL_H #define PROJECTIONTANGENTIAL_H diff --git a/src/ProjectionTangential.cxx b/src/ProjectionTangential.cxx index 2578c5a..230662a 100644 --- a/src/ProjectionTangential.cxx +++ b/src/ProjectionTangential.cxx @@ -1,21 +1,3 @@ -// -// Copyright 2005 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #include #include diff --git a/src/Stitch.H b/src/Stitch.H index 0bb6d48..2fbde1f 100644 --- a/src/Stitch.H +++ b/src/Stitch.H @@ -1,21 +1,3 @@ -// -// Copyright 2005 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #ifndef STITCH_H #define STITCH_H diff --git a/src/Stitch.cxx b/src/Stitch.cxx index af46968..ec1daf6 100644 --- a/src/Stitch.cxx +++ b/src/Stitch.cxx @@ -1,21 +1,3 @@ -// -// Copyright 2006 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #include #include diff --git a/src/TIFFOutputImage.H b/src/TIFFOutputImage.H index 3a14279..1c9aad8 100644 --- a/src/TIFFOutputImage.H +++ b/src/TIFFOutputImage.H @@ -1,21 +1,3 @@ -// -// Copyright 2006 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #ifndef TIFFOUTPUTIMAGE_H #define TIFFOUTPUTIMAGE_H diff --git a/src/TIFFOutputImage.cxx b/src/TIFFOutputImage.cxx index b8433ca..b528521 100644 --- a/src/TIFFOutputImage.cxx +++ b/src/TIFFOutputImage.cxx @@ -1,21 +1,3 @@ -// -// Copyright 2006 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #include #include diff --git a/src/ViewParams.H b/src/ViewParams.H index 37c5e48..ba24f22 100644 --- a/src/ViewParams.H +++ b/src/ViewParams.H @@ -1,21 +1,3 @@ -// -// Copyright 2005 by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #ifndef VIEWPARAMS_H #define VIEWPARAMS_H diff --git a/src/choose_hill.H b/src/choose_hill.H index e424d70..76fb018 100644 --- a/src/choose_hill.H +++ b/src/choose_hill.H @@ -1,21 +1,3 @@ -// -// Copyright 1998-2004 by Bill Spitzak and others. -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #ifndef CHOOSE_HILL_H #define CHOOSE_HILL_H diff --git a/src/choose_hill.cxx b/src/choose_hill.cxx index f144d5e..9162e40 100644 --- a/src/choose_hill.cxx +++ b/src/choose_hill.cxx @@ -1,24 +1,3 @@ -// -// Search Chooser widget for the Fast Light Tool Kit (FLTK). -// -// Copyright by Johannes Hofmann -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Library General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Library General Public License for more details. -// -// You should have received a copy of the GNU Library General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// -// #include #include diff --git a/src/gipfel.cxx b/src/gipfel.cxx index dc15d8e..3ec7290 100644 --- a/src/gipfel.cxx +++ b/src/gipfel.cxx @@ -1,23 +1,3 @@ -// -// gipfel program. -// -// Copyright 2006 by Johannes Hofmann -// -// This program is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public -// License as published by the Free Software Foundation; either -// version 2 of the License, or (at your option) any later version. -// -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// General Public License for more details. -// -// You should have received a copy of the GNU General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -// USA. -// #include #include -- cgit v1.2.3 From 6c50749f40e50a4b6a260a262b40035bfe83fd76 Mon Sep 17 00:00:00 2001 From: Johannes Hofmann Date: Mon, 30 Oct 2006 20:49:30 +0100 Subject: add simplified copyright --- src/Fl_Search_Chooser.H | 5 +++++ src/Fl_Search_Chooser.cxx | 5 +++++ src/Fl_Value_Dial.H | 5 +++++ src/Fl_Value_Dial.cxx | 5 +++++ src/GipfelWidget.H | 5 +++++ src/GipfelWidget.cxx | 5 +++++ src/Hill.H | 5 +++++ src/Hill.cxx | 5 +++++ src/ImageMetaData.H | 5 +++++ src/ImageMetaData.cxx | 5 +++++ src/JPEGOutputImage.H | 5 +++++ src/JPEGOutputImage.cxx | 5 +++++ src/OutputImage.H | 5 +++++ src/OutputImage.cxx | 5 +++++ src/Panorama.H | 5 +++++ src/Panorama.cxx | 5 +++++ src/PreviewOutputImage.H | 5 +++++ src/PreviewOutputImage.cxx | 5 +++++ src/Projection.H | 5 +++++ src/Projection.cxx | 5 +++++ src/ProjectionSphaeric.H | 5 +++++ src/ProjectionSphaeric.cxx | 5 +++++ src/ProjectionTangential.H | 5 +++++ src/ProjectionTangential.cxx | 5 +++++ src/Stitch.H | 5 +++++ src/Stitch.cxx | 5 +++++ src/TIFFOutputImage.H | 5 +++++ src/TIFFOutputImage.cxx | 5 +++++ src/ViewParams.H | 5 +++++ src/choose_hill.H | 5 +++++ src/choose_hill.cxx | 5 +++++ src/gipfel.cxx | 5 +++++ 32 files changed, 160 insertions(+) (limited to 'src/ImageMetaData.H') diff --git a/src/Fl_Search_Chooser.H b/src/Fl_Search_Chooser.H index c5e88d9..d3478c2 100644 --- a/src/Fl_Search_Chooser.H +++ b/src/Fl_Search_Chooser.H @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #ifndef FL_SEARCH_CHOOSER_H #define FL_SEARCH_CHOOSER_H diff --git a/src/Fl_Search_Chooser.cxx b/src/Fl_Search_Chooser.cxx index f1cd6c3..28396a0 100644 --- a/src/Fl_Search_Chooser.cxx +++ b/src/Fl_Search_Chooser.cxx @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #include #include diff --git a/src/Fl_Value_Dial.H b/src/Fl_Value_Dial.H index 71e32a4..35a3adf 100644 --- a/src/Fl_Value_Dial.H +++ b/src/Fl_Value_Dial.H @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #ifndef Fl_Value_Dial_H #define Fl_Value_Dial_H diff --git a/src/Fl_Value_Dial.cxx b/src/Fl_Value_Dial.cxx index 482ec2e..773cb58 100644 --- a/src/Fl_Value_Dial.cxx +++ b/src/Fl_Value_Dial.cxx @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #include #include diff --git a/src/GipfelWidget.H b/src/GipfelWidget.H index 86e8d07..4b3166e 100644 --- a/src/GipfelWidget.H +++ b/src/GipfelWidget.H @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #ifndef GipfelWidget_H #define GipfelWidget_H diff --git a/src/GipfelWidget.cxx b/src/GipfelWidget.cxx index 30320de..2927cde 100644 --- a/src/GipfelWidget.cxx +++ b/src/GipfelWidget.cxx @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #include #include diff --git a/src/Hill.H b/src/Hill.H index 5c8aca7..37ab44a 100644 --- a/src/Hill.H +++ b/src/Hill.H @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #ifndef HILL_H #define HILL_H diff --git a/src/Hill.cxx b/src/Hill.cxx index 5ec35ee..14b8f81 100644 --- a/src/Hill.cxx +++ b/src/Hill.cxx @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #include #include diff --git a/src/ImageMetaData.H b/src/ImageMetaData.H index 6cb16fe..5796964 100644 --- a/src/ImageMetaData.H +++ b/src/ImageMetaData.H @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #ifndef IMAGE_META_DATA_H #define IMAGE_META_DATA_H diff --git a/src/ImageMetaData.cxx b/src/ImageMetaData.cxx index 6d66954..6519239 100644 --- a/src/ImageMetaData.cxx +++ b/src/ImageMetaData.cxx @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #include #include diff --git a/src/JPEGOutputImage.H b/src/JPEGOutputImage.H index 4a9e60f..b3554c8 100644 --- a/src/JPEGOutputImage.H +++ b/src/JPEGOutputImage.H @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #ifndef JPEGOUTPUTIMAGE_H #define JPEGOUTPUTIMAGE_H diff --git a/src/JPEGOutputImage.cxx b/src/JPEGOutputImage.cxx index 7ca4cb5..6e685d0 100644 --- a/src/JPEGOutputImage.cxx +++ b/src/JPEGOutputImage.cxx @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #include #include diff --git a/src/OutputImage.H b/src/OutputImage.H index bae0ff5..9be72c5 100644 --- a/src/OutputImage.H +++ b/src/OutputImage.H @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #ifndef OUTPUTIMAGE_H #define OUTPUTIMAGE_H diff --git a/src/OutputImage.cxx b/src/OutputImage.cxx index e4da537..ddf8e14 100644 --- a/src/OutputImage.cxx +++ b/src/OutputImage.cxx @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #include #include diff --git a/src/Panorama.H b/src/Panorama.H index 3f8312a..80a8f69 100644 --- a/src/Panorama.H +++ b/src/Panorama.H @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #ifndef PANORAMA_H #define PANORAMA_H diff --git a/src/Panorama.cxx b/src/Panorama.cxx index f964e40..4674c47 100644 --- a/src/Panorama.cxx +++ b/src/Panorama.cxx @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #include #include diff --git a/src/PreviewOutputImage.H b/src/PreviewOutputImage.H index 5852730..8b41684 100644 --- a/src/PreviewOutputImage.H +++ b/src/PreviewOutputImage.H @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #ifndef PREVIEWOUTPUTIMAGE_H #define PREVIEWOUTPUTIMAGE_H diff --git a/src/PreviewOutputImage.cxx b/src/PreviewOutputImage.cxx index 3caef7f..4b1d993 100644 --- a/src/PreviewOutputImage.cxx +++ b/src/PreviewOutputImage.cxx @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #include #include diff --git a/src/Projection.H b/src/Projection.H index cb9bc7e..6db0e97 100644 --- a/src/Projection.H +++ b/src/Projection.H @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #ifndef PROJECTION_H #define PROJECTION_H diff --git a/src/Projection.cxx b/src/Projection.cxx index d6dbd34..88ec5bf 100644 --- a/src/Projection.cxx +++ b/src/Projection.cxx @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #include #include diff --git a/src/ProjectionSphaeric.H b/src/ProjectionSphaeric.H index 49fc74d..f80940a 100644 --- a/src/ProjectionSphaeric.H +++ b/src/ProjectionSphaeric.H @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #ifndef PROJECTIONSPHAERIC_H #define PROJECTIONSPHAERIC_H diff --git a/src/ProjectionSphaeric.cxx b/src/ProjectionSphaeric.cxx index dbbcec6..d4e7e43 100644 --- a/src/ProjectionSphaeric.cxx +++ b/src/ProjectionSphaeric.cxx @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #include #include #include diff --git a/src/ProjectionTangential.H b/src/ProjectionTangential.H index 77c10d7..07ddaf9 100644 --- a/src/ProjectionTangential.H +++ b/src/ProjectionTangential.H @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #ifndef PROJECTIONTANGENTIAL_H #define PROJECTIONTANGENTIAL_H diff --git a/src/ProjectionTangential.cxx b/src/ProjectionTangential.cxx index 230662a..230767c 100644 --- a/src/ProjectionTangential.cxx +++ b/src/ProjectionTangential.cxx @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #include #include diff --git a/src/Stitch.H b/src/Stitch.H index 2fbde1f..d29c2e9 100644 --- a/src/Stitch.H +++ b/src/Stitch.H @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #ifndef STITCH_H #define STITCH_H diff --git a/src/Stitch.cxx b/src/Stitch.cxx index ec1daf6..f378747 100644 --- a/src/Stitch.cxx +++ b/src/Stitch.cxx @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #include #include diff --git a/src/TIFFOutputImage.H b/src/TIFFOutputImage.H index 1c9aad8..820a281 100644 --- a/src/TIFFOutputImage.H +++ b/src/TIFFOutputImage.H @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #ifndef TIFFOUTPUTIMAGE_H #define TIFFOUTPUTIMAGE_H diff --git a/src/TIFFOutputImage.cxx b/src/TIFFOutputImage.cxx index b528521..cc1b289 100644 --- a/src/TIFFOutputImage.cxx +++ b/src/TIFFOutputImage.cxx @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #include #include diff --git a/src/ViewParams.H b/src/ViewParams.H index ba24f22..b6f34a2 100644 --- a/src/ViewParams.H +++ b/src/ViewParams.H @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #ifndef VIEWPARAMS_H #define VIEWPARAMS_H diff --git a/src/choose_hill.H b/src/choose_hill.H index 76fb018..2425fa3 100644 --- a/src/choose_hill.H +++ b/src/choose_hill.H @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #ifndef CHOOSE_HILL_H #define CHOOSE_HILL_H diff --git a/src/choose_hill.cxx b/src/choose_hill.cxx index 9162e40..d3477f3 100644 --- a/src/choose_hill.cxx +++ b/src/choose_hill.cxx @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #include #include diff --git a/src/gipfel.cxx b/src/gipfel.cxx index 3ec7290..343d19f 100644 --- a/src/gipfel.cxx +++ b/src/gipfel.cxx @@ -1,3 +1,8 @@ +// +// Copyright 2006 Johannes Hofmann +// +// This software may be used and distributed according to the terms +// of the GNU General Public License, incorporated herein by reference. #include #include -- cgit v1.2.3