VTK
dox/Geovis/Core/vtkGeoAlignedImageSource.h
Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Visualization Toolkit
00004   Module:    vtkGeoAlignedImageSource.h
00005 
00006   Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
00007   All rights reserved.
00008   See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
00009 
00010      This software is distributed WITHOUT ANY WARRANTY; without even
00011      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
00012      PURPOSE.  See the above copyright notice for more information.
00013 
00014 =========================================================================*/
00015 /*-------------------------------------------------------------------------
00016   Copyright 2008 Sandia Corporation.
00017   Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation,
00018   the U.S. Government retains certain rights in this software.
00019 -------------------------------------------------------------------------*/
00038 #ifndef __vtkGeoAlignedImageSource_h
00039 #define __vtkGeoAlignedImageSource_h
00040 
00041 #include "vtkGeovisCoreModule.h" // For export macro
00042 #include "vtkGeoSource.h"
00043 
00044 class vtkGeoImageNode;
00045 class vtkImageData;
00046 class vtkMultiBlockDataSet;
00047 
00048 class VTKGEOVISCORE_EXPORT vtkGeoAlignedImageSource : public vtkGeoSource
00049 {
00050 public:
00051   static vtkGeoAlignedImageSource *New();
00052   vtkTypeMacro(vtkGeoAlignedImageSource, vtkGeoSource);
00053   void PrintSelf(ostream& os, vtkIndent indent);
00054 
00056   virtual bool FetchRoot(vtkGeoTreeNode* node);
00057 
00059   virtual bool FetchChild(vtkGeoTreeNode* parent, int index, vtkGeoTreeNode* child);
00060 
00062 
00063   vtkGetObjectMacro(Image, vtkImageData);
00064   virtual void SetImage(vtkImageData* image);
00066 
00068 
00069   vtkSetVector2Macro(LatitudeRange, double);
00070   vtkGetVector2Macro(LatitudeRange, double);
00071   vtkSetVector2Macro(LongitudeRange, double);
00072   vtkGetVector2Macro(LongitudeRange, double);
00074 
00076 
00077   vtkSetClampMacro(Overlap, double, 0.0, VTK_DOUBLE_MAX);
00078   vtkGetMacro(Overlap, double);
00080 
00082 
00083   vtkSetMacro(PowerOfTwoSize, bool);
00084   vtkGetMacro(PowerOfTwoSize, bool);
00085   vtkBooleanMacro(PowerOfTwoSize, bool);
00087 
00088 protected:
00089   vtkGeoAlignedImageSource();
00090   ~vtkGeoAlignedImageSource();
00091 
00092   void CropImageForNode(vtkGeoImageNode* node, vtkImageData* image);
00093   int PowerOfTwo(int val);
00094 
00095   vtkImageData* Image;
00096   vtkMultiBlockDataSet* LevelImages;
00097   double LatitudeRange[2];
00098   double LongitudeRange[2];
00099   double Overlap;
00100   bool PowerOfTwoSize;
00101 
00102   //BTX
00103   class vtkProgressObserver;
00104   vtkProgressObserver* ProgressObserver;
00105   //ETX
00106 
00107 private:
00108   vtkGeoAlignedImageSource(const vtkGeoAlignedImageSource&);  // Not implemented.
00109   void operator=(const vtkGeoAlignedImageSource&);  // Not implemented.
00110 };
00111 
00112 #endif