raytraceview.h
来自「蒙特卡罗方法可以有效地解决复杂的工程问题」· C头文件 代码 · 共 76 行
H
76 行
// RayTraceView.h : interface of the CRayTraceView class
//
/////////////////////////////////////////////////////////////////////////////
#if !defined(AFX_RAYTRACEVIEW_H__6C3A335E_C063_4577_9A57_9951BE5D59C7__INCLUDED_)
#define AFX_RAYTRACEVIEW_H__6C3A335E_C063_4577_9A57_9951BE5D59C7__INCLUDED_
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
#include "RayTraceDoc.h"
class CRayTraceView : public CView
{
protected: // create from serialization only
CRayTraceView();
DECLARE_DYNCREATE(CRayTraceView)
// Attributes
public:
CRayTraceDoc* GetDocument();
CScene scene; //场景成员
CString m_strPath; //存放程序路径
int m_nScene; //场景数目计数
CWinThread *m_pDrawThread;
// Operations
public:
// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CRayTraceView)
public:
virtual void OnDraw(CDC* pDC); // overridden to draw this view
//}}AFX_VIRTUAL
// Implementation
public:
void StartThread();
void RayTracing(); //第一场景绘制函数
void RayTracing2(); //第二场景绘制函数
void SavePicture(CString strPath); //保存当前场景为位图
virtual ~CRayTraceView();
#ifdef _DEBUG
virtual void AssertValid() const;
virtual void Dump(CDumpContext& dc) const;
#endif
protected:
bool m_bDrawing; //正在绘制标志
// Generated message map functions
protected:
//{{AFX_MSG(CRayTraceView)
afx_msg void OnRtRaytracing();
afx_msg void OnRtSet();
afx_msg void OnSize(UINT nType, int cx, int cy);
afx_msg void OnRtCartoon();
afx_msg void OnUpdateRtRaytracing(CCmdUI* pCmdUI);
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
};
#ifndef _DEBUG // debug version in RayTraceView.cpp
inline CRayTraceDoc* CRayTraceView::GetDocument()
{ return (CRayTraceDoc*)m_pDocument; }
#endif
/////////////////////////////////////////////////////////////////////////////
//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
#endif // !defined(AFX_RAYTRACEVIEW_H__6C3A335E_C063_4577_9A57_9951BE5D59C7__INCLUDED_)
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?