AtilaCalculatorSoftware  2.3.4
C++ Interface for Atila fem resources files
All Classes Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
MainWindow Class Reference

Qt main window. More...

#include <main_window.h>

Inheritance diagram for MainWindow:

Public Slots

void slotExit ()
 Stop the application. More...
 
void slotOpenFile ()
 Open and read object file, then render it. More...
 
void slotZoomArea ()
 Allow the user to select an area to zoom on. More...
 
void slotInteractWithObject ()
 Reset the interactor to allow object interaction after zoomArea. More...
 
void slotShowNodes ()
 Shows the objects node if toggled on checked, otherwise hide it. More...
 
void slotResetCamera ()
 Reset the camera view as default. More...
 

Public Member Functions

 MainWindow (char *dataDirectory)
 

Private Member Functions

void initAxes ()
 Initialize axes view. More...
 
void showResult (Result &result, const int &component)
 Load result and show elements. More...
 
void show3DPoly (Result &result, const int &component)
 Show the 3D polygon of the given result. More...
 
void showNodes ()
 Show the nodes of the result. More...
 
void loadBinaryData (const std::string &filename)
 Read binary data and load it, then print the scalars and show the object, also set the "Results" menu. More...
 
void unloadBinaryData ()
 Clear and destruct loaded binary data. More...
 
void setBinaryElements ()
 Add action item to "Elements" menu for each elements of the loaded meshes. More...
 
void clearBinaryElements ()
 Remove all actions of the "Elements" menu. More...
 
void setBinaryResults ()
 Add action item to "Results" menu for each component of each loaded results of binary data. More...
 
void clearBinaryResults ()
 Remove all actions of the "Results" menu. More...
 

Private Attributes

QString objectDirectory
 Path to directory that stores the objects to open. More...
 
vtkSmartPointer< vtkOrientationMarkerWidget > axesWidget
 Movable widget that shows the axes. More...
 
QStringListModel * informationListModel
 Information module model. More...
 
vtkProp * nodeActor = nullptr
 Actor of node showing. More...
 
BinaryDataWrapperbinary = nullptr
 Data imported from the current .res file. More...
 
ResultlastResult = nullptr
 Last loaded result. More...
 
int lastResultComponent = 0
 Last loaded result component. More...
 

Detailed Description

Qt main window.

Constructor & Destructor Documentation

◆ MainWindow()

MainWindow::MainWindow ( char *  dataDirectory)
explicit
Parameters
dataDirectoryThe path to the objects directory

Member Function Documentation

◆ clearBinaryElements()

void MainWindow::clearBinaryElements ( )
private

Remove all actions of the "Elements" menu.

◆ clearBinaryResults()

void MainWindow::clearBinaryResults ( )
private

Remove all actions of the "Results" menu.

◆ initAxes()

void MainWindow::initAxes ( )
private

Initialize axes view.

◆ loadBinaryData()

void MainWindow::loadBinaryData ( const std::string &  filename)
private

Read binary data and load it, then print the scalars and show the object, also set the "Results" menu.

See also
setBinaryResults
Parameters
filenamePath to the resource gzFile to read data from

◆ setBinaryElements()

void MainWindow::setBinaryElements ( )
private

Add action item to "Elements" menu for each elements of the loaded meshes.

◆ setBinaryResults()

void MainWindow::setBinaryResults ( )
private

Add action item to "Results" menu for each component of each loaded results of binary data.

◆ show3DPoly()

void MainWindow::show3DPoly ( Result result,
const int &  component 
)
private

Show the 3D polygon of the given result.

Parameters
resultResult read by the binary data
componentComponent to show

◆ showNodes()

void MainWindow::showNodes ( )
private

Show the nodes of the result.

Parameters
resultResult read by the binary data
componentComponent from which nodes will be read

◆ showResult()

void MainWindow::showResult ( Result result,
const int &  component 
)
private

Load result and show elements.

Parameters
resultResult read by the binary data
componentComponent to show

◆ slotExit

void MainWindow::slotExit ( )
slot

Stop the application.

◆ slotInteractWithObject

void MainWindow::slotInteractWithObject ( )
slot

Reset the interactor to allow object interaction after zoomArea.

◆ slotOpenFile

void MainWindow::slotOpenFile ( )
slot

Open and read object file, then render it.

◆ slotResetCamera

void MainWindow::slotResetCamera ( )
slot

Reset the camera view as default.

◆ slotShowNodes

void MainWindow::slotShowNodes ( )
slot

Shows the objects node if toggled on checked, otherwise hide it.

◆ slotZoomArea

void MainWindow::slotZoomArea ( )
slot

Allow the user to select an area to zoom on.

◆ unloadBinaryData()

void MainWindow::unloadBinaryData ( )
private

Clear and destruct loaded binary data.

Member Data Documentation

◆ axesWidget

vtkSmartPointer<vtkOrientationMarkerWidget> MainWindow::axesWidget
private

Movable widget that shows the axes.

◆ binary

BinaryDataWrapper* MainWindow::binary = nullptr
private

Data imported from the current .res file.

◆ informationListModel

QStringListModel* MainWindow::informationListModel
private

Information module model.

◆ lastResult

Result* MainWindow::lastResult = nullptr
private

Last loaded result.

◆ lastResultComponent

int MainWindow::lastResultComponent = 0
private

Last loaded result component.

◆ nodeActor

vtkProp* MainWindow::nodeActor = nullptr
private

Actor of node showing.

◆ objectDirectory

QString MainWindow::objectDirectory
private

Path to directory that stores the objects to open.


The documentation for this class was generated from the following files: