Diff of /panTools.h [68cdf8] .. [ed05d7] Maximize Restore

  Switch to side-by-side view

--- a/panTools.h
+++ b/panTools.h
@@ -1,9 +1,3 @@
-#ifndef PANTOOLS_H
-#define PANTOOLS_H
-
-// PTLens, Copyright (C) 2004, Thomas Niemann
-// email: thomasn@epaperpress.com, subject=ptlens
-// 
 // 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 
@@ -21,69 +15,103 @@
 // write to the Free Software Foundation, Inc., 675 
 // Mass Ave, Cambridge, MA 02139, USA.
 
-#include "Panorama.h"
-#include "Filter.h"
+/**
+* @file panTools.h
+* This file is included in all four plug-ins (PTAdjust, PTCorrect, PTPerspect, and PTRemap)
+* It contains the main functions to invoke panotools to preform the selected tasks
+* @date January 2007
+*/
 
-// photoshop image parameters
-typedef struct {
-    int imageWidth;
-	int imageHeight;
-	int imageDepth;
-	int imageChannelSize;
-	int imageSize;
+#ifndef PANTOOLS_H
+#define PANTOOLS_H
+
+#ifdef __cplusplus
+extern "C" {  
+#endif	
+
+#include "../libpano/sys_win.h"
+#include "../libpano/Filter.h"
+
+#ifdef __cplusplus
+}
+#endif
+
+
+
+/**
+* photoshop image parameters
+*/
+typedef struct
+{
+  int imageWidth;         //< the Image Width
+  int imageHeight;        //< the Image Height
+  int imageDepth;         //< the Image Depth
+  int imageChannelSize;   //< the Image ChannelSize
+  int imageSize;          //< the Image Size
 } PhoData;
 
-typedef struct {
-	Image image1;
-	Image image2;
-	panoPrefs prefs;
-	sPrefs sprefs;
-	TrformStr tr;
-	bool initPrefs;
+/**
+* Panorama Data
+*/
+typedef struct
+{
+  Image     image1;       //< Image 1
+  Image     image2;       //< Image 2
+  panoPrefs prefs;        //< Panorama Prefs
+  sPrefs    sprefs;       //< Stitch Prefs
+  TrformStr tr;           //< Tranform 
+  bool      initPrefs;    //< initialized
 } PanData;
 
 
+#if 0   // unused functions
 typedef void (*ConvFileName_proc)(fullPath *fname,char *string);
+typedef void (*PrintError_proc)(char* fmt, ...); 
+typedef void (*SetAdjustDefaults_proc)(aPrefs *p);
+typedef int (*addLayerToFile_proc)(Image *im, fullPath* sfile, fullPath* dfile, stBuf *sB);
+typedef void** (*mymalloc_proc)(long numBytes);
+typedef int (*readPrefs_proc)(char* p, int selector ); 
+typedef int (*writePSDwithLayer_proc)(Image *im, fullPath *fname);
+typedef int (*writeTIFF_proc)(Image *im, fullPath* fname);
+#endif
+
 typedef void (*CopyImageData_proc)(Image *dest, Image *src);
 typedef void (*FourToThreeBPP_proc)(Image *im);
-typedef void (*PrintError_proc)(char* fmt, ...); 
-typedef void (*SetAdjustDefaults_proc)(aPrefs *p);
 typedef void (*SetImageDefaults_proc)(Image *im);
 typedef void (*SetWindowOwner_proc)(HWND owner);
-typedef int (*addLayerToFile_proc)(Image *im, fullPath* sfile, fullPath* dfile, stBuf *sB);
 typedef void (*filter_main_proc)(TrformStr *TrPtr, struct size_Prefs *spref);
 typedef void (*myfree_proc)(void **hdl);
-typedef void** (*mymalloc_proc)(long numBytes);
-typedef int (*readPrefs_proc)(char* p, int selector ); 
 typedef int (*writePSD_proc)(Image *im, fullPath* fname);
-typedef int (*writePSDwithLayer_proc)(Image *im, fullPath *fname);
-typedef int (*writeTIFF_proc)(Image *im, fullPath* fname);
 
-typedef struct {
-	// handle to pano12.dll
-	HINSTANCE hPano12;
+/**
+* Panorama funtions called from within the plug ins
+*/
+typedef struct
+{
+  // handle to pano13.dll
+  HINSTANCE hpano13;
 
-	// entry points to pano12.dll
-	FourToThreeBPP_proc FourToThreeBPP;
-	filter_main_proc filter_main;
-	myfree_proc myfree;
-	SetWindowOwner_proc SetWindowOwner;
-	SetImageDefaults_proc SetImageDefaults;
-	CopyImageData_proc CopyImageData;
-	writePSD_proc writePSD;
+  // entry points to pano13.dll
+  FourToThreeBPP_proc FourToThreeBPP;
+  filter_main_proc filter_main;
+  myfree_proc myfree;
+  SetWindowOwner_proc SetWindowOwner;
+  SetImageDefaults_proc SetImageDefaults;
+  CopyImageData_proc CopyImageData;
+  writePSD_proc writePSD;
 
 #if 0   // unused calls
-	ConvFileName_proc ConvFileName;
-	PrintError_proc PrintError;
-	SetAdjustDefaults_proc SetAdjustDefaults;
-	addLayerToFile_proc addLayerToFile;
-	mymalloc_proc mymalloc;
-	readPrefs_proc readPrefs;
-	writePSDwithLayer_proc writePSDwithLayer;
-	writeTIFF_proc writeTIFF;
+  ConvFileName_proc ConvFileName;
+  PrintError_proc PrintError;
+  SetAdjustDefaults_proc SetAdjustDefaults;
+  addLayerToFile_proc addLayerToFile;
+  mymalloc_proc mymalloc;
+  readPrefs_proc readPrefs;
+  writePSDwithLayer_proc writePSDwithLayer;
+  writeTIFF_proc writeTIFF;
 #endif
 
-	bool initDLL;		// true of pano12.dll is loaded & initialized
+  bool initDLL;       //< true of pano13.dll is loaded & initialized
 } DllData;
 
 int panTools();