28 #include <QStringList>
30 #include <QXmlDefaultHandler>
35 class QXmlStreamWriter;
37 #include "ControlList.h"
39 #include "GuiCameraList.h"
40 #include "ImageList.h"
41 #include "ShapeList.h"
43 #include "XmlStackedHandler.h"
46 class BundleSolutionInfo;
50 class CorrelationMatrix;
129 Image *image(QString
id);
131 Shape *shape(QString
id);
134 bool isTemporaryProject()
const;
136 const WorkOrder *lastNotUndoneWorkOrder()
const;
137 QString
name()
const;
141 QUndoStack *undoStack();
142 void waitForImageReaderFinished();
143 void waitForShapeReaderFinished();
151 static QString
cnetRoot(QString projectRoot);
184 void save(
FileName newPath,
bool verifyPathDoesntExist =
true);
188 template<
typename Data>
void warn(QString text, Data relevantData);
190 void warn(QString text);
268 void addTargetsFromImportedImagesToProject(
ImageList *imageList);
269 void addCamerasFromImportedImagesToProject(
ImageList *imageList);
282 ControlList *createOrRetrieveControlList(QString name);
283 ImageList *createOrRetrieveImageList(QString name);
284 ShapeList *createOrRetrieveShapeList(QString name);
287 QString nextImageListGroupName();
290 void save(QXmlStreamWriter &stream,
FileName newProjectRoot)
const;
294 void storeWarning(QString text);
295 void storeWarning(QString text,
const ImageList &relevantData);
307 virtual bool startElement(
const QString &namespaceURI,
const QString &localName,
308 const QString &qName,
const QXmlAttributes &atts);
309 virtual bool endElement(
const QString &namespaceURI,
const QString &localName,
310 const QString &qName);
325 QDir m_currentCnetFolder;
326 QPointer<Directory> m_directory;
333 QPointer<Control> m_activeControl;
334 QPointer<ImageList> m_activeImageList;
360 QPointer<ImageReader> m_imageReader;
362 bool m_isTemporaryProject;
364 int m_numImagesCurrentlyReading;
367 QMutex *m_imageReadingMutex;
369 int m_numShapesCurrentlyReading;
370 QMutex *m_shapeMutex;
371 QPointer<ShapeReader> m_shapeReader;
372 QMutex *m_shapeReadingMutex;
374 QUndoStack m_undoStack;
This represents an ISIS control net in a project-based GUI interface.
Internalizes a list of shapes and allows for operations on the entire list.
QString targetBodyRoot() const
Accessor for the root directory of the target body data.
QDir addImageFolder(QString prefix)
Create and return the name of a folder for placing images.
Internalizes a list of images and allows for operations on the entire list.
void controlClosed(QObject *control)
A control is being deleted from the project.
The main project for cnetsuite.
~Project()
Clean up the project.
QString name() const
Get the project's GUI name.
File name manipulation and expansion.
QList< WorkOrder * > workOrderHistory()
Get the entire list of work orders that have executed.
Container class for BundleAdjustment results.
QMutex * mutex()
Return mutex used for Naif calls.
QString bundleSolutionInfoRoot() const
Accessor for the root directory of the results data.
Maintains a list of Controls so that control nets can easily be copied from one Project to another...
void controlListDeleted(QObject *controlList)
An control list is being deleted from the project.
void open(QString)
Open the project at the given path.
void saveHistory(QXmlStreamWriter &stream) const
Serialize the work orders into the given XML.
void addControl(Control *control)
Add the given Control's to the current project.
void controlListAdded(ControlList *controls)
apparently not used?
void targetBodyClosed(QObject *targetBodyObj)
A target body is being deleted from the project.
Q_DECLARE_METATYPE(Isis::Cube *)
This allows Cube *'s to be stored in a QVariant.
List for holding TargetBodies.
Control * activeControl()
Return the Active Control (control network)
QString cnetRoot() const
Get where control networks ought to be stored inside the project.
void projectLoaded(Project *)
Emitted when project loaded receivers: CNetSuiteMainWindow, Directory, HistoryTreeWidget.
QString resultsRoot() const
Accessor for the root directory of the results data.
void createFolders()
This creates the project root, image root, and control net root directories.
void relocateProjectRoot(QString newRoot)
This is called when the project is moved.
static QStringList images(QStringList)
Verify that the input fileNames are image files.
void addBundleSolutionInfo(BundleSolutionInfo *bundleSolutionInfo)
Add the given BundleSolutionInfo to the current project.
void saveWarnings(QXmlStreamWriter &stream) const
Serialize the warnings into the given XML.
QString shapeDataRoot() const
Accessor for the root directory of the shape model data.
void addToProject(WorkOrder *)
Run the work order and stores it in the project.
void imageClosed(QObject *image)
An image is being deleted from the project.
Parent class for anything that performs an action in Project.
void bundleSolutionInfoAdded(BundleSolutionInfo *bundleSolutionInfo)
Emitted when new BundleSolutionInfo available from jigsaw receivers: ProjectTreeWidget (TODO: should ...
void shapeListDeleted(QObject *shapeList)
A shape model list is being deleted from the project.
void shapeClosed(QObject *shape)
A shape model is being deleted from the project.
void deleteAllProjectFiles()
Delete all of the files, that this project stores, from disk.
Container class for BundleAdjustment settings.
XML Handler that parses XMLs in a stack-oriented way.
void guiCamerasAdded(GuiCameraList *targets)
Emitted when new GuiCamera objects added to project receivers: Directory.
ImageList * activeImageList()
Returns the active ImageList.
void controlAdded(Control *control)
Emitted when new Control added to Project receivers: ProjectTreeWidget.
This represents a cube in a project-based GUI interface.
QDir addBundleSolutionInfoFolder(QString folder)
Create and return the name of a folder for placing BundleSolutionInfo.
void projectRelocated(Project *)
Emitted when project location moved receivers: Control, BundleSolutionInfo, Image, TargetBody.
Directory * directory() const
Returns the directory associated with this Project.
void imageListDeleted(QObject *imageList)
An image list is being deleted from the project.
void addShapes(QStringList shapeFiles)
Read the given shape model cube file names as Images and add them to the project. ...
QList< QAction * > userPreferenceActions()
Get a list of configuration/settings actions related to reading images into this Project.
void shapesAdded(ShapeList *shapes)
Emitted when new shape model images are available.
void addImages(QStringList imageFiles)
Read the given cube file names as Images and add them to the project.
QDir addShapeFolder(QString prefix)
Create and return the name of a folder for placing shape models.
List of GuiCameras saved as QSharedPointers.
void nameChanged(QString newName)
Emitted when project name is changed receivers: ProjectTreeWidget.
void imagesAdded(ImageList *images)
Emitted when new images are available.
void setName(QString newName)
Change the project's name (GUI only, doesn't affect location on disk).
This represents a shape in a project-based GUI interface.
void bundleSolutionInfoClosed(QObject *bundleSolutionInfo)
A BundleSolutionInfo object is being deleted from the project.
QMap< QString, Control * > * m_idToControlMap
This variable will probably go away when we add the bundle results object because it will be under: B...
void targetsAdded(TargetBodyList *targets)
Emitted when new TargetBody objects added to project receivers: Directory.
QString projectRoot() const
Get the top-level folder of the project.
QDir addCnetFolder(QString prefix)
Create and return the name of a folder for placing control networks.
void setActiveImageList(ImageList *)
Set the Active ImageList.
void setActiveControl(Control *)
Set the Active Control (control network)
QString imageDataRoot() const
Accessor for the root directory of the image data.
Project(Directory &directory, QObject *parent=0)
Create a new Project.