3dObjectPropSheet.cpp
资源名称:gloop.zip [点击查看]
上传用户:shxiangxiu
上传日期:2007-01-03
资源大小:1101k
文件大小:2k
源码类别:
OpenGL
开发平台:
Visual C++
- /////////////////////////////////////////////////////////////////////////////
- // 3dObjectPropSheet.cpp : implementation file
- //
- // glOOP (OpenGL Object Oriented Programming library)
- // Copyright (c) Craig Fahrnbach 1997, 1998
- //
- // OpenGL is a registered trademark of Silicon Graphics
- //
- //
- // This program is provided for educational and personal use only and
- // is provided without guarantee or warrantee expressed or implied.
- //
- // Commercial use is strickly prohibited without written permission
- // from ImageWare Development.
- //
- // This program is -not- in the public domain.
- //
- /////////////////////////////////////////////////////////////////////////////
- #include "stdafx.h"
- #include "glOOP.h"
- #include "3dObjectDialog.h"
- /////////////////////////////////////////////////////////////////////////////
- // C3dObjectScalePage dialog
- IMPLEMENT_DYNAMIC(C3dObjectPropSheet, CPropertySheet)
- /////////////////////////////////////////////////////////////////////////////
- // C3dObjectScalePage dialog message map
- BEGIN_MESSAGE_MAP(C3dObjectPropSheet, CPropertySheet)
- //{{AFX_MSG_MAP(C3dObjectPropSheet)
- //}}AFX_MSG_MAP
- END_MESSAGE_MAP()
- /////////////////////////////////////////////////////////////////////////////
- // C3dObjectPropSheet dialog construction
- C3dObjectPropSheet::C3dObjectPropSheet(LPSTR lpName, CWnd* pWndParent, C3dObject* pObject, C3dWorld* pWorld)
- : CPropertySheet(lpName, pWndParent)
- {
- if(pObject)
- {
- pObject->AddAttributePage(pWorld, this);
- }
- AddPage(&m_OriginPage);
- m_OriginPage.m_pObject = pObject;
- AddPage(&m_RotatePage);
- m_RotatePage.m_pObject = pObject;
- AddPage(&m_ScalePage);
- m_ScalePage.m_pObject = pObject;
- AddPage(&m_TranslatePage);
- m_TranslatePage.m_pObject = pObject;
- if(!pObject->m_iType == LIGHT_OBJECT)
- {
- AddPage(&m_ColorMatlPage);
- m_ColorMatlPage.m_pObject = pObject;
- if(pWorld)
- {
- m_ColorMatlPage.m_pMatlList = &pWorld->m_MaterialList;
- m_ColorMatlPage.m_pColorList = &pWorld->m_ColorList;
- }
- }
- AddPage(&m_TexturePage);
- m_TexturePage.m_pObject = pObject;
- AddPage(&m_AnimationPage);
- m_AnimationPage.m_pObject = pObject;
- }
- /////////////////////////////////////////////////////////////////////////////
- // C3dObjectPropSheet function implimentation
- void C3dObjectPropSheet::PostNcDestroy()
- {
- CPropertySheet::PostNcDestroy();
- delete this;
- }