Click here to Skip to main content
15,892,674 members
Articles / Multimedia / OpenGL

CGLEnabledView - An MDI view class supporting OpenGL

Rate me:
Please Sign up or sign in to vote.
4.77/5 (26 votes)
30 Nov 19992 min read 228.9K   9.5K   55  
A plug-in view class that provides OpenGL support
// OGLInfoDlg.cpp : implementation file
//

#include "stdafx.h"
#include "TestGL.h"
#include "OGLInfoDlg.h"

#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif

/////////////////////////////////////////////////////////////////////////////
// COGLInfoDlg dialog


COGLInfoDlg::COGLInfoDlg(CWnd* pParent /*=NULL*/)
	: CDialog(COGLInfoDlg::IDD, pParent)
{
	//{{AFX_DATA_INIT(COGLInfoDlg)
	m_accel = _T("");
	m_extensions = _T("");
	m_rend = _T("");
	m_vendor = _T("");
	m_version = _T("");
	m_gluext = _T("");
	m_gluver = _T("");
	//}}AFX_DATA_INIT
}


void COGLInfoDlg::DoDataExchange(CDataExchange* pDX)
{
	CDialog::DoDataExchange(pDX);
	//{{AFX_DATA_MAP(COGLInfoDlg)
	DDX_Text(pDX, IDC_STATIC_ACCELERATION, m_accel);
	DDX_Text(pDX, IDC_STATIC_EXTENSIONS, m_extensions);
	DDX_Text(pDX, IDC_STATIC_RENDERER, m_rend);
	DDX_Text(pDX, IDC_STATIC_VENDOR, m_vendor);
	DDX_Text(pDX, IDC_STATIC_VERSION, m_version);
	DDX_Text(pDX, IDC_STATIC_GLUEXTENSIONS, m_gluext);
	DDX_Text(pDX, IDC_STATIC_GLUVERSION, m_gluver);
	//}}AFX_DATA_MAP
}


BEGIN_MESSAGE_MAP(COGLInfoDlg, CDialog)
	//{{AFX_MSG_MAP(COGLInfoDlg)
	ON_BN_CLICKED(IDC_DETAILS_BUT, OnDetailsBut)
	//}}AFX_MSG_MAP
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// COGLInfoDlg message handlers

void COGLInfoDlg::OnDetailsBut() 
{
	AfxMessageBox( m_detailstext, MB_OK|MB_ICONINFORMATION);	
}

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here


Written By
Software Developer (Senior)
Italy Italy
Male.
Living in Rome, Italy
Computer addict since 12 years old (first computer: Commodore 64).
Master degree in Computer Science.
Very interested in computer generated graphics both real time (mainly OpenGL) and photorealistic rendering.

Comments and Discussions