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.

75 lines
2.4 KiB
C++

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

//////////////////////////////////////////////////////////////////////////////
//文件: DFDraw补充绘图元素接口类
//主要功能:
//
//程序编写: 2005-12-07
//
//
/////////////////////////////////////////////////////////////////////////////
#pragma once
#include ".\sectionmath.h"
#include "MxnFormat/SeisBuilder3D.h"
//对于COtherDraw::Exchange(int message,char *Data);处在结果文件显示状态
//message=1,Data为double[2],进入为坐标返回线号道号其中一个数据除1e20为实际值
//message=2,画线或道Data顺序对应为x,y,CDC *,SCreen *
//message=3,删除区域内线Data为CCurve *
//message=4,改变结果文件名Data为CString *,为新的结果文件
//message=5,获得结果文件名(CString *m_result)
//message=6,(int stepx,int stepy,int width,int steprx,int stepry,int IsQuick) get
//message=7,(int stepx,int stepy,int width,int steprx,int stepry,int IsQuick) write
//message=8,(double m,double n) return x=m,n=y;
// 补充绘图元素接口
#define OtherDraw_FMN 202 //绘制f(m,n)图形其中x=x(m,n),y=y(m,n),z=z(m,n),为参数形式曲面方程
#define OtherDraw_OffsetX 204 //COffset
class AFX_EXT_CLASS COtherDraw
{
public:
COtherDraw(void);
virtual ~COtherDraw(void);
int m_type;
void* pValue;
CString name;
CColorBase *pColor;
virtual void Serialize(CArchive& ar);
virtual int Read(CFile& fr, CString str);
virtual int Write(CFile& fw);
virtual int Draw(CDC* pDC, CScreenXY& sr,void DrawCurve(CCurve &curve));
virtual int IsInRange(double& xmin, double& xmax, double& ymin, double& ymax);
virtual void GetRange(double& xmin, double& xmax, double& ymin, double& ymax);
virtual void GetRange(CPoint3D& minPoint, CPoint3D& maxPoint);
//将三维解释工区转换为新的三维地震剖面索引文件
bool FmnToSeisIndex3D(OUT CSeisBuilder3D& cubeBuilder);
static int IsOtherType(CString str);
static int IsOtherType(int type);
void GetRange(double& zmin, double& zmax);
void *Exchange(int message,char *Data);
void Clear(void);
void Offset(double dx, double dy);
void operator=(const COtherDraw& od);
void ScaleCoor(double xs, double ys, double dx, double dy);
void ScaleProperty(double sx, double sy);
};
class AFX_EXT_CLASS CGlobalFun
{
public:
CGlobalFun() {}
static int DeleteResult(CString m_result,CString m_xf,CString m_yf,CCurve *pCurve);
static int GetMN(double &x,double &y,CString m_fx,CString m_fy);
static void SetBeginLineCdp(int bline,int bcdp);
static void GetBeginLineCdp(int &bline,int &bcdp);
};