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


// Callback function for enumerating service providers
static BOOL FAR PASCAL DirectPlayEnumerateCallback(
LPGUID lpSPGuid,
LPTSTR lpszSPName,
DWORD dwMajorVersion,
DWORD dwMinorVersion,
LPVOID lpContext
)
{
//Look for the TCP/IP service provider for DirectPlay
if (strstr( lpszSPName, "TCP") != NULL)
{
// Make space for the service provider's GUID.
lpServiceProviderGuid = new GUID;
if (lpServiceProviderGuid == NULL) //If memory could not be allocated
::MessageBox(NULL,"Could not allocate memory for service provider's GUID",
"HelloWorld", MB_OK);
else
*lpServiceProviderGuid = *lpSPGuid; // Store the GUID of the service provider
return(FALSE); //Returning false stops further enumeration
//Since we found our service provider, we return false
}
return(TRUE); //Continue enumeration
}
DirectPlayEnumerateCallback():
DirectPlay calls this function for each
service provider it detects on the machine



© 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