www.pudn.com > lgq.rar > lgqView.h, change:2006-01-19,size:2976b


// lgqView.h : interface of the CLgqView class 
// 
///////////////////////////////////////////////////////////////////////////// 
 
#if !defined(AFX_LGQVIEW_H__ADE4B9C0_9EF5_43E7_9938_C6A7B856CD8F__INCLUDED_) 
#define AFX_LGQVIEW_H__ADE4B9C0_9EF5_43E7_9938_C6A7B856CD8F__INCLUDED_ 
 
#if _MSC_VER > 1000 
#pragma once 
#endif // _MSC_VER > 1000 
 
 
class CLgqView : public CView 
{ 
protected: // create from serialization only 
	CLgqView(); 
	DECLARE_DYNCREATE(CLgqView) 
 
// Attributes 
public: 
	CLgqDoc* GetDocument(); 
 
// Operations 
public: 
 
// Overrides 
	// ClassWizard generated virtual function overrides 
	//{{AFX_VIRTUAL(CLgqView) 
	public: 
	virtual void OnDraw(CDC* pDC);  // overridden to draw this view 
	virtual BOOL PreCreateWindow(CREATESTRUCT& cs); 
	protected: 
	virtual BOOL OnPreparePrinting(CPrintInfo* pInfo); 
	virtual void OnBeginPrinting(CDC* pDC, CPrintInfo* pInfo); 
	virtual void OnEndPrinting(CDC* pDC, CPrintInfo* pInfo); 
	//}}AFX_VIRTUAL 
 
// Implementation 
public: 
	virtual ~CLgqView(); 
 
	///////////////////////////////添加成员函数与成员变量 
	BOOL RenderScene(); 
	BOOL SetupPixelFormat(void); 
	void SetLogicalPalette(void); 
	BOOL InitializeOpenGL(CDC* pDC); 
 
	BOOL Read(CString filename); 
	void DrawDem(); 
	 
 
	BOOL  LoadTexture2(LPCTSTR fileName); 
	 
	GLuint m_texName; // Name of bound texture. 
	BOOL  CreateTexture(UINT &texture, LPSTR strFileName); 
	void  CreateSkyBox(float x, float y, float z, float width, float height, float length); 
 
	float Version,Alpha,X0,Y0,DX,DY; 
	int  m_dRow,m_dCol; 
	float  m_dDX,m_dDY; 
 
    float dx,dy,m_dX0,m_dY0; 
 
    int Compress,Row,Col,Hzoom,MinV,MaxV; 
	char DataMark[3],Unit,ValueType[7];  
	int Maxhight,Minhight; 
//	int i; 
    float *m_hight; 
	float z; 
	float x; 
	float y; 
	BOOL  m_display; 
 
	HGLRC    m_hRC;          //////绘制描述表 
	HPALETTE m_hPalette;     //////调色板 
	CDC*     m_pDC;          //////设备描述表 
 
#ifdef _DEBUG 
	virtual void AssertValid() const; 
	virtual void Dump(CDumpContext& dc) const; 
#endif 
 
protected: 
 
	float Scale; 
	float LH_Rate; 
	BOOL m_rotate; 
	BOOL m_texture; 
	 
 
// Generated message map functions 
protected: 
	//{{AFX_MSG(CLgqView) 
	afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct); 
	afx_msg void OnDestroy(); 
	afx_msg void OnSize(UINT nType, int cx, int cy); 
	afx_msg void OnTimer(UINT nIDEvent); 
	afx_msg void OnFileOpen(); 
	afx_msg void OnKeyDown(UINT nChar, UINT nRepCnt, UINT nFlags); 
	afx_msg void Onshowdem(); 
	//}}AFX_MSG 
	DECLARE_MESSAGE_MAP() 
}; 
 
#ifndef _DEBUG  // debug version in lgqView.cpp 
inline CLgqDoc* CLgqView::GetDocument() 
   { return (CLgqDoc*)m_pDocument; } 
#endif 
 
///////////////////////////////////////////////////////////////////////////// 
 
//{{AFX_INSERT_LOCATION}} 
// Microsoft Visual C++ will insert additional declarations immediately before the previous line. 
 
#endif // !defined(AFX_LGQVIEW_H__ADE4B9C0_9EF5_43E7_9938_C6A7B856CD8F__INCLUDED_)