资源简介
VS 6.0
实现多个物体旋转
多个运动物体,实现运动物体的鼠标拾取
代码片段和文件信息
//-----------------------------------------------------------------------------
// File: D3DApp.cpp
//
// Desc: Application class for the Direct3D samples framework library.
//-----------------------------------------------------------------------------
#define STRICT
#include
#include
#include setsd.h>
#include
#include
#include
#include
#include “D3DApp.h“
#include “D3DUtil.h“
#include “DXUtil.h“
#include “D3DRes.h“
//-----------------------------------------------------------------------------
// Global access to the app (needed for the global WndProc())
//-----------------------------------------------------------------------------
static CD3DApplication* g_pD3DApp = NULL;
//-----------------------------------------------------------------------------
// Name: CD3DApplication()
// Desc: Constructor
//-----------------------------------------------------------------------------
CD3DApplication::CD3DApplication()
{
g_pD3DApp = this;
m_dwNumAdapters = 0;
m_dwAdapter = 0L;
m_pD3D = NULL;
m_pd3dDevice = NULL;
m_hWnd = NULL;
m_hWndFocus = NULL;
m_bActive = FALSE;
m_bReady = FALSE;
m_bHasFocus = FALSE;
m_dwCreateFlags = 0L;
m_bframeMoving = TRUE;
m_bSingleStep = FALSE;
m_fFPS = 0.0f;
m_strDeviceStats[0] = _T(‘\0‘);
m_strframeStats[0] = _T(‘\0‘);
m_strWindowtitle = _T(“D3D8 Application“);
m_dwCreationWidth = 400;
m_dwCreationHeight = 300;
m_bUseDepthBuffer = FALSE;
m_dwMinDepthBits = 16;
m_dwMinStencilBits = 0;
m_bShowCursorWhenFullscreen = FALSE;
// When m_bClipCursorWhenFullscreen is TRUE the cursor is limited to
// the device window when the app goes fullscreen. This prevents users
// from accidentally clicking outside the app window on a multimon system.
// This flag is turned off by default for debug builds since it makes
// multimon debugging difficult.
#if defined(_DEBUG) || defined(DEBUG)
m_bClipCursorWhenFullscreen = FALSE;
#else
m_bClipCursorWhenFullscreen = TRUE;
#endif
}
//-----------------------------------------------------------------------------
// Name: WndProc()
// Desc: Static msg handler which passes messages to the application class.
//-----------------------------------------------------------------------------
LRESULT CALLBACK WndProc( HWND hWnd UINT uMsg WPARAM wParam LPARAM lParam )
{
return g_pD3DApp->MsgProc( hWnd uMsg wParam lParam );
}
//-----------------------------------------------------------------------------
// Name: Create()
// Desc:
//-----------------------------------------------------------------------------
HRESULT CD3DApplication::Create( HINSTANCE hInstance )
{
HRESUL
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
文件 74454 2001-12-08 01:28 pick\d3dapp.cpp
文件 9013 2001-12-07 18:57 pick\d3dapp.h
文件 1437 2001-12-07 18:57 pick\d3dres.h
文件 23187 2001-12-07 18:57 pick\d3dutil.cpp
文件 10643 2001-12-07 18:57 pick\d3dutil.h
文件 1078 2001-12-07 18:57 pick\DirectX.ico
文件 10801 2001-12-07 18:57 pick\diutil.cpp
文件 1985 2001-12-07 18:57 pick\diutil.h
文件 23589 2001-12-07 18:57 pick\dxutil.cpp
文件 5072 2001-12-07 18:57 pick\dxutil.h
文件 4833 2001-12-08 01:11 pick\Obj.cpp
文件 905 2001-12-08 00:27 pick\Obj.h
文件 1084 2001-12-08 00:58 pick\Orbit.cpp
文件 692 2001-12-08 00:37 pick\Orbit.h
文件 43288 2001-12-08 01:13 pick\pick.aps
文件 33832 2001-12-08 03:07 pick\pick.cpp
文件 5318 2001-12-07 22:42 pick\pick.dsp
文件 634 2001-12-07 20:01 pick\pick.dsw
文件 368640 2001-12-08 03:08 pick\pick.exe
文件 3928 2001-12-08 01:06 pick\pick.h
文件 99328 2001-12-08 03:11 pick\pick.ncb
文件 56832 2001-12-08 03:11 pick\pick.opt
文件 2059 2001-12-08 03:08 pick\pick.plg
文件 4778 2001-12-07 18:57 pick\pick.rc
文件 2881 2001-12-07 18:57 pick\resource.h
目录 0 2001-12-08 03:11 pick\
- 上一篇:碰撞检测VC实现的代码
- 下一篇:fisher分类器算法及程序
评论
共有 条评论