Basic HTML version of Foils prepared July 5 98

Foil 159 PPT Slide

From FMS: Forces Modeling and Simulation Handout JSU HPC Summer Institute for Undergraduates, Jackson MS -- June 15 1998. by Wojtek Furmanski, Subhash Nair, Tom Pulikal


1 // Callback function for enumerating service providers
2 static BOOL FAR PASCAL DirectPlayEnumerateCallback(
3 LPGUID lpSPGuid,
4 LPTSTR lpszSPName,
5 DWORD dwMajorVersion,
6 DWORD dwMinorVersion,
7 LPVOID lpContext
8 )
9 {
10 //Look for the TCP/IP service provider for DirectPlay
11 if (strstr( lpszSPName, "TCP") != NULL)
12 {
13 // Make space for the service provider's GUID.
14 lpServiceProviderGuid = new GUID;
15 if (lpServiceProviderGuid == NULL) //If memory could not be allocated
16 ::MessageBox(NULL,"Could not allocate memory for service provider's GUID",
17 "HelloWorld", MB_OK);
18 else
19 *lpServiceProviderGuid = *lpSPGuid; // Store the GUID of the service provider
20 return(FALSE); //Returning false stops further enumeration
21 //Since we found our service provider, we return false
22 }
23 return(TRUE); //Continue enumeration
24 }
25 DirectPlayEnumerateCallback():
26 DirectPlay calls this function for each
27 service provider it detects on the machine

in Table To:


© Northeast Parallel Architectures Center, Syracuse University, npac@npac.syr.edu

If you have any comments about this server, send e-mail to webmaster@npac.syr.edu.

Page produced by wwwfoil on Sat Nov 28 1998