You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

141 lines
4.2 KiB
C

/**********************************************************************
* @file FITKAlgCGNSReader.h
* @brief VTKCGNS
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-25
*********************************************************************/
#ifndef _FITKAlgCGNSReader_H
#define _FITKAlgCGNSReader_H
#include "FITKInterfaceCFDPostAPI.h"
#include <vtkUnstructuredGridAlgorithm.h>
#include <vtkSetGet.h>
#include <QObject>
#include <QMultiHash>
class vtkDataSet;
namespace Interface
{
/**
* @brief VTKCGNS
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-25
*/
class FITKInterfaceCFDPostAPI FITKAlgCGNSReader :public vtkUnstructuredGridAlgorithm
{
vtkTypeMacro(FITKAlgCGNSReader, vtkUnstructuredGridAlgorithm);
public:
static FITKAlgCGNSReader* New();
void PrintSelf(ostream& os, vtkIndent indent);
/**
* @brief
* @param[i] fileName
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-25
*/
void setFileName(const QString fileName);
protected:
/**
* @brief
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-25
*/
FITKAlgCGNSReader();
/**
* @brief
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-25
*/
~FITKAlgCGNSReader();
/**
* @brief
* @param[i] port
* @param[i] info
* @return int
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-23
*/
int FillOutputPortInformation(int port, vtkInformation* info);
/**
* @brief
* @param[i] request
* @param[i] inputVector
* @param[i] outputVector
* @return int
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-23
*/
int ProcessRequest(vtkInformation* request, vtkInformationVector** inputVector, vtkInformationVector* outputVector);
/**
* @brief
* @param[i] request
* @param[i] inputVector
* @param[i] outputVector
* @return int
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-23
*/
int RequestData(vtkInformation* request, vtkInformationVector** inputVector, vtkInformationVector* outputVector);
private:
/**
* @brief
* @param[i] blockData
* @param[i] cuttentName
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-25
*/
void getBlocks(vtkDataObject* blockData, const char* cuttentName = "");
/**
* @brief datasetpoint
* @param[i] dataset
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-25
*/
void getPointArray(vtkDataSet* dataset);
/**
* @brief datasetcell
* @param[i] dataset
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-25
*/
void getCellArray(vtkDataSet* dataset);
private:
/**
* @brief
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-25
*/
QString _fileName = "";
/**
* @brief
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-25
*/
QList<vtkDataSet*> _blockList ={};
/**
* @brief pointtuple
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-25
*/
QHash<QString, int*> _pointDataArray{};
/**
* @brief celltuple
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-25
*/
QHash<QString, int*> _cellDataArray{};
QList<bool> _visibleStates = {};
QMultiHash<int, int> _reslationShip = {};
QStringList _blockNames = {};
QStringList _bcTypes = {};
};
}
#endif