#ifndef STRUCTDEFINE_H #define STRUCTDEFINE_H #pragma once #include "./NGraphExtend.h" ////////////////////////////////////////////////////////////////////////////// //主要功能: // 类型定义 ///////////////////////////////////////////////////////////////////////////// #pragma pack (1) //使用了对齐指令,引入其它类型定义.h时放置在此指令上面 #include #include #define SYMBOLSIZELITHO 8 #define SYMBOLSIZEFLUID 14 AFX_EXT_CLASS typedef struct INCLINEDWELLSTRUCT //斜井数据结构 { CString wellname; //井号 double x; //横坐标 double y; //纵坐标 double depth; //井斜深 double bevel; //井斜角 double azimuth; //真方位角 double x0; //投影横坐标 double y0; //投影纵坐标 double depthV; //井垂深 double disS; //视平移(相对井口的水平平移距离) } Struct_InclinedWell; typedef std::list< Struct_InclinedWell> INCLINEDWELLSTRUCTLIST; typedef struct TRACESTRUCT//道的两条轨迹数据结构 { CPoint2D pt; //点的逻辑坐标 double depth; //点对应的斜深 } Struct_Trace; class CTrackObj; typedef struct TRACKSORTSTRUCT //道排列结构体 { CTrackObj *pTrackObj; // 道对象指针 double fCenterX; // 道头中心点x double fCenterY; // 道头中心点y }Struct_TrackSort; class CTrackCurve; typedef struct CURVESORTSTRUCT { CTrackCurve *pCurve; // 曲线对象指针 int integer; // 对象左边界 } Struct_CurveSort; typedef struct SIGNSTRUCT //一个符号的索引区的数据结构 { char name[31]; //符号名 char fhdm[11]; long offset; //数据区偏移量 short length; //数据区长度 short CategoryCode; //图式种类代码 0:岩性符号; 1:含有物符号; 2:沉积构造符号 short SubCategoryCode; //图式子种类代码(保留) }Struct_Sign; typedef struct BLOCKSTRUCT //方波曲线属性结构体 { BOOL bUseData; //本方波区间的数据是否有效,如果bUseData=TRUE(有效数据),bUseData=FALSE(无效数据是 fValue=-9999) double fStartDep; //方波顶数据 double fEndDep; //方波底数据 double fValue; //方波幅度值 CString sSkeleton; //骨架属性 CString sFluid; //流体属性 BOOL bOutput; //输出属性 BLOCKSTRUCT & operator = (BLOCKSTRUCT &tmp) { bUseData = tmp.bUseData; fStartDep = tmp.fStartDep; fEndDep = tmp.fEndDep; fValue = tmp.fValue; sSkeleton = tmp.sSkeleton; sFluid = tmp.sFluid; bOutput = tmp.bOutput; return *this; } }Struct_Block; typedef struct SCrossSelDataDepth //交会图中创建的圈点区域内的数据的深度 { float* m_pdepthBuf;//深度缓冲 int m_bufSize; //缓冲大小 int m_DataSize; //数据大小 COLORREF m_Clr; //对应的圈点区域的颜色 SCrossSelDataDepth() { m_bufSize = 0; m_DataSize = 0; m_pdepthBuf = NULL; m_Clr = RGB(0,0,0); } ~ SCrossSelDataDepth() { if(m_pdepthBuf != NULL) { delete []m_pdepthBuf; m_pdepthBuf = NULL; } } }Struct_CrossSelDataDepth; typedef struct LITHBMPSTRUCT //岩性位图结构体 { CString name; char width; HBITMAP hsignal; }Struct_LithBmp; typedef struct LITHDATASTRUCT { float min; float max; CString name; CString clr; }Struct_LithData; typedef struct MICROFACIESSTRUCT { CString m_strMicroFacies; double m_dCorrelationDegree; }Struct_MicroFacies; typedef struct CURVESTRUCT { CString m_strCurve; CArray m_MicroFaciesDataArr; }Struct_Curve; typedef struct CURVEDATASTRUCT { char m_curveName[30]; //曲线形态名 char m_wxName[30]; //微相名 double m_fRlev; //采样间隔(.125) int m_nSample; //采样个数 double *m_depth; //对应深度 double *m_value; //曲线数值 }Struct_CurveData; typedef struct CURVEPATTERNSTRUCT { char m_curve[30]; //曲线名 CArray m_CurveDataArr; }Struct_CurvePattern; //单元表格结构体 struct CELLSTRUCT { GDFLOGFONT font; //字体 int linewidth[4]; //边线宽度:0不画 int lineclr[4]; //边线颜色:顺序上下左右 int nBackclr; //背景色索引号 int nTextClr; //文本颜色索引号 CString text; //文字 int span; //单元格跨越的列数:0不合并,1、2、3...代表合并索引号 int layout; //停靠状态 0居中,1居左,2居右 BOOL show; //绘制文字使用,临时变量 CELLSTRUCT() { font.m_dHeight = 15; font.m_dWidth = 6; for(int i=0; i<4; i++) { linewidth[i] = 0; lineclr[i] = 1; nBackclr = 1; nTextClr = 1; span = 0; layout = 0; show = TRUE; } } void operator=(CELLSTRUCT &cell) { font = cell.font; //字体 for(int i=0; i<4; i++) { linewidth[i] = cell.linewidth[i];//边线宽度:0不画 lineclr[i] = cell.lineclr[i];//边线颜色:顺序上下左右 } nBackclr = cell.nBackclr; //背景色索引号 nTextClr = cell.nTextClr; //文本颜色索引号 text = cell.text; //文字 span = cell.span; //单元格跨越的列数:0不合并,1、2、3...代表合并索引号 layout = cell.layout; //停靠状态 0居中,1居左,2居右 show = cell.show; //绘制文字使用,临时变量 } }; //岩样数据体 struct SAMPLESTRUCT { SAMPLESTRUCT() { num =0; Ca =0;Os=0;thick=0;Por=0;Perm = 0;} int num; //样品号 double thick; //厚度(部位) double Por; //孔隙度 double Perm; //渗透率 double Os; //饱和度 double Ca; //碳酸钙 //double V1; //数值1 //double V2; //数值2 //double V3; //数值3 //double V4; //数值4 //double V5; //数值5 }; //pcg数据结构体 struct PCG_WELLTEMPCOL //保存pcg格式中的井模板列的数据 { CString strDataRef; //索引 int mask; //属性(24567) int style; //显示样式(0) double width; //宽度 CString combName; //组合名称 BOOL combLeft; //是否左组合 BOOL combRight; //是否右组合 BOOL bComb; //是否组合 int combType; //组合类型0水平,1竖直 CString title; //标题(图栏) CRect8 combineRange; //组合头范围 GDFLOGFONTEXT logfont; PCG_WELLTEMPCOL* m_pParent; std::list wellTempColList; //井模块列子链表(嵌套) int fid; //在pcg文件中的顺序号,因为有的文件会有重名的道,因此加一个在pcg文件中读取的顺序号,以0开始 PCG_WELLTEMPCOL() { mask = 24567; style = 0; width = 100; combLeft = FALSE; combRight = FALSE; bComb = FALSE; combType = 0; m_pParent = NULL; fid = 0; }; ~PCG_WELLTEMPCOL() { //POSITION pos = wellTempColList.GetHeadPosition(); //while(pos != NULL) //{ // PCG_WELLTEMPCOL* wellcol = wellTempColList.GetNext(pos); // delete wellcol; //} }; void operator= (PCG_WELLTEMPCOL& wellcol) { strDataRef = wellcol.strDataRef; mask = wellcol.mask; style = wellcol.style; width = wellcol.width; combName = wellcol.combName; combLeft = wellcol.combLeft; combRight = wellcol.combRight; bComb = wellcol.bComb; combType = wellcol.combType; title = wellcol.title; combineRange = wellcol.combineRange; }; void Add(PCG_WELLTEMPCOL *p) { wellTempColList.push_back(p); p->m_pParent = this; }; PCG_WELLTEMPCOL* FindTrackInWellTempCol(CString str) { //POSITION pos = wellTempColList.GetHeadPosition(); //while(pos != NULL) //{ // PCG_WELLTEMPCOL* wellcol = wellTempColList.GetNext(pos); // if(wellcol->FindTrackInWellTempCol(str) != NULL) // return wellcol; //} std::list::iterator it = wellTempColList.begin(); for (; it != wellTempColList.end(); it++) { if ((*it)->FindTrackInWellTempCol(str) != NULL) return *it; } if(str == strDataRef && !str.IsEmpty()) return this; else return NULL; }; }; typedef std::vector PCG_WELLCOLARRAY; //井列数组 struct PCG_TRACECOL //保存pcg格式中道数据 { CString name; //名称 CString type; //道类型 int mask; //属性掩码 int style; //样式 int marco; //宏 int id; //ID double left; //左边距 double right; //右边距 CString mode; //模式(Log/Default) (True=log/False = default ,20170927) BOOL revers; //反转 COLORREF backColor; //背景色 double macroTop; //宏有效顶深 double macroBottom; //宏有效底深 int fillIndex; //充填符号索引号 BOOL backFill; //是否充填背景 int backFillIndex; //背景充填符号索引号 BOOL DrawHeadGrid; //是否绘制道头网格 double width; //道宽 CString showstyle; //显示风格 CString fillmode; //填充方式 double headmarkpos; //图头标注位置 double headtitlepos; //图标题位置 BOOL showline; //曲线道是否显示道头横线 BOOL HeadFill; //道头是否充填 BOOL bAutoCacluateRange ;//是否使用自动的范围计算 void Empty() { name.Empty(); type.Empty(); mask = 0; style = 0; marco = 0; id = -1; left = 0; right = 0; mode = "Default"; revers = FALSE; backColor = RGB(0,0,0); macroTop = 0; macroBottom = 0; fillIndex = 0; backFill = FALSE; backFillIndex = 0; DrawHeadGrid = FALSE; width = -1; showstyle = "Normal"; fillmode.Empty(); headmarkpos = 0.0; headtitlepos = 0.0; showline = TRUE; HeadFill = TRUE; bAutoCacluateRange = TRUE; } }; #pragma pack () #endif