94 lines
3.0 KiB
C++
94 lines
3.0 KiB
C++
#ifndef COPTION_2D_GEOMETRYDLG_H_20190319
|
|
#define COPTION_2D_GEOMETRYDLG_H_20190319
|
|
|
|
#pragma once
|
|
#include "afxcmn.h"
|
|
#include "CtrlProtocolDef.h"
|
|
|
|
// COption2DGeometryDlg 对话框
|
|
|
|
class COption2DGeometryDlg : public CDialog
|
|
{
|
|
DECLARE_DYNAMIC(COption2DGeometryDlg)
|
|
|
|
public:
|
|
static COption2DGeometryDlg* GetInstance();
|
|
virtual BOOL OnInitDialog();
|
|
// 对话框数据
|
|
enum { IDD = IDD_DIALOG_OPTION_2D_GEOMETRY };
|
|
//从界面添加坐标,添加borehole或者surface坐标点
|
|
void AddCoordinatesPoints(EN_COORDINATES_TYPE eType,std::vector<STBoreHolePoints> vecNewPoints);
|
|
//从Geomative坐标文件添加坐标,用于还原之前List列表
|
|
void AddNoSortCoordinatesFromFile(std::vector<STBoreHolePoints> vecNewPoints);
|
|
//删除已有点
|
|
void DeleteCoordinatesPoint();
|
|
//获取所有电极坐标,没有排序的
|
|
std::vector<STBoreHolePoints> GetAllCoordinatesPoints()
|
|
{
|
|
return m_vecNoSortAllPoints;
|
|
}
|
|
|
|
UINT32 GetAllCoordinatesPointsCount()
|
|
{
|
|
return m_vecNoSortAllPoints.size();
|
|
}
|
|
|
|
//获取排序后的关于孔的坐标信息
|
|
std::map<STWellPoints, std::vector<STBoreHolePoints>> GetBoreholeCoordinates()
|
|
{
|
|
return m_mapBoreholeCoordinates;
|
|
}
|
|
|
|
//获取排序后的关于地表的坐标信息
|
|
std::vector<STBoreHolePoints> GetSurfaceCoordinates()
|
|
{
|
|
return m_vecSurfaceCoordinates;
|
|
}
|
|
|
|
void AddElecCoordinatesInfo(STBoreHoleParam stBoreHoleParam)
|
|
{
|
|
m_vecAllElecCoordinatesInfo.push_back(stBoreHoleParam);
|
|
}
|
|
|
|
//获取所有测线的电极坐标及电极间距
|
|
std::vector<STBoreHoleParam> GetAllElecCoordinatesInfo()
|
|
{
|
|
return m_vecAllElecCoordinatesInfo;
|
|
}
|
|
|
|
void SetElectrodeDistance(float fElecDistance)
|
|
{
|
|
m_fElecDistance = fElecDistance;
|
|
}
|
|
|
|
float GetElectrodeDistance()
|
|
{
|
|
return m_fElecDistance;
|
|
}
|
|
protected:
|
|
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV 支持
|
|
void ShowCoordinatesPoints();//显示borehole或者surface坐标点
|
|
DECLARE_MESSAGE_MAP()
|
|
|
|
afx_msg void OnBnClickedBtnSort();
|
|
afx_msg void OnBnClickedSaveGeometry();
|
|
afx_msg void OnBnClickedBtnClearAll();
|
|
|
|
void AddBoreholePointToVector(std::vector<STBoreHolePoints> vecNewPoints); //将坐标点排序添加到井下集合
|
|
void AddSurfacePointsToVector(std::vector<STBoreHolePoints> vecNewPoints); //将坐标点排序添加到地表集合
|
|
void DeletePointsToVector(); //删除集合的数据
|
|
private:
|
|
COption2DGeometryDlg(CWnd* pParent = NULL); // 标准构造函数
|
|
virtual ~COption2DGeometryDlg();
|
|
|
|
CListCtrl m_geometryList;
|
|
std::vector<STBoreHolePoints> m_vecNoSortAllPoints; //未排序的集合用于显示到列表
|
|
|
|
//用户计算脚本
|
|
map<STWellPoints, vector<STBoreHolePoints>> m_mapBoreholeCoordinates; //保存井下所有的点,,int存放X用于区分是否在同一个孔
|
|
std::vector<STBoreHolePoints> m_vecSurfaceCoordinates; //地表所有的点,只有一条测线
|
|
std::vector<STBoreHoleParam> m_vecAllElecCoordinatesInfo; //获取所有电极坐标信息
|
|
float m_fElecDistance; //保存测井的电极间距
|
|
};
|
|
|
|
#endif |