www.pudn.com > Spere.rar > SpereView.h
// SpereView.h : interface of the CSpereView class
//
/////////////////////////////////////////////////////////////////////////////
#if !defined(AFX_SPEREVIEW_H__EC23865C_A664_48C7_92D0_9F2B5066E37B__INCLUDED_)
#define AFX_SPEREVIEW_H__EC23865C_A664_48C7_92D0_9F2B5066E37B__INCLUDED_
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
#include "gl\gl.h"
#include "gl\glu.h"
#include "OpenGL.h" // Added by ClassView
class CSpereView : public CView
{
protected: // create from serialization only
CSpereView();
DECLARE_DYNCREATE(CSpereView)
// Attributes
public:
CSpereDoc* GetDocument();
// Operations
public:
// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CSpereView)
public:
virtual void OnDraw(CDC* pDC); // overridden to draw this view
virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
virtual BOOL Create(LPCTSTR lpszClassName, LPCTSTR lpszWindowName, DWORD dwStyle, const RECT& rect, CWnd* pParentWnd, UINT nID, CCreateContext* pContext = NULL);
protected:
virtual BOOL OnPreparePrinting(CPrintInfo* pInfo);
virtual void OnBeginPrinting(CDC* pDC, CPrintInfo* pInfo);
virtual void OnEndPrinting(CDC* pDC, CPrintInfo* pInfo);
virtual void CalcWindowRect(LPRECT lpClientRect, UINT nAdjustType = adjustBorder);
//}}AFX_VIRTUAL
// Implementation
public:
void SetWindowPixelFormat();
HDC m_hDC;
HWND hWnd;
COpenGL* m_pOpenGL;
HGLRC m_hGLContext;
float m_fAngleZ;
float m_fAngleY;
float m_fAngleX;
void DrawSpere();
virtual ~CSpereView();
#ifdef _DEBUG
virtual void AssertValid() const;
virtual void Dump(CDumpContext& dc) const;
#endif
protected:
// Generated message map functions
protected:
//{{AFX_MSG(CSpereView)
afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);
afx_msg void OnSize(UINT nType, int cx, int cy);
afx_msg void OnCancelMode();
afx_msg void OnCaptureChanged(CWnd *pWnd);
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
};
#ifndef _DEBUG // debug version in SpereView.cpp
inline CSpereDoc* CSpereView::GetDocument()
{ return (CSpereDoc*)m_pDocument; }
#endif
/////////////////////////////////////////////////////////////////////////////
//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
#endif // !defined(AFX_SPEREVIEW_H__EC23865C_A664_48C7_92D0_9F2B5066E37B__INCLUDED_)