I have a few errors in my code here they are, my question is how do I fix the undeclared identifiers?
Error 1 error C2065: 'currTimeStamp' : undeclared identifier c:\users\owner\documents\devry\gsp 381\week 1\wk1-ilab-starter\directxframework.cpp 26 1 GDP381W1
Error 5 error C2065: 'currTimeStamp' : undeclared identifier c:\users\owner\documents\devry\gsp 381\week 1\wk1-ilab-starter\directxframework.cpp 252 1 GDP381W1
Error 6 error C2065: 'currTimeStamp' : undeclared identifier c:\users\owner\documents\devry\gsp 381\week 1\wk1-ilab-starter\directxframework.cpp 254 1 GDP381W1
Error 9 error C2065: 'currTimeStamp' : undeclared identifier c:\users\owner\documents\devry\gsp 381\week 1\wk1-ilab-starter\directxframework.cpp 256 1 GDP381W1
Error 3 error C2065: 'm_FPS' : undeclared identifier c:\users\owner\documents\devry\gsp 381\week 1\wk1-ilab-starter\directxframework.cpp 243 1 GDP381W1
Error 10 error C2065: 'm_FPS' : undeclared identifier c:\users\owner\documents\devry\gsp 381\week 1\wk1-ilab-starter\directxframework.cpp 257 1 GDP381W1
Error 2 error C2065: 'prevTimeStamp' : undeclared identifier c:\users\owner\documents\devry\gsp 381\week 1\wk1-ilab-starter\directxframework.cpp 27 1 GDP381W1
Error 7 error C2065: 'prevTimeStamp' : undeclared identifier c:\users\owner\documents\devry\gsp 381\week 1\wk1-ilab-starter\directxframework.cpp 254 1 GDP381W1
Error 8 error C2065: 'prevTimeStamp' : undeclared identifier c:\users\owner\documents\devry\gsp 381\week 1\wk1-ilab-starter\directxframework.cpp 256 1 GDP381W1
Error 4 error C3861: 'swprintf_s': identifier not found c:\users\owner\documents\devry\gsp 381\week 1\wk1-ilab-starter\directxframework.cpp 243 1 GDP381W1
Error 1 error C2065: 'currTimeStamp' : undeclared identifier c:\users\owner\documents\devry\gsp 381\week 1\wk1-ilab-starter\directxframework.cpp 26 1 GDP381W1
Error 5 error C2065: 'currTimeStamp' : undeclared identifier c:\users\owner\documents\devry\gsp 381\week 1\wk1-ilab-starter\directxframework.cpp 252 1 GDP381W1
Error 6 error C2065: 'currTimeStamp' : undeclared identifier c:\users\owner\documents\devry\gsp 381\week 1\wk1-ilab-starter\directxframework.cpp 254 1 GDP381W1
Error 9 error C2065: 'currTimeStamp' : undeclared identifier c:\users\owner\documents\devry\gsp 381\week 1\wk1-ilab-starter\directxframework.cpp 256 1 GDP381W1
Error 3 error C2065: 'm_FPS' : undeclared identifier c:\users\owner\documents\devry\gsp 381\week 1\wk1-ilab-starter\directxframework.cpp 243 1 GDP381W1
Error 10 error C2065: 'm_FPS' : undeclared identifier c:\users\owner\documents\devry\gsp 381\week 1\wk1-ilab-starter\directxframework.cpp 257 1 GDP381W1
Error 2 error C2065: 'prevTimeStamp' : undeclared identifier c:\users\owner\documents\devry\gsp 381\week 1\wk1-ilab-starter\directxframework.cpp 27 1 GDP381W1
Error 7 error C2065: 'prevTimeStamp' : undeclared identifier c:\users\owner\documents\devry\gsp 381\week 1\wk1-ilab-starter\directxframework.cpp 254 1 GDP381W1
Error 8 error C2065: 'prevTimeStamp' : undeclared identifier c:\users\owner\documents\devry\gsp 381\week 1\wk1-ilab-starter\directxframework.cpp 256 1 GDP381W1
Error 4 error C3861: 'swprintf_s': identifier not found c:\users\owner\documents\devry\gsp 381\week 1\wk1-ilab-starter\directxframework.cpp 243 1 GDP381W1
DirectXFramework.cpp #include "DirectXFramework.h" #include <time.h> CDirectXFramework::CDirectXFramework(void) { // Init or NULL objects before use to avoid any undefined behavior m_bVsync = false; m_pD3DObject = 0; m_pD3DDevice = 0; currTimeStamp = 0; prevTimeStamp = 0; m_fps =0; } CDirectXFramework::~CDirectXFramework(void) { // If Shutdown is not explicitly called correctly, call it when // this class is destroyed or falls out of scope as an error check. Shutdown(); } void CDirectXFramework::Init(HWND& hWnd, HINSTANCE& hInst, bool bWindowed) { m_hWnd = hWnd; ////////////////////////////////////////////////////////////////////////// // Direct3D Foundations - D3D Object, Present Parameters, and D3D Device ////////////////////////////////////////////////////////////////////////// // Create the D3D Object m_pD3DObject = Direct3DCreate9(D3D_SDK_VERSION); // Find the width and height of window using hWnd and GetWindowRect() RECT rect; GetWindowRect(hWnd, &rect); int width = rect.right - rect.left; int height = rect.bottom - rect.top; // Set D3D Device presentation parameters before creating the device D3DPRESENT_PARAMETERS D3Dpp; ZeroMemory(&D3Dpp, sizeof(D3Dpp)); // NULL the structure's memory D3Dpp.hDeviceWindow = hWnd; // Handle to the focus window D3Dpp.Windowed = bWindowed; // Windowed or Full-screen boolean D3Dpp.AutoDepthStencilFormat = D3DFMT_D24S8; // Format of depth/stencil buffer, 24 bit depth, 8 bit stencil D3Dpp.EnableAutoDepthStencil = TRUE; // Enables Z-Buffer (Depth Buffer) D3Dpp.BackBufferCount = 1; // Change if need of > 1 is required at a later date D3Dpp.BackBufferFormat = D3DFMT_X8R8G8B8; // Back-buffer format, 8 bits for each pixel D3Dpp.BackBufferHeight = height; // Make sure resolution is supported, use adapter modes D3Dpp.BackBufferWidth = width; // (Same as above) D3Dpp.SwapEffect = D3DSWAPEFFECT_DISCARD; // Discard back-buffer, must stay discard to support multi-sample D3Dpp.PresentationInterval = m_bVsync ? D3DPRESENT_INTERVAL_DEFAULT : D3DPRESENT_INTERVAL_IMMEDIATE; // Present back-buffer immediately, unless V-Sync is on D3Dpp.Flags = D3DPRESENTFLAG_DISCARD_DEPTHSTENCIL; // This flag should improve performance, if not set to NULL. D3Dpp.FullScreen_RefreshRateInHz = bWindowed ? 0 : D3DPRESENT_RATE_DEFAULT; // Full-screen refresh rate, use adapter modes or default D3Dpp.MultiSampleQuality = 0; // MSAA currently off, check documentation for support. D3Dpp.MultiSampleType = D3DMULTISAMPLE_NONE; // MSAA currently off, check documentation for support. // Check device capabilities DWORD devicebehaviorFlags = 0; m_pD3DObject->GetDeviceCaps(D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, &m_D3DCaps); // Determine vertex processing mode if(m_D3DCaps.DevCaps & D3DCREATE_HARDWARE_VERTEXPROCESSING) { // Hardware vertex processing supported? (Video Card) devicebehaviorFlags |= D3DCREATE_HARDWARE_VERTEXPROCESSING; } else { // If not, use software (CPU) devicebehaviorFlags |= D3DCREATE_SOFTWARE_VERTEXPROCESSING; } // If hardware vertex processing is on, check pure device support if(m_D3DCaps.DevCaps & D3DDEVCAPS_PUREDEVICE && devicebehaviorFlags & D3DCREATE_HARDWARE_VERTEXPROCESSING) { devicebehaviorFlags |= D3DCREATE_PUREDEVICE; } // Create the D3D Device with the present parameters and device flags above m_pD3DObject->CreateDevice( D3DADAPTER_DEFAULT, // which adapter to use, set to primary D3DDEVTYPE_HAL, // device type to use, set to hardware rasterization hWnd, // handle to the focus window devicebehaviorFlags, // behavior flags &D3Dpp, // presentation parameters &m_pD3DDevice); // returned device pointer //************************************************************************* ////////////////////////////////////////////////////////////////////////// // Create a Font Object ////////////////////////////////////////////////////////////////////////// // Load a font for private use for this process AddFontResourceEx(L"Delicious-Roman.otf", FR_PRIVATE, 0); // Load D3DXFont, each font style you want to support will need an ID3DXFont //ID3DXFont* m_pD3DFont;//:DW Bug11 same problem as sprite. You must declare them in the h file. If you redeclare them here, they become local variable and are destroyed when Init() returns. D3DXCreateFont(m_pD3DDevice, 30, 0, FW_BOLD, 0, false, DEFAULT_CHARSET, OUT_DEFAULT_PRECIS, DEFAULT_QUALITY, DEFAULT_PITCH | FF_DONTCARE, TEXT("Delicious-Roman"), &m_pD3DFont); ////////////////////////////////////////////////////////////////////////// // Create Sprite Object and Textures ////////////////////////////////////////////////////////////////////////// // Create a sprite object, note you will only need one for all 2D sprites //ID3DXSprite* m_pD3DSprite;//:DW Bug10 This should already be defined in the h file. D3DXCreateSprite(m_pD3DDevice, &m_pD3DSprite); // Create a texture, each different 2D sprite to display to the screen // will need a new texture object. If drawing the same sprite texture // multiple times, just call that sprite's Draw() with different // transformation values. //D3DXCreateTextureFromFileEx(m_pD3DDevice, "test.tga", 0, 0, 0, 0, //D3DFMT_UNKNOWN, D3DPOOL_MANAGED, D3DX_DEFAULT, D3DX_DEFAULT, //D3DCOLOR_XRGB(255, 0, 255), &m_imageInfo, 0, &m_pTexture);//:DW Bug03. "test.tga" needs to be wide characters //#1 D3DXCreateTextureFromFileEx(m_pD3DDevice, L"test.png", 0, 0, 0, 0, D3DFMT_UNKNOWN, D3DPOOL_MANAGED, D3DX_DEFAULT, D3DX_DEFAULT, D3DCOLOR_XRGB(255, 0, 255), &m_imageInfo, 0, &m_pTexture);//:DW Bug03 fixed. //************************************************************************* } //int CDirectXFramework::Update(void);//:DW Bug04. This is a declaration (should be in the h file) You need to define the method. // //{ // int CDirectXFramework::Render(void);//:DW Bug05. This is a declaration (should be in the h file) You need to define the method. //} (note: additional problem. These two methods return voids, not ints.) void CDirectXFramework::Update()//:DW Bug04 fixed. { } void CDirectXFramework::Render(void)//:DW Bug05 fixed { // If the device was not created successfully, return if(!m_pD3DDevice) return; //************************************************************************* ////////////////////////////////////////////////////////////////////////// // All draw calls between swap chain's functions, and pre-render and post- // render functions (Clear and Present, BeginScene and EndScene) ////////////////////////////////////////////////////////////////////////// // Clear the back buffer, call BeginScene() HRESULT BeginScene(); if(SUCCEEDED(m_pD3DDevice->Clear(0, 0, D3DCLEAR_TARGET | D3DCLEAR_ZBUFFER, D3DXCOLOR(0.0f, 1.0f, 1.0f, 0.0f), 2.0f, 0))) { if(SUCCEEDED(m_pD3DDevice->BeginScene())) { ////////////////////////////////////////////////////////////////////////// // Draw 3D Objects (for future labs - not used in Week #1) ////////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////// // Draw 2D sprites ////////////////////////////////////////////////////////////////////////// // Note: You should only be calling the sprite object's begin and end once, // with all draw calls of sprites between them // Call Sprite's Begin to start rendering 2D sprite objects if (SUCCEEDED(m_pD3DSprite->Begin(D3DXSPRITE_ALPHABLEND | D3DXSPRITE_SORT_DEPTH_FRONTTOBACK))) { ////////////////////////////////////////////////////////////////////////// // Matrix Transformations to control sprite position, scale, and rotate // Set these matrices for each object you want to render to the screen ////////////////////////////////////////////////////////////////////////// D3DXMATRIX transMat, rotMat, scaleMat, worldMat; D3DXMatrixIdentity(&transMat); D3DXMatrixIdentity(&scaleMat); D3DXMatrixIdentity(&rotMat); D3DXMatrixIdentity(&worldMat); // Scaling D3DXMatrixScaling(&scaleMat, 2.0f, 2.0f, 0.0f); // Rotation on Z axis, value in radians, converting from degrees D3DXMatrixRotationZ(&rotMat, D3DXToRadian(90.0f)); // Translation //D3DXMatrixRotationZ(&rotMat, D3DXToRadian(90.0f));//:DW Bug09 Should be translation matrix D3DXMatrixTranslation(&transMat, 200.0f, 100.0f, 0.0f);//:DW Bug09 fixed. // Multiply scale and rotation, store in scale D3DXMatrixMultiply(&scaleMat, &scaleMat, &rotMat); // Multiply scale and translation, store in world D3DXMatrixMultiply(&worldMat, &scaleMat, &transMat); // Set Transform m_pD3DSprite->SetTransform(&worldMat); // Draw the texture with the sprite object m_pD3DSprite->Draw(m_pTexture, 0, &D3DXVECTOR3(m_imageInfo.Width * 0.5f, m_imageInfo.Height * 0.5f, 0.0f), 0, D3DCOLOR_ARGB(255, 0, 0, 255)); // End drawing 2D sprites m_pD3DSprite->End(); } ////////////////////////////////////////////////////////////////////////// // Draw Text ////////////////////////////////////////////////////////////////////////// // Calculate RECT structure for text drawing placement, using whole screen RECT rect; GetWindowRect(m_hWnd, &rect); rect.right = rect.right - rect.left; rect.bottom = rect.bottom - rect.top; rect.left = 0; rect.top = 0; // Draw Text, using DT_TOP, DT_RIGHT for placement in the top right of the // screen. DT_NOCLIP can improve speed of text rendering, but allows text // to be drawn outside of the rect specified to draw text in. //m_pD3DFont->DrawText(0, "Orlando Camacho" , -1, &rect, DT_TOP | DT_RIGHT | DT_NOCLIP, D3DCOLOR_ARGB(255, 255, 255, 255));//:DW Bug06. Unicode issue again m_pD3DFont->DrawText(0, L"Orlando Camacho" , -1, &rect, DT_TOP | DT_RIGHT | DT_NOCLIP, D3DCOLOR_ARGB(255, 0, 0, 0));//:DW Bug06 fixed. Also, text set to black, otherwise white font on a white background = invisible. // Draw FPS wchar_t buffer[64]; swprintf_s(buffer, 64, L"FPS: %d", m_FPS); m_pD3DFont->DrawText(0, buffer, -1, &rect, DT_TOP | DT_NOCLIP, D3DCOLOR_ARGB(255, 0, 0, 255)); // Calculate Frames per Second __int64 currTimeStamp = (float)timeGetTime(); static int fpsCounter = 0; if(currTimeStamp -prevTimeStamp >= 1000.0f) { prevTimeStamp = currTimeStamp; __int64 m_FPS = fpsCounter; fpsCounter = 0; // EndScene, and Present the back buffer to the display buffer m_pD3DDevice->EndScene(); m_pD3DDevice->Present(0, 0, 0, 0); } } //************************************************************************* //void CDirectXFramework::Shutdown(void);/:DW Bug07. Redundant and should not have the semicolon. //{ //} //void CDirectXFramework::Shutdown(void);//:DW Bug08. Remove semicolon and add braces CDirectXFramework::Shutdown();//:DW Bug08 fixed. { //************************************************************************* // Release COM objects in the opposite order they were created in // Texture SAFE_RELEASE(m_pTexture); // Sprite SAFE_RELEASE(m_pD3DSprite); // Font SAFE_RELEASE(m_pD3DFont); // 3DDevice SAFE_RELEASE(m_pD3DDevice); // 3DObject SAFE_RELEASE(m_pD3DObject); //************************************************************************* } } {
winMain.cpp #include <iostream> using namespace std; #include <windows.h> #include <time.h> #define VC_EXTRALEAN #include "DirectXFramework.h" ////////////////////////////////////////////////////////////////////////// // Global Variables ////////////////////////////////////////////////////////////////////////// #define SCREEN_WIDTH 800 #define SCREEN_HEIGHT 600 #define WINDOW_TITLE L"GSP 381 - DirectX Framework" HWND g_hWnd; // Handle to the window HINSTANCE g_hInstance; // Handle to the application instance bool g_bWindowed; // Boolean for windowed or full-screen //************************************************************************* // This is where you declare the instance of your DirectXFramework Class CDirectXFramework g_DX; //************************************************************************* // Entry point for the game or application. int WINAPI wWinMain(HINSTANCE hInstance, // Handle to the application HINSTANCE hPrevInstance, // Handle to the previous app LPTSTR lpCmdLine, // Command line string int lpCmdShow); // Show window value LRESULT CALLBACK WndProc(HWND hWnd, // Handle to the window UINT message, // Incoming Message WPARAM wparam, // Message Info LPARAM lparam); // Message Info void InitWindow(void) { WNDCLASSEX wndClass; ZeroMemory(&wndClass, sizeof(wndClass)); // set up the window wndClass.cbSize = sizeof(WNDCLASSEX); // size of window structure wndClass.lpfnWndProc = (WNDPROC)WndProc; // message callback wndClass.lpszClassName = WINDOW_TITLE; // class name wndClass.hInstance = g_hInstance; // handle to the application wndClass.hCursor = LoadCursor(NULL, IDC_ARROW); // default cursor wndClass.hbrBackground = (HBRUSH)(COLOR_WINDOWFRAME); // background brush // register a new type of window RegisterClassEx(&wndClass); g_hWnd = CreateWindow( WINDOW_TITLE, WINDOW_TITLE, // window class name and title g_bWindowed ? WS_OVERLAPPEDWINDOW | WS_VISIBLE:(WS_POPUP | WS_VISIBLE),// window style CW_USEDEFAULT, CW_USEDEFAULT, // x and y coordinates SCREEN_WIDTH, SCREEN_HEIGHT, // width and height of window NULL, NULL, // parent window and menu g_hInstance, // handle to application NULL); // Display the window ShowWindow(g_hWnd, SW_SHOW); UpdateWindow(g_hWnd); } int WINAPI wWinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPTSTR lpCmdLine, int nCmdShow ) { g_hInstance = hInstance; // Store application handle g_bWindowed = true; // Windowed mode or full-screen // Init the window InitWindow(); // Use this msg structure to catch window messages MSG msg; ZeroMemory(&msg, sizeof(msg)); //************************************************************************* // Initialize DirectX/Game here (call the Init method of your framwork) g_DX.Init(g_hWnd, g_hInstance, g_bWindowed); //************************************************************************* // Main Windows/Game Loop __int64 cntsPerSec = 0; QueryPerformanceFrequency((LARGE_INTEGER*)&cntsPerSec); float secsPerCnt = 1.0f / (float)cntsPerSec; __int64 prevTimeStamp = 0; QueryPerformanceCounter((LARGE_INTEGER*)&prevTimeStamp); while(msg.message != WM_QUIT) { if(PeekMessage(&msg, NULL, 0, 0, PM_REMOVE)) { TranslateMessage(&msg); DispatchMessage(&msg); } __int64 currTimeStamp = 0; QueryPerformanceCounter((LARGE_INTEGER*)&currTimeStamp); float dt = (currTimeStamp - prevTimeStamp)*secsPerCnt; //************************************************************************* // This is where you call your DirectXFramework/Game render/update calls //g_DX.Update((int)passed);//:DW Bug01. Update has no parameters. g_DX.Update();//:DW Bug01 fixed. g_DX.Render(); // Prepare for next iteration: The current time // stamp becomes the previous time stamp for the // next iteration. prevTimeStamp = currTimeStamp; //************************************************************************* } //************************************************************************* //Shutdown DirectXFramework/Game here g_DX.Shutdown(); //************************************************************************* // Unregister window //UnregisterClass((LPCSTR)WINDOW_TITLE, g_hInstance);//:DW Bug02 The project is setup for Unicode (wide characters) UnregisterClass((LPCWSTR)WINDOW_TITLE, g_hInstance);//:DW Bug02 fixed. // Return successful return 0; } LRESULT CALLBACK WndProc(HWND hWnd, UINT message, WPARAM wparam, LPARAM lparam) { // attempt to handle your messages switch(message) { case (WM_PAINT): { InvalidateRect(hWnd,NULL,TRUE); break; } case(WM_DESTROY): { PostQuitMessage(0); break; } case(WM_KEYDOWN): { switch(wparam) { // Escape Key will close the application // Remove/Modify this call when creating a real game with menus, etc. case VK_ESCAPE: { PostQuitMessage(0); break; } } } } // pass to default handler return DefWindowProc(hWnd, message, wparam, lparam); }
DirectXFramework.h ////////////////////////////////////////////////////////////////////////// // Name: DirectXFramework.h // Date: April 2nd, 2010 // Author: Kyle Lauing [klauing@devry.edu] or [kylelauing@gmail.com] // Purpose: This file is used to create a very simple framework for using // DirectX 9 for the GSP 381 course for DeVry University. // Disclaimer: // Copyright © 2010 by DeVry Educational Development Corporation. // All rights reserved. No part of this work may be reproduced // or used in any form or by any means graphic, electronic, or // mechanical, including photocopying, recording, Web distribution // or information storage and retrieval systems without the // prior consent of DeVry Educational Development Corporation. ////////////////////////////////////////////////////////////////////////// #pragma once #pragma comment(lib, "winmm.lib") ////////////////////////////////////////////////////////////////////////// // Direct3D 9 headers and libraries required ////////////////////////////////////////////////////////////////////////// #include <d3d9.h> #include <d3dx9.h> #pragma comment(lib, "d3d9.lib") #pragma comment(lib, "d3dx9.lib") // Macro to release COM objects fast and safely #define SAFE_RELEASE(x) if(x){x->Release(); x = 0;} class CDirectXFramework { ////////////////////////////////////////////////////////////////////////// // Application Variables ////////////////////////////////////////////////////////////////////////// HWND m_hWnd; // Handle to the window bool m_bVsync; // Boolean for vertical syncing ////////////////////////////////////////////////////////////////////////// // Direct3D Variables ////////////////////////////////////////////////////////////////////////// IDirect3D9* m_pD3DObject; // Direct3D 9 Object IDirect3DDevice9* m_pD3DDevice; // Direct3D 9 Device D3DCAPS9 m_D3DCaps; // Device Capabilities ////////////////////////////////////////////////////////////////////////// // Font Variables ////////////////////////////////////////////////////////////////////////// ID3DXFont* m_pD3DFont; // Font Object ////////////////////////////////////////////////////////////////////////// // Sprite Variables ////////////////////////////////////////////////////////////////////////// ID3DXSprite* m_pD3DSprite; // Sprite Object IDirect3DTexture9* m_pTexture; // Texture Object for a sprite D3DXIMAGE_INFO m_imageInfo; // File details of a texture public: ////////////////////////////////////////////////////////////////////////// // Init and Shutdown are preferred to constructors and destructor, // due to having more control when to explicitly call them when global. ////////////////////////////////////////////////////////////////////////// CDirectXFramework(void); ~CDirectXFramework(void); ////////////////////////////////////////////////////////////////////////// // Name: Init // Parameters: HWND hWnd - Handle to the window for the application // HINSTANCE hInst - Handle to the application instance // bool bWindowed - Boolean to control windowed or full-screen // Return: void // Description: Ran once at the start. Initialize DirectX components and // variables to control the application. ////////////////////////////////////////////////////////////////////////// void Init(HWND& hWnd, HINSTANCE& hInst, bool bWindowed); ////////////////////////////////////////////////////////////////////////// // Name: Update // Parameters: float elapsedTime - Time that has elapsed since the last // update call. // Return: void // Description: Runs every frame, use dt to limit functionality called to // a certain amount of elapsed time that has passed. Used // for updating variables and processing input commands prior // to calling render. ////////////////////////////////////////////////////////////////////////// void Update(); ////////////////////////////////////////////////////////////////////////// // Name: Render // Parameters: float elapsedTime - Time that has elapsed since the last // render call. // Return: void // Description: Runs every frame, use dt to limit functionality called to // a certain amount of elapsed time that has passed. Render // calls all draw call to render objects to the screen. ////////////////////////////////////////////////////////////////////////// void Render(void); ////////////////////////////////////////////////////////////////////////// // Name: Shutdown // Parameters: void // Return: void // Description: Runs once at the end of an application. Destroy COM // objects and deallocate dynamic memory. ////////////////////////////////////////////////////////////////////////// void Shutdown(); };