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.

161 lines
5.4 KiB
C

/**********************************************************************
* @file PostGraphProperty.h
* @brief
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-09
*********************************************************************/
#ifndef _PostGraphProperty_H
#define _PostGraphProperty_H
#include <QObject>
#include "PostGraphAdaptorAPI.h"
#include "FITK_Interface/FITKInterfaceCFDPost/FITKAbstractCFDPostData.h"
#define SolidColor "Solid Color"
namespace Interface
{
class FITKAbstractCFDPostData;
class PostGraphObjectBase;
enum class FITKPostDisplayType {
Post_Point, //点
Post_Edge, //线
Post_Face, //面
Post_FaceWithEdge, //带线的面
};
/**
* @brief
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-09
*/
class PostGraphAdaptorAPI PostGraphProperty : public QObject
{
Q_OBJECT;
public:
/**
* @brief
* @param[i] postData
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-09
*/
PostGraphProperty(PostGraphObjectBase* postGraphObj, FITKAbstractCFDPostData* postData);
/**
* @brief
* @return void
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-09
*/
~PostGraphProperty();
/**
* @brief
* @param[i] type 1: 2:
* @param[i] vaName
* @param[i] componentIndex
* @return void
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-09
*/
void setCurrentField(FITKPostFieldType type, QString fieldName, int componentIndex = -1);
/**
* @brief
* @param[o] type 1: 2:
* @param[o] filedName
* @param[o] componentIndex
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-10
*/
void getCurrentField(FITKPostFieldType& type, QString& filedName, int& componentIndex);
/**
* @brief
* @param[i] type
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-10
*/
void setCurrentDisplayType(FITKPostDisplayType type);
/**
* @brief
* @return FITKPostDisplayType
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-10
*/
FITKPostDisplayType getCurrentDisplayType();
/**
* @brief /
* setScalarBarWidgetIsShowScalarBarWidget
* /ScalarBarWidget
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-11
*/
void hideScalarBarWidget();
void showScalarBarWidget();
/**
* @brief
* @param[i] isShow
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-11
*/
void setScalarBarWidgetIsShow(bool isShow);
/**
* @brief ScalarBarWidget
* @return bool
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-11
*/
bool getScalarBarWidgetOnOrOff();
/**
* @brief ScalarBarWidget
* @return bool
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-11
*/
bool getScalarBarWidgetIsShow();
/**
* @brief
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-13
*/
void setOpacity(double opacity);
/**
* @brief
* @return double
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-13
*/
double getOpacity();
private:
/**
* @brief
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-12
*/
PostGraphObjectBase* _postGraphObj = nullptr;
/**
* @brief
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-09
*/
FITKAbstractCFDPostData* _postData = nullptr;
FITKPostDisplayType _displayType = FITKPostDisplayType::Post_Face;
FITKPostFieldType _fieldType = FITKPostFieldType::Post_None;
/**
* @brief
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-10
*/
QString _fieldName = SolidColor;
int _componentIndex = -1;
/**
* @brief
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-11
*/
bool _isShowScalarBar = true;
};
}
#endif