~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~ [ freetext search ] ~ [ file search ] ~

Wine Cross Reference
wine/dlls/dplayx/dplay_global.h

Version: ~ [ wine-1.1.6 ] ~ [ wine-1.1.5 ] ~ [ wine-1.1.4 ] ~ [ wine-1.1.3 ] ~ [ wine-1.1.2 ] ~ [ wine-1.1.1 ] ~ [ wine-1.1.0 ] ~ [ wine-1.0 ] ~ [ wine-1.0-rc5 ] ~ [ wine-1.0-rc4 ] ~ [ wine-1.0-rc3 ] ~ [ wine-1.0-rc2 ] ~ [ wine-1.0-rc1 ] ~ [ wine-0.9.61 ] ~ [ wine-0.9.60 ] ~ [ wine-0.9.59 ] ~ [ wine-0.9.58 ] ~ [ wine-0.9.57 ] ~ [ wine-0.9.56 ] ~ [ wine-0.9.55 ] ~ [ wine-0.9.54 ] ~ [ wine-0.9.53 ] ~ [ wine-0.9.52 ] ~ [ wine-0.9.51 ] ~ [ wine-0.9.50 ] ~ [ wine-0.9.49 ] ~ [ wine-0.9.48 ] ~ [ wine-0.9.47 ] ~ [ wine-0.9.46 ] ~ [ wine-0.9.45 ] ~ [ wine-0.9.44 ] ~ [ wine-0.9.43 ] ~ [ wine-0.9.42 ] ~ [ wine-0.9.41 ] ~ [ wine-0.9.40 ] ~ [ wine-0.9.39 ] ~ [ wine-0.9.38 ] ~ [ wine-0.9.37 ] ~ [ wine-0.9.36 ] ~ [ wine-0.9.35 ] ~ [ wine-0.9.34 ] ~ [ wine-0.9.33 ] ~ [ wine-0.9.32 ] ~ [ wine-0.9.31 ] ~ [ wine-0.9.30 ] ~ [ wine-0.9.29 ] ~ [ wine-0.9.28 ] ~ [ wine-0.9.27 ] ~ [ wine-0.9.26 ] ~ [ wine-0.9.25 ] ~ [ wine-0.9.24 ] ~ [ wine-0.9.23 ] ~ [ wine-0.9.22 ] ~ [ wine-0.9.21 ] ~ [ wine-0.9.20 ] ~ [ wine-0.9.19 ] ~ [ wine-0.9.18 ] ~ [ wine-0.9.17 ] ~ [ wine-0.9.16 ] ~ [ wine-0.9.15 ] ~ [ wine-0.9.14 ] ~ [ wine-0.9.13 ] ~ [ wine-0.9.12 ] ~ [ wine-0.9.11 ] ~ [ wine-0.9.10 ] ~ [ wine-0.9.9 ] ~ [ wine-0.9.8 ] ~ [ wine-0.9.7 ] ~ [ wine-0.9.6 ] ~ [ wine-0.9.5 ] ~ [ wine-0.9.4 ] ~ [ wine-0.9.3 ] ~ [ wine-0.9.2 ] ~ [ wine-0.9.1 ] ~ [ wine-0.9 ] ~ [ wine20050930 ] ~ [ wine20050830 ] ~ [ wine20050725 ] ~ [ wine20050628 ] ~ [ wine20050524 ] ~ [ wine20050419 ] ~ [ wine20050310 ] ~ [ wine20050211 ] ~ [ wine20050111 ] ~ [ wine20041201 ] ~ [ wine20041019 ] ~ [ wine20040914 ] ~ [ wine20040813 ] ~ [ wine20040716 ] ~ [ wine20040615 ] ~ [ wine20040505 ] ~ [ wine20040408 ] ~ [ wine20040309 ] ~ [ wine20040213 ] ~ [ wine20040121 ] ~ [ wine20031212 ] ~ [ wine20031118 ] ~ [ wine20031016 ] ~ [ wine20030911 ] ~ [ wine20030813 ] ~ [ wine20030709 ] ~ [ wine20030618 ] ~ [ wine20030508 ] ~ [ wine20030408 ] ~ [ wine20030318 ] ~ [ wine20030219 ] ~ [ wine20030115 ] ~ [ wine20021219 ] ~ [ wine20021125 ] ~ [ wine20021031 ] ~ [ wine20021007 ] ~ [ wine20020904 ] ~ [ wine20020804 ] ~ [ wine20020710 ] ~ [ wine20020605 ] ~ [ wine20020509 ] ~ [ wine20020411 ] ~ [ wine20020310 ] ~ [ wine20020228 ] ~ [ wine20011226 ] ~ [ wine20011108 ] ~ [ wine20011004 ] ~ [ wine20010824 ] ~ [ wine20010731 ] ~ [ wine20010629 ] ~ [ wine20010510 ] ~ [ wine20010418 ] ~ [ wine20010326 ] ~ [ wine20010305 ] ~ [ wine20010216 ] ~ [ wine20010112 ] ~ [ wine20001222 ] ~ [ wine20001202 ] ~ [ wine20001026 ] ~ [ wine20001002 ] ~ [ wine20000909 ] ~ [ wine20000821 ] ~ [ wine20000801 ] ~ [ wine20000716 ] ~ [ wine20000326 ] ~ [ wine20000227 ] ~ [ wine20000130 ] ~ [ wine20000109 ] ~

  1 /*
  2  * Copyright 2000 Peter Hunnisett
  3  *
  4  * This library is free software; you can redistribute it and/or
  5  * modify it under the terms of the GNU Lesser General Public
  6  * License as published by the Free Software Foundation; either
  7  * version 2.1 of the License, or (at your option) any later version.
  8  *
  9  * This library is distributed in the hope that it will be useful,
 10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
 11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 12  * Lesser General Public License for more details.
 13  *
 14  * You should have received a copy of the GNU Lesser General Public
 15  * License along with this library; if not, write to the Free Software
 16  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
 17  */
 18 
 19 #ifndef __WINE_DPLAY_GLOBAL_INCLUDED
 20 #define __WINE_DPLAY_GLOBAL_INCLUDED
 21 
 22 #include <stdarg.h>
 23 
 24 #include "windef.h"
 25 #include "winbase.h"
 26 #include "wine/dplaysp.h"
 27 #include "lobbysp.h"
 28 #include "dplayx_queue.h"
 29 
 30 extern HRESULT DPL_EnumAddress( LPDPENUMADDRESSCALLBACK lpEnumAddressCallback,
 31                                 LPCVOID lpAddress, DWORD dwAddressSize,
 32                                 LPVOID lpContext );
 33 
 34 extern DWORD DP_CalcSessionDescSize( LPCDPSESSIONDESC2 lpSessDesc, BOOL bAnsi );
 35 
 36 /*****************************************************************************
 37  * Predeclare the interface implementation structures
 38  */
 39 typedef struct IDirectPlay2Impl IDirectPlay2AImpl;
 40 typedef struct IDirectPlay2Impl IDirectPlay2Impl;
 41 typedef struct IDirectPlay3Impl IDirectPlay3AImpl;
 42 typedef struct IDirectPlay3Impl IDirectPlay3Impl;
 43 typedef struct IDirectPlay4Impl IDirectPlay4AImpl;
 44 typedef struct IDirectPlay4Impl IDirectPlay4Impl;
 45 
 46 typedef struct tagDirectPlayIUnknownData
 47 {
 48   LONG              ulObjRef;
 49   CRITICAL_SECTION  DP_lock;
 50 } DirectPlayIUnknownData;
 51 
 52 typedef struct tagEnumSessionAsyncCallbackData
 53 {
 54   LPSPINITDATA lpSpData;
 55   GUID         requestGuid;
 56   DWORD        dwEnumSessionFlags;
 57   DWORD        dwTimeout;
 58   HANDLE       hSuicideRequest;
 59 } EnumSessionAsyncCallbackData;
 60 
 61 typedef struct tagDP_MSG_REPLY_STRUCT
 62 {
 63   HANDLE hReceipt;
 64   WORD   wExpectedReply;
 65   LPVOID lpReplyMsg;
 66   DWORD  dwMsgBodySize;
 67   /* FIXME: Is the message header required as well? */
 68 } DP_MSG_REPLY_STRUCT, *LPDP_MSG_REPLY_STRUCT;
 69 
 70 typedef struct tagDP_MSG_REPLY_STRUCT_LIST
 71 {
 72   DPQ_ENTRY(tagDP_MSG_REPLY_STRUCT_LIST) replysExpected;
 73   DP_MSG_REPLY_STRUCT replyExpected;
 74 } DP_MSG_REPLY_STRUCT_LIST, *LPDP_MSG_REPLY_STRUCT_LIST;
 75 
 76 struct PlayerData
 77 {
 78   /* Individual player information */
 79   DPID dpid;
 80 
 81   DPNAME name;
 82   HANDLE hEvent;
 83 
 84   ULONG  uRef;  /* What is the reference count on this data? */
 85 
 86   /* View of local data */
 87   LPVOID lpLocalData;
 88   DWORD  dwLocalDataSize;
 89 
 90   /* View of remote data */
 91   LPVOID lpRemoteData;
 92   DWORD  dwRemoteDataSize;
 93 
 94   /* SP data on a per player basis */
 95   LPVOID lpSPPlayerData;
 96 
 97   DWORD  dwFlags; /* Special remarks about the type of player */
 98 };
 99 typedef struct PlayerData* lpPlayerData;
