JunkBox_Win_Lib 1.5.3
Loading...
Searching...
No Matches
GlProcView.h
Go to the documentation of this file.
1#pragma once
2
3#ifdef ENABLE_OPENGL
4
5
6#include "GlBaseClass.h"
7
8#include <gl/glew.h>
9#include <gl/glut.h>
10#include <gl/glext.h>
11#include <gl/wglew.h>
12//#include <GL/glaux.h>
13
14
15typedef void (*GL_PPROC_VIEW_FUNC)(void);
16
17
18//
19namespace jbxwl {
20
21
22class CGlProcView : public CGlBaseView
23{
24 DECLARE_DYNCREATE(CGlProcView)
25
26protected:
27 CGlProcView();
28 virtual ~CGlProcView();
29
30public:
31// RECT renderRect;
32 //
33 GL_PPROC_VIEW_FUNC initFunc;
34 GL_PPROC_VIEW_FUNC dispFunc;
35 GL_PPROC_VIEW_FUNC postFunc;
36
37 void SetInitFunc(GL_PPROC_VIEW_FUNC func) { initFunc = func;}
38 void SetDispFunc(GL_PPROC_VIEW_FUNC func) { dispFunc = func;}
39 void SetPostFunc(GL_PPROC_VIEW_FUNC func) { postFunc = func;}
40
41// オペレーション
42public:
43// virtual void ClearObject(void);
44 virtual void SetState(void) {}
45 virtual void InitObject(void) { SetState();}
46 virtual void ExecRender(void);
47 virtual void OnDraw(CDC* pDC) { CGlBaseView::OnDraw(pDC);}
48
49// オーバーライド
50
51 //{{AFX_VIRTUAL(CGlProcView)
52 public:
53 virtual void OnInitialUpdate();
54 //}}AFX_VIRTUAL
55
56#ifdef _DEBUG
57 virtual void AssertValid() const;
58#ifndef _WIN32_WCE
59 virtual void Dump(CDumpContext& dc) const;
60#endif
61#endif
62
63protected:
64
65 DECLARE_MESSAGE_MAP()
66public:
67 afx_msg void OnSize(UINT nType, int cx, int cy);
68 afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);
69 afx_msg void OnDestroy();
70};
71
72
73} // namespace
74
75
76#endif // ENABLE_OPENGL
77