Isis Developer Reference
MosaicController.h
Go to the documentation of this file.
1 #ifndef MosaicWidgetController_H
2 #define MosaicWidgetController_H
3 
4 #include <QObject>
5 
6 #include <QPointer>
7 
8 class QAction;
9 template <typename A> class QFutureWatcher;
10 template <typename A> class QList;
11 class QMenu;
12 class QMutex;
13 class QProgressBar;
14 class QSettings;
15 class QStatusBar;
16 
17 // This is required since we have a slot with a QStringList
18 #include <QStringList>
19 
20 // This is the parent of the inner class
21 #include <functional>
22 
23 #include "ImageList.h"
24 #include "PvlObject.h"
25 #include "MosaicSceneWidget.h"
26 #include "ImageFileListWidget.h"
27 
28 namespace Isis {
29  class ControlNet;
30  class FileName;
31  class ImageReader;
32  class MosaicSceneWidget;
33  class ProgressBar;
34  class PvlObject;
35 
67  class MosaicController : public QObject {
68  Q_OBJECT
69 
70  public:
71  MosaicController(QStatusBar *status, QSettings &settings);
72  virtual ~MosaicController();
73 
75  return m_scene;
76  }
77 
79  return m_worldScene;
80  }
81 
83  return m_fileList;
84  }
85 
86  void addExportActions(QMenu &fileMenu);
87 
89  void saveProject();
90 
92  void saveSettings(QSettings &settings);
93 
94  signals:
98  void imagesAdded(ImageList images);
99  void imagesAdded(ImageList *images);
100 
102 
103  public slots:
104  void saveProject(QString filename);
105  void readProject(QString filename);
106  void openImages(QStringList filenames);
107  void openProjectImages(PvlObject projectImages);
108 
109  private slots:
110  void changeMaxThreads();
111  void imageClosed(QObject * image);
112  void imagesReady(ImageList);
113  void saveList();
114 
115  private:
116  void applyMaxThreadCount();
117  void convertV1ToV2(Pvl &project);
118 
119  private:
120  ImageList m_images;
121 
122  QPointer<ImageFileListWidget> m_fileList;
123  QPointer<MosaicSceneWidget> m_scene;
124  QPointer<MosaicSceneWidget> m_worldScene;
125  QPointer<ImageReader> m_imageReader;
126 
127  int m_maxThreads;
128 
129  // Cameras are not re-entrant and so this mutex will make sure they
130  // aren't overly abused
131  QMutex *m_mutex;
132  };
133 }
134 
135 #endif
136 
FileName.h
QWidget
QProgressBar
Cube.h
Isis::ImageDisplayProperties::FootprintViewProperties
@ FootprintViewProperties
Every display property for footprint views, provided for convenience.
Definition: ImageDisplayProperties.h:111
Isis::PvlObject
Contains Pvl Groups and Pvl Objects.
Definition: PvlObject.h:61
MosaicSceneWidget.h
QList< QAction * >
Isis::MosaicController::imagesAdded
void imagesAdded(ImageList images)
Emitted when new images are available.
Isis::MosaicController::getSettingsActions
QList< QAction * > getSettingsActions()
Definition: MosaicController.cpp:131
Isis::MosaicController::saveProject
void saveProject()
ImageFileListWidget.h
Isis::IException::Unknown
@ Unknown
A type of error that cannot be classified as any of the other error types.
Definition: IException.h:118
QMenu
Isis::ImageFileListWidget
A colored, grouped cube list.
Definition: ImageFileListWidget.h:64
Isis::MosaicController::imagesAdded
void imagesAdded(ImageList *images)
Isis::ImageList::append
void append(Image *const &value)
Appends an image to the image list.
Definition: ImageList.cpp:153
Isis::TextFile
Provides access to sequential ASCII stream I/O.
Definition: TextFile.h:38
Isis::MosaicSceneWidget
This widget encompasses the entire mosaic scene.
Definition: MosaicSceneWidget.h:153
Isis::Pvl
Container for cube-like labels.
Definition: Pvl.h:119
Isis::Image::fileName
QString fileName() const
Get the file name of the cube that this image represents.
Definition: Image.cpp:340
Isis::Pvl::write
void write(const QString &file)
Opens and writes PVL information to a file and handles the end of line sequence.
Definition: Pvl.cpp:130
Isis::ImageReader
Definition: ImageReader.h:43
QStringList
Isis::ImageList
Internalizes a list of images and allows for operations on the entire list.
Definition: ImageList.h:55
Isis::MosaicController
Definition: MosaicController.h:67
Isis::ImageList::setName
void setName(QString newName)
Set the human-readable name of this image list.
Definition: ImageList.cpp:703
Isis::MosaicController::allImagesClosed
void allImagesClosed()
Isis::ReadWrite
const int ReadWrite
Definition: Process.h:24
ControlNet.h
Isis::MosaicController::getMosaicScene
MosaicSceneWidget * getMosaicScene()
Definition: MosaicController.h:74
Pvl.h
_FILEINFO_
#define _FILEINFO_
Macro for the filename and line number.
Definition: IException.h:24
TextFile.h
Isis::MosaicController::getMosaicWorldScene
MosaicSceneWidget * getMosaicWorldScene()
Definition: MosaicController.h:78
DisplayProperties.h
Isis::MosaicController::openProjectImages
void openProjectImages(PvlObject projectImages)
Definition: MosaicController.cpp:162
Isis::PvlObject::findObject
PvlObjectIterator findObject(const QString &name, PvlObjectIterator beg, PvlObjectIterator end)
Find the index of object with a specified name, between two indexes.
Definition: PvlObject.h:274
Isis::MosaicController::saveSettings
void saveSettings(QSettings &settings)
Definition: MosaicController.cpp:146
Isis::MosaicController::openImages
void openImages(QStringList filenames)
Handle opening cubes by filename.
Definition: MosaicController.cpp:157
ImageList.h
Isis::Image
This represents a cube in a project-based GUI interface.
Definition: Image.h:107
Isis::IException
Isis exception class.
Definition: IException.h:91
Isis::PvlObject::hasObject
bool hasObject(const QString &name) const
Returns a boolean value based on whether the object exists in the current PvlObject or not.
Definition: PvlObject.h:323
ProgressBar.h
IException.h
Isis::MosaicController::MosaicController
MosaicController(QStatusBar *status, QSettings &settings)
MosaicWidget constructor.
Definition: MosaicController.cpp:44
Isis::MosaicController::readProject
void readProject(QString filename)
Definition: MosaicController.cpp:235
QFutureWatcher
This is free and unencumbered software released into the public domain.
Definition: AbstractTableModel.h:24
PvlObject.h
QMap< QString, QString >
MosaicController.h
Isis::MosaicController::getProgress
QProgressBar * getProgress()
Definition: MosaicController.cpp:109
Isis::Image::toPvl
PvlObject toPvl() const
Convert this Image to PVL.
Definition: Image.cpp:226
ImageReader.h
QObject
Isis::ImageList::erase
iterator erase(iterator pos)
Erases a single image from the image list.
Definition: ImageList.cpp:195
Isis::Projection
Base class for Map Projections.
Definition: Projection.h:155
QAction
Isis::MosaicController::~MosaicController
virtual ~MosaicController()
Free the allocated memory by this object.
Definition: MosaicController.cpp:80
Isis::MosaicController::addExportActions
void addExportActions(QMenu &fileMenu)
Add actions that are export-related to the menu.
Definition: MosaicController.cpp:91
Isis::MosaicController::getImageFileList
ImageFileListWidget * getImageFileList()
Definition: MosaicController.h:82
Isis
This is free and unencumbered software released into the public domain.
Definition: Apollo.h:16