100 
101 struct PlayerList
102 {
103   DPQ_ENTRY(PlayerList) players;
104 
105   lpPlayerData lpPData;
106 };
107 typedef struct PlayerList* lpPlayerList;
108 
109 struct GroupData
110 {
111   /* Internal information */
112   DPID parent; /* If parent == 0 it's a top level group */
113 
114   ULONG uRef; /* Reference count */
115 
116   DPQ_HEAD(GroupList)  groups;  /* A group has [0..n] groups */
117   DPQ_HEAD(PlayerList) players; /* A group has [0..n] players */
118 
119   DPID idGroupOwner; /* ID of player who owns the group */
120 
121   DWORD dwFlags; /* Flags describing anything special about the group */
122 
123   DPID   dpid;
124   DPNAME name;
125 
126   /* View of local data */
127   LPVOID lpLocalData;
128   DWORD  dwLocalDataSize;
129 
130   /* View of remote data */
131   LPVOID lpRemoteData;
132   DWORD  dwRemoteDataSize;
133 };
134 typedef struct GroupData  GroupData;
135 typedef struct GroupData* lpGroupData;
136 
137 struct GroupList
138 {
139   DPQ_ENTRY(GroupList) groups;
140 
141   lpGroupData lpGData;
142 };
143 typedef struct GroupList* lpGroupList;
144 
145 struct DPMSG
146 {
147   DPQ_ENTRY( DPMSG ) msgs;
148   DPMSG_GENERIC* msg;
149 };
150 typedef struct DPMSG* LPDPMSG;
151 
152 enum SPSTATE
153 {
154   NO_PROVIDER = 0,
155   DP_SERVICE_PROVIDER = 1,
156   DP_LOBBY_PROVIDER = 2
157 };
158 
159 /* Contains all data members. FIXME: Rename me */
160 typedef struct tagDirectPlay2Data
161 {
162   BOOL   bConnectionOpen;
163 
164   /* For async EnumSessions requests */
165   HANDLE hEnumSessionThread;
166   HANDLE hKillEnumSessionThreadEvent;
167   DWORD  dwEnumSessionLock;
168 
169   LPVOID lpNameServerData; /* DPlay interface doesn't know contents */
170 
171   BOOL bHostInterface; /* Did this interface create the session */
172 
173   lpGroupData lpSysGroup; /* System group with _everything_ in it */
174 
175   LPDPSESSIONDESC2 lpSessionDesc;
176 
177   /* I/O Msg queues */
178   DPQ_HEAD( DPMSG ) receiveMsgs; /* Msg receive queue */
179   DPQ_HEAD( DPMSG ) sendMsgs;    /* Msg send pending queue */
180 
181   /* Information about the service provider active on this connection */
182   SPINITDATA spData;
183   BOOL       bSPInitialized;
184 
185   /* Information about the lobby server that's attached to this DP object */
186   SPDATA_INIT dplspData;
187   BOOL        bDPLSPInitialized;
188 
189   /* Our service provider */
190   HMODULE hServiceProvider;
191 
192   /* Our DP lobby provider */
193   HMODULE hDPLobbyProvider;
194 
195   enum SPSTATE connectionInitialized;
196 
197   /* Expected messages queue */
198   DPQ_HEAD( tagDP_MSG_REPLY_STRUCT_LIST ) replysExpected;
199 } DirectPlay2Data;
200 
201 typedef struct tagDirectPlay3Data
202 {
203   BOOL dummy;
204 } DirectPlay3Data;
205 typedef struct tagDirectPlay4Data
206 {
207   BOOL dummy;
208 } DirectPlay4Data;
209 
210 #define DP_IMPL_FIELDS \
211   LONG ulInterfaceRef; \
212   DirectPlayIUnknownData*  unk; \
213   DirectPlay2Data*         dp2; \
214   DirectPlay3Data*         dp3; \
215   DirectPlay4Data*         dp4;
216 
217 struct IDirectPlay2Impl
218 {
219   const IDirectPlay2Vtbl *lpVtbl;
220   DP_IMPL_FIELDS
221 };
222 
223 struct IDirectPlay3Impl
224 {
225   const IDirectPlay3Vtbl *lpVtbl;
226   DP_IMPL_FIELDS
227 };
228 
229 struct IDirectPlay4Impl
230 {
231   const IDirectPlay4Vtbl *lpVtbl;
232   DP_IMPL_FIELDS
233 };
234 
235 HRESULT DP_HandleMessage( IDirectPlay2Impl* This, LPCVOID lpMessageBody,
236                           DWORD  dwMessageBodySize, LPCVOID lpMessageHeader,
237                           WORD wCommandId, WORD wVersion,
238                           LPVOID* lplpReply, LPDWORD lpdwMsgSize );
239 
240 /* DP SP external interfaces into DirectPlay */
241 extern HRESULT DP_GetSPPlayerData( IDirectPlay2Impl* lpDP, DPID idPlayer, LPVOID* lplpData );
242 extern HRESULT DP_SetSPPlayerData( IDirectPlay2Impl* lpDP, DPID idPlayer, LPVOID lpData );
243 
244 /* DP external interfaces to call into DPSP interface */
245 extern LPVOID DPSP_CreateSPPlayerData(void);
246 
247 #endif /* __WINE_DPLAY_GLOBAL_INCLUDED */
248 

~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~ [ freetext search ] ~ [ file search ] ~

This page was automatically generated by the LXR engine.
Visit the LXR main site for more information.