Click here to Skip to main content
Click here to Skip to main content
Articles » Multimedia » OpenGL » General » Downloads
 
Add your own
alternative version

Basic Curves And Surfaces Modeler

, 18 Apr 2012 CPOL
A basic demo of modeling curves and surfaces in OpenGL.
cadsurfexe.zip
CadSurfexe
CadSurf.exe
VKGeom.dll
VKGraphic.dll
cadsurf_demo.zip
CadSurf.exe
cadsurf_src.zip
CadSurf_src
VKernel
VKGraphic
VKGraphic.dsp
VKGraphic.dsw
VKGraphic.plg
VKGeom
VKGeom.dsp
VKGeom.dsw
cadsurf
CadSurf.clw
CadSurf.dsp
cadsurf.dsw
Thumbs.db
res
bmp00001.bmp
cadsurf.ico
CADSURFDOC.ICO
new_splash.bmp
new_splash.PNG
new_splash_small.bmp
tb_geom.bmp
Thumbs.db
toolbar.bmp
toolbar1.bmp
untitled.bmp
XPStyle.manifest
CadSurf_VS2008.zip
CadSurf
cadsurf
CadSurf.suo
res
bmp00001.bmp
cadsurf.ico
CADSURFDOC.ICO
new_splash.bmp
new_splash.PNG
new_splash_small.bmp
tb_geom.bmp
Thumbs.db
toolbar.bmp
toolbar1.bmp
untitled.bmp
VKernel
VKGeom
VKGraphic
VKGraphic.plg
// MaterialDlg.cpp : implementation file
//

#include "stdafx.h"
#include "CadSurf.h"
#include "MaterialDlg.h"

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

/////////////////////////////////////////////////////////////////////////////
// CMaterialDlg dialog


CMaterialDlg::CMaterialDlg(CWnd* pParent /*=NULL*/)
	: CDialog(CMaterialDlg::IDD, pParent)
{
	//{{AFX_DATA_INIT(CMaterialDlg)
		// NOTE: the ClassWizard will add member initialization here
	//}}AFX_DATA_INIT
}


void CMaterialDlg::DoDataExchange(CDataExchange* pDX)
{
	CDialog::DoDataExchange(pDX);
	//{{AFX_DATA_MAP(CMaterialDlg)
		// NOTE: the ClassWizard will add DDX and DDV calls here
	//}}AFX_DATA_MAP
}


BEGIN_MESSAGE_MAP(CMaterialDlg, CDialog)
	//{{AFX_MSG_MAP(CMaterialDlg)
		// NOTE: the ClassWizard will add message map macros here
		ON_COMMAND_EX_RANGE(IDC_ALUM,IDC_BRUBBER, OnMaterial)
	//}}AFX_MSG_MAP
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// CMaterialDlg message handlers

BOOL CMaterialDlg::OnMaterial(UINT nID)
{
	switch(nID)
	{
	case IDC_ALUM :
		m_Matl = ALUMINIUM;
		break;
	case IDC_BRASS :
		m_Matl = BRASS;
		break;
	case IDC_PBRONZE :
		m_Matl = P_BRONZE;
		break;
	case IDC_CHROME :
		m_Matl = CHROME;
		break;
	case IDC_PCOPPER :
		m_Matl = P_COPPER;
		break;
	case IDC_GOLD :
		m_Matl = GOLD;
		break;
	case IDC_PEWTER :
		m_Matl = PEWTER;
		break;
	case IDC_SILVER :
		m_Matl = SILVER;
		break;
	case IDC_STEEL :
		m_Matl = STEEL;
		break;
	case IDC_EMERALD :
		m_Matl = EMERALD;
		break;
	case IDC_OBSIDIAN :
		m_Matl = OBSIDIAN;
		break;
	case IDC_PEARL :
		m_Matl = PEARL;
		break;
	case IDC_TURQUOISE :
		m_Matl = TURQUOISE;
		break;
	case IDC_BPLASTIC :
		m_Matl = PLASTIC;
		break;
	case IDC_BRONZE :
		m_Matl = BRONZE;
		break;
	case IDC_COPPER :
		m_Matl = COPPER;
		break;
	case IDC_PGOLD :
		m_Matl = P_GOLD;
		break;
	case IDC_PSILVER :
		m_Matl = P_SILVER;
		break;
	case IDC_JADE :
		m_Matl = JADE;
		break;
	case IDC_RUBY :
		m_Matl = RUBY;
		break;
	case IDC_BRUBBER :
		m_Matl = RUBBER;
		break;
	default:
		m_Matl = JADE;
		break;
	}
	return TRUE;
}

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, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

Share

About the Author

Sharjith
Engineer Tata Technologies Ltd
India India
Sharjith is a Mechanical Engineer with strong passion for Automobiles, Aircrafts and Software development.

| Advertise | Privacy | Mobile
Web03 | 2.8.141022.2 | Last Updated 18 Apr 2012
Article Copyright 2003 by Sharjith
Everything else Copyright © CodeProject, 1999-2014
Terms of Service
Layout: fixed | fluid