Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

2029 lines
72 KiB

  1. #ifndef H245API_H
  2. #define H245API_H
  3. /******************************************************************************
  4. *
  5. * INTEL Corporation Proprietary Information
  6. * Copyright (c) 1994, 1995, 1996 Intel Corporation.
  7. *
  8. * This listing is supplied under the terms of a license agreement
  9. * with INTEL Corporation and may not be used, copied, nor disclosed
  10. * except in accordance with the terms of that agreement.
  11. *
  12. *****************************************************************************/
  13. /******************************************************************************
  14. *
  15. * $Workfile: h245api.h $
  16. * $Revision: 1.64 $
  17. * $Modtime: 04 Mar 1997 16:51:38 $
  18. * $Log: S:/sturgeon/src/include/vcs/h245api.h_v $
  19. *
  20. * Rev 1.64 04 Mar 1997 17:32:36 MANDREWS
  21. * H245CopyCap() and H245CopyCapDescriptor() now return HRESULTs.
  22. *
  23. * Rev 1.63 26 Feb 1997 10:56:20 MANDREWS
  24. * Added H245_MAX_CAPID.
  25. *
  26. * Rev 1.62 Feb 24 1997 18:28:26 tomitowx
  27. * multiple modedescriptor support
  28. *
  29. * Rev 1.61 19 Dec 1996 17:16:10 EHOWARDX
  30. * Now using ASN.1 compiler C++ flag.
  31. *
  32. * Rev 1.60 17 Dec 1996 17:14:12 EHOWARDX
  33. * Added pSeparateStack to IND_OPEN_T.
  34. *
  35. * Rev 1.59 12 Dec 1996 11:24:38 EHOWARDX
  36. * Backed out H245_CONF_H323_OLD change.
  37. *
  38. * Rev 1.57 11 Dec 1996 13:46:46 SBELL1
  39. * Changed H245Init to return linkLayer Physical ID
  40. *
  41. * Rev 1.56 24 Oct 1996 15:57:54 MANDREWS
  42. * Fixed typo in last update.
  43. *
  44. * Rev 1.55 Oct 21 1996 17:11:00 mandrews
  45. * Fixed type in last check-in.
  46. *
  47. * Rev 1.54 Oct 21 1996 16:41:20 mandrews
  48. * Added H245_MASTER_SLAVE_CONFLICT as an additional openChannelReject
  49. * reason code.
  50. *
  51. * Rev 1.53 17 Oct 1996 18:17:54 EHOWARDX
  52. * Changed general string to always be Unicode.
  53. *
  54. * Rev 1.52 14 Oct 1996 14:00:28 EHOWARDX
  55. *
  56. * Unicode changes.
  57. *
  58. * Rev 1.51 03 Sep 1996 18:09:54 EHOWARDX
  59. *
  60. * Changed some parameters to const.
  61. * Changed H245_REQ_ENTRY_H243_CONFERENCE_ID to H245_REQ_ENTER_H243_CONFERENCE
  62. *
  63. * Rev 1.50 15 Aug 1996 14:33:48 EHOWARDX
  64. * Changed definition of H245_COMM_MODE_ENTRY_T as per Mike Andrews' request.
  65. *
  66. * Rev 1.49 24 Jul 1996 15:18:16 EHOWARDX
  67. * Backed out change of IndNonstandardRequest to IndNonstandardReq,
  68. * IndNonstandardResponse to IndNonStandardRsp, and IndNonstandardCommand to
  69. * IndNonstandardCmd to make less work for upper layers (CCTEST).
  70. *
  71. * Rev 1.48 19 Jul 1996 14:12:20 EHOWARDX
  72. *
  73. * Added indication callback structure for CommunicationModeResponse and
  74. * CommunicationModeCommand.
  75. *
  76. * Rev 1.47 19 Jul 1996 12:50:30 EHOWARDX
  77. *
  78. * Multipoint clean-up.
  79. *
  80. * Rev 1.46 16 Jul 1996 17:53:48 unknown
  81. * Added FNS indication.
  82. *
  83. * Rev 1.45 16 Jul 1996 11:51:58 EHOWARDX
  84. *
  85. * Changed ERROR_LOCAL_BASE_ID to ERROR_BASE_ID.
  86. *
  87. * Rev 1.44 16 Jul 1996 11:46:10 EHOWARDX
  88. *
  89. * Eliminated H245_ERROR_MUX_CAPS_ALREADY_SET (changing the existing
  90. * mux cap should not be an error).
  91. *
  92. * Rev 1.43 11 Jul 1996 18:42:14 rodellx
  93. *
  94. * Fixed bug where HRESULT ids were in violation of Facility and/or Code
  95. * value rules.
  96. *
  97. * Rev 1.42 10 Jul 1996 11:33:42 unknown
  98. * Changed error base.
  99. *
  100. * Rev 1.41 01 Jul 1996 22:07:24 EHOWARDX
  101. * Added Conference and CommunicationMode structures and API functions.
  102. *
  103. * Rev 1.40 18 Jun 1996 14:48:54 EHOWARDX
  104. *
  105. * Bumped version number to 2 and modified H245MaintenanceLoopRelease()
  106. * and associated Confirms.
  107. *
  108. * Rev 1.39 14 Jun 1996 18:59:38 EHOWARDX
  109. * Geneva update.
  110. *
  111. * Rev 1.38 31 May 1996 18:19:46 EHOWARDX
  112. * Brought error codes in line with STURERR.DOC guidelines.
  113. *
  114. * Rev 1.37 30 May 1996 23:37:26 EHOWARDX
  115. * Clean up.
  116. *
  117. * Rev 1.36 30 May 1996 13:55:02 EHOWARDX
  118. * Changed H245EndConnection to H245EndSession.
  119. * Removed H245_CONF_ENDCONNECTION.
  120. *
  121. * Rev 1.35 29 May 1996 14:23:58 EHOWARDX
  122. * Changed definition of H245_ERROR_OK back to 0 (NOERROR == S_OK == 0).
  123. *
  124. * Rev 1.34 29 May 1996 13:19:50 EHOWARDX
  125. * RESULT to HRESULT conversion.
  126. *
  127. * Rev 1.33 24 May 1996 23:12:56 EHOWARDX
  128. * Tel Aviv update.
  129. *
  130. * Rev 1.32 21 May 1996 18:23:58 EHOWARDX
  131. *
  132. * Added dwTransId parameter to H245RequestMultiplexEntry,
  133. * H245RequestMode, and H245MaintenanceLoopRequest.
  134. *
  135. * Rev 1.31 20 May 1996 14:14:42 EHOWARDX
  136. * Fixed typo.
  137. *
  138. * Rev 1.30 20 May 1996 14:05:20 EHOWARDX
  139. * Removed dwTransId formal parameter from H245EndConnection().
  140. *
  141. * Rev 1.29 16 May 1996 15:51:56 EHOWARDX
  142. * Fixed typo in H245_INVALID_CAPDESCID.
  143. *
  144. * Rev 1.28 16 May 1996 10:57:46 unknown
  145. * Added H245_INVALID_CAPDESCID.
  146. *
  147. * Rev 1.27 14 May 1996 20:20:14 EHOWARDX
  148. * Removed H245_IND_SYS.
  149. *
  150. * Rev 1.26 14 May 1996 19:00:58 EHOWARDX
  151. * Deleted unused H245_SYSCON_xxx values.
  152. *
  153. * Rev 1.25 14 May 1996 16:58:48 EHOWARDX
  154. * Changed H245_IND_CAPDESC_T To H245_TOTCAPDESC_T.
  155. * H245EnumCaps() cap desc callback now takes single pointer to
  156. * H245_TOTCAPDESC_T instead of separate H245_CAPDESCID_T and
  157. * H245_CAPDESC_T pointer.
  158. *
  159. * Rev 1.24 13 May 1996 23:13:46 EHOWARDX
  160. * Everything ready for Micrsoft drop on the 17th.
  161. *
  162. * Rev 1.23 13 May 1996 15:43:16 EHOWARDX
  163. * Changed return type of H245CopyCapDescriptor from H245_CAPDESC_T pointer
  164. * to H245_TOTCAPDESC_T pointer.
  165. *
  166. * Rev 1.22 13 May 1996 14:05:16 EHOWARDX
  167. * Added H245CopyCapDescriptor() and H245FreeCapDescriptor().
  168. *
  169. * Rev 1.21 11 May 1996 20:00:34 EHOWARDX
  170. * Changed IS1381 to IS13818 (correct name for capability).
  171. * Changed H245SystemControl() - eliminated dwTransId and added
  172. * H245_SYSCON_GET_XXX requests.
  173. *
  174. * Rev 1.20 10 May 1996 17:38:28 unknown
  175. * Changed H245GetCaps and H245EnumCaps to also return Cap Descriptors.
  176. *
  177. * Rev 1.19 09 May 1996 20:22:58 EHOWARDX
  178. * Latest and greatest...
  179. *
  180. * Rev 1.35 09 May 1996 19:38:14 EHOWARDX
  181. * Redesigned locking logic and added new functionality.
  182. *
  183. * Rev 1.34 06 May 1996 13:19:44 EHOWARDX
  184. * Moved enums out of structures.
  185. * Added H245NonStandardH221() and H245NonStandardObject().
  186. *
  187. * Rev 1.33 01 May 1996 19:29:16 EHOWARDX
  188. * Added H245CopyCap(), H245FreeCap(), H245CopyMux(), H245FreeMux().
  189. * Changed H2250_xxx definitions for H.225.0 address to H245_xxx.
  190. *
  191. * Rev 1.32 27 Apr 1996 21:04:26 EHOWARDX
  192. * Changed channel numbers to words, added new open/open ack fields.
  193. *
  194. * Rev 1.31 26 Apr 1996 15:57:14 EHOWARDX
  195. * Added new Terminal Capabilities.
  196. *
  197. * Rev 1.27.1.6 25 Apr 1996 17:53:06 EHOWARDX
  198. * Added H245_INVALID_ID, currently set to zero, should be 0xFFFFFFFF later.
  199. *
  200. * Rev 1.27.1.5 25 Apr 1996 16:50:04 EHOWARDX
  201. * Added new functions as per API Changes spec.
  202. *
  203. * Rev 1.27.1.4 24 Apr 1996 20:57:30 EHOWARDX
  204. * Added new OpenLogicalChannelAck/OpenLogicalChannelReject support.
  205. *
  206. * Rev 1.27.1.3 18 Apr 1996 15:56:42 EHOWARDX
  207. * Updated to 1.30.
  208. *
  209. * Rev 1.27.1.2 16 Apr 1996 20:09:52 EHOWARDX
  210. * Added new H2250LogicalChannelParameter fields.
  211. *
  212. * Rev 1.27.1.1 16 Apr 1996 18:45:24 EHOWARDX
  213. * Added silenceSupression to H.225.0 Logical Channel Parameters.
  214. *
  215. * Rev 1.27.1.0 03 Apr 1996 15:56:14 cjutzi
  216. * Branched for H.323.
  217. *
  218. * Rev 1.27 02 Apr 1996 08:29:44 cjutzi
  219. * - Changed CapDescriptor API
  220. *
  221. * Rev 1.26 01 Apr 1996 16:46:50 cjutzi
  222. *
  223. * - Completed ENdConnection, and made asynch.. rather
  224. * than sync.. as before
  225. * Changed H245ShutDown to be sync rather than async..
  226. *
  227. * Rev 1.25 29 Mar 1996 14:55:52 cjutzi
  228. *
  229. * - added USERINPUT stuff
  230. * - Added hooks for stats in SYSCON H245SystemControl
  231. *
  232. * Rev 1.24 27 Mar 1996 10:55:40 cjutzi
  233. * - added c++ wrapper for API calls..
  234. *
  235. * Rev 1.23 20 Mar 1996 14:42:46 cjutzi
  236. * - added ERROR NO_CAPDESC
  237. *
  238. * Rev 1.22 18 Mar 1996 15:14:56 cjutzi
  239. *
  240. * - added RxPort and TEST_TIMER
  241. *
  242. * Rev 1.21 12 Mar 1996 15:49:24 cjutzi
  243. *
  244. * - implemented locking
  245. * - added EndSession
  246. * - added Shutdown
  247. *
  248. *
  249. * Rev 1.20 08 Mar 1996 14:06:04 cjutzi
  250. *
  251. * - Removed Simultanious capability api
  252. * - added CapabilityDescriptor api.. (very similar.. made more sence)
  253. * - compeleted Mux Table upcall information..
  254. *
  255. * Rev 1.19 06 Mar 1996 08:45:58 cjutzi
  256. *
  257. * - added ERROR ASN1
  258. *
  259. * Rev 1.18 05 Mar 1996 17:32:24 cjutzi
  260. *
  261. * - master slave indication message from Hani.. implemented..
  262. * added H245_IND_MSTSLV ..
  263. *
  264. * Rev 1.17 05 Mar 1996 16:36:46 cjutzi
  265. *
  266. * - removed MUX_ENTRY_DESC_T .. cleaned it up.. don't need it..
  267. *
  268. * Rev 1.16 05 Mar 1996 10:06:30 cjutzi
  269. *
  270. * - added mux table entry stuff
  271. * - changed errors to map to 10000
  272. *
  273. * Rev 1.15 01 Mar 1996 13:46:20 cjutzi
  274. * - added more error messages
  275. *
  276. * Rev 1.14 29 Feb 1996 17:27:38 cjutzi
  277. *
  278. * - bi-directional channel working
  279. *
  280. * Rev 1.13 29 Feb 1996 11:33:50 cjutzi
  281. * - fixed bug w/ H245_CONF_IND_T .. as global union.. fixed to be
  282. * struct
  283. *
  284. * Rev 1.12 29 Feb 1996 08:26:48 cjutzi
  285. *
  286. * - added 2 error messages (SIMCAPID and DATA_FORMAT)
  287. *
  288. * Rev 1.11 27 Feb 1996 13:28:50 cjutzi
  289. * - added global protocol id H245_PROTOID
  290. *
  291. * Rev 1.10 26 Feb 1996 17:24:10 cjutzi
  292. *
  293. * - added MiscCommand.. had to add channel to H245_IND_MISC_T..
  294. *
  295. * Rev 1.9 26 Feb 1996 11:07:24 cjutzi
  296. *
  297. * - added simultanoius caps..
  298. *
  299. * Rev 1.8 16 Feb 1996 12:59:26 cjutzi
  300. * - added tracing and debug..
  301. * - got close to work.. Added structure to H245_IND_T.. new CLOSE indication
  302. *
  303. * Rev 1.7 15 Feb 1996 14:13:08 cjutzi
  304. *
  305. * - re-arranged the AL_T entries for more clairity..
  306. *
  307. * Rev 1.6 15 Feb 1996 10:48:30 cjutzi
  308. *
  309. * - major changes..
  310. * - added MUX_T
  311. * - changed H245_IND_T
  312. * - changed IND_OPEN/IND_OPEN_NEEDSRSP etc..
  313. *
  314. * Rev 1.5 09 Feb 1996 16:14:04 cjutzi
  315. *
  316. * - removed init_success
  317. * - removed shutdown success
  318. * - added masterslave type for callback/confirm
  319. * - added SYSCON TraceLvl
  320. *
  321. *****************************************************************************/
  322. //
  323. // H.245 return codes
  324. //
  325. #if defined(OIL)
  326. #include "common.x"
  327. #define HRESULT RESULT
  328. #define ERROR_BASE_ID 0x8000
  329. #define MAKE_H245_ERROR(error) (error)
  330. #define H245_ERROR_OK 0
  331. #define H245_ERROR_INVALID_DATA_FORMAT MAKE_H245_ERROR(ERROR_BASE_ID+0x01) /* Data Structure passed down is somehow invalid */
  332. #define H245_ERROR_NOMEM MAKE_H245_ERROR(ERROR_BASE_ID+0x02) /* memory allocation failure */
  333. #define H245_ERROR_NOSUP MAKE_H245_ERROR(ERROR_BASE_ID+0x03) /* H245 feature not valid, or not in this H245 spec */
  334. #define H245_ERROR_PARAM MAKE_H245_ERROR(ERROR_BASE_ID+0x04) /* invalid parameter or data structure passed to API*/
  335. #define H245_ERROR_ALREADY_INIT MAKE_H245_ERROR(ERROR_BASE_ID+0x05) /* system has already been initialized */
  336. #define H245_ERROR_NOT_CONNECTED MAKE_H245_ERROR(ERROR_BASE_ID+0x06) /* system is not in the connected state */
  337. #else
  338. #pragma warning( disable : 4115 4201 4214 4514 )
  339. #include "apierror.h"
  340. #define H245_ERROR_OK NOERROR
  341. #define H245_ERROR_INVALID_DATA_FORMAT MAKE_H245_ERROR(ERROR_INVALID_DATA) /* Data Structure passed down is somehow invalid */
  342. #define H245_ERROR_NOMEM MAKE_H245_ERROR(ERROR_OUTOFMEMORY) /* memory allocation failure */
  343. #define H245_ERROR_NOSUP MAKE_H245_ERROR(ERROR_NOT_SUPPORTED) /* H245 feature not valid, or not in this H245 spec */
  344. #define H245_ERROR_PARAM MAKE_H245_ERROR(ERROR_INVALID_PARAMETER) /* invalid parameter or data structure passed to API*/
  345. #define H245_ERROR_ALREADY_INIT MAKE_H245_ERROR(ERROR_ALREADY_INITIALIZED)/* system has already been initialized */
  346. #define H245_ERROR_NOT_CONNECTED MAKE_H245_ERROR(ERROR_NOT_CONNECTED) /* system is not in the connected state */
  347. #endif
  348. #define H245_ERROR_NORESOURCE MAKE_H245_ERROR(ERROR_BASE_ID+0x10) /* No resources left for this call */
  349. #define H245_ERROR_NOTIMP MAKE_H245_ERROR(ERROR_BASE_ID+0x11) /* H245 feature should be implemented.. but is not */
  350. #define H245_ERROR_SUBSYS MAKE_H245_ERROR(ERROR_BASE_ID+0x12) /* subsystem failure.. error unknown */
  351. #define H245_ERROR_FATAL MAKE_H245_ERROR(ERROR_BASE_ID+0x13) /* fatal error.. system will be coming down.. */
  352. #define H245_ERROR_MAXTBL MAKE_H245_ERROR(ERROR_BASE_ID+0x14) /* you have reached the maxium number of tbl entries*/
  353. #define H245_ERROR_CHANNEL_INUSE MAKE_H245_ERROR(ERROR_BASE_ID+0x15) /* channel is currently in use */
  354. #define H245_ERROR_INVALID_CAPID MAKE_H245_ERROR(ERROR_BASE_ID+0x16) /* Invalid Cap ID.. can not be found */
  355. #define H245_ERROR_INVALID_OP MAKE_H245_ERROR(ERROR_BASE_ID+0x17) /* Invalid operation at this time.. */
  356. #define H245_ERROR_UNKNOWN MAKE_H245_ERROR(ERROR_BASE_ID+0x18) /* unknown error */
  357. #define H245_ERROR_NOBANDWIDTH MAKE_H245_ERROR(ERROR_BASE_ID+0x19) /* Bandwidth will not allow this */
  358. #define H245_ERROR_LOSTCON MAKE_H245_ERROR(ERROR_BASE_ID+0x1A) /* System connection .. channel 0 was lost */
  359. #define H245_ERROR_INVALID_MUXTBLENTRY MAKE_H245_ERROR(ERROR_BASE_ID+0x1B) /* Invalid Multiplex Table Entry */
  360. #define H245_ERROR_INVALID_INST MAKE_H245_ERROR(ERROR_BASE_ID+0x1C) /* instance is either no longer valid or is invalid */
  361. #define H245_ERROR_INPROCESS MAKE_H245_ERROR(ERROR_BASE_ID+0x1D) /* request is denied.. action already in process */
  362. #define H245_ERROR_INVALID_STATE MAKE_H245_ERROR(ERROR_BASE_ID+0x1E) /* Not proper state to process request */
  363. #define H245_ERROR_TIMEOUT MAKE_H245_ERROR(ERROR_BASE_ID+0x1F) /* Timeout occured */
  364. #define H245_ERROR_INVALID_CHANNEL MAKE_H245_ERROR(ERROR_BASE_ID+0x20) /* Invalid channel */
  365. #define H245_ERROR_INVALID_CAPDESCID MAKE_H245_ERROR(ERROR_BASE_ID+0x21) /* Invalid Capbility Descriptor ID */
  366. #define H245_ERROR_CANCELED MAKE_H245_ERROR(ERROR_BASE_ID+0x22) /* operation you are responding to has been canceled*/
  367. #define H245_ERROR_MUXELEMENT_DEPTH MAKE_H245_ERROR(ERROR_BASE_ID+0x23) /* Mux Table Entry is too complex.. MAX recursion */
  368. #define H245_ERROR_MUXELEMENT_WIDTH MAKE_H245_ERROR(ERROR_BASE_ID+0x24) /* Mux Table Entry has reached max subelement width */
  369. #define H245_ERROR_ASN1 MAKE_H245_ERROR(ERROR_BASE_ID+0x25) /* ASN1 PDU compiler error - see PDU log */
  370. #define H245_ERROR_NO_MUX_CAPS MAKE_H245_ERROR(ERROR_BASE_ID+0x26) /* Mux Capabilities have not been loaded */
  371. #define H245_ERROR_NO_CAPDESC MAKE_H245_ERROR(ERROR_BASE_ID+0x27) /* No Capability Descriptors set */
  372. #if defined(REMOVE_FROM_TSP)
  373. // declare exported functions
  374. #if defined(H245DLL_EXPORT)
  375. #define H245DLL __declspec (dllexport)
  376. #else // (H245DLL_EXPORT)
  377. #define H245DLL __declspec (dllimport)
  378. #endif // (H245DLL_EXPORT)
  379. #else // REMOVE_FROM_TSP
  380. #define H245DLL
  381. #endif // REMOVE_FROM_TSP
  382. /************************************/
  383. /* ASN.1 DATASTRUCTURES ABSTRACTION */
  384. /************************************/
  385. #include "h245asn1.h"
  386. typedef struct NonStandardIdentifier H245_NONSTANDID_T;
  387. typedef struct NonStandardParameter H245_NONSTANDARD_PARAMETER_T;
  388. typedef H245_NONSTANDARD_PARAMETER_T H245_CAP_NONSTANDARD_T;
  389. typedef struct H261VideoCapability H245_CAP_H261_T;
  390. typedef struct H262VideoCapability H245_CAP_H262_T;
  391. typedef struct H263VideoCapability H245_CAP_H263_T;
  392. typedef struct IS11172VideoCapability H245_CAP_VIS11172_T;
  393. typedef struct IS11172AudioCapability H245_CAP_AIS11172_T;
  394. typedef struct IS13818AudioCapability H245_CAP_IS13818_T;
  395. typedef struct DataApplicationCapability H245_CAP_DATAAPPLICATION_T;
  396. typedef struct H222Capability H245_CAP_H222_T;
  397. typedef struct H223Capability H245_CAP_H223_T;
  398. typedef struct V76Capability H245_CAP_VGMUX_T;
  399. typedef struct H2250Capability H245_CAP_H2250_T;
  400. typedef struct ConferenceCapability H245_CAP_CONFERENCE_T;
  401. typedef struct TerminalLabel H245_TERMINAL_LABEL_T;
  402. #define PDU_T MltmdSystmCntrlMssg
  403. #define H245_ACCESS_T NetworkAccessParameters
  404. typedef unsigned long H245_INST_T;
  405. typedef unsigned short H245_CHANNEL_T;
  406. typedef unsigned long H245_PORT_T;
  407. #define H245_INVALID_ID ((H245_INST_T)0)
  408. #define H245_INVALID_CHANNEL ((H245_CHANNEL_T)0)
  409. #define H245_INVALID_PORT_NUMBER ((H245_PORT_T)-1)
  410. typedef struct
  411. {
  412. unsigned int length;
  413. unsigned char *value;
  414. } H245_OCTET_STRING_T;
  415. /************************/
  416. /* H245 ABSTRACTION */
  417. /************************/
  418. /* H245_CAPDIR_T */
  419. typedef enum
  420. {
  421. H245_CAPDIR_DONTCARE = 0,
  422. H245_CAPDIR_RMTRX,
  423. H245_CAPDIR_RMTTX,
  424. H245_CAPDIR_RMTRXTX,
  425. H245_CAPDIR_LCLRX,
  426. H245_CAPDIR_LCLTX,
  427. H245_CAPDIR_LCLRXTX
  428. } H245_CAPDIR_T;
  429. /* H245_DATA_T */
  430. typedef enum
  431. {
  432. H245_DATA_DONTCARE = 0,
  433. H245_DATA_NONSTD,
  434. H245_DATA_NULL,
  435. H245_DATA_VIDEO,
  436. H245_DATA_AUDIO,
  437. H245_DATA_DATA,
  438. H245_DATA_ENCRYPT_D,
  439. H245_DATA_CONFERENCE,
  440. H245_DATA_MUX /* mux parameters */
  441. } H245_DATA_T;
  442. /* H245_CLIENT_T */
  443. typedef enum
  444. {
  445. H245_CLIENT_DONTCARE = 0, // For H245EnumCap/H245GetCap
  446. H245_CLIENT_NONSTD,
  447. H245_CLIENT_VID_NONSTD,
  448. H245_CLIENT_VID_H261,
  449. H245_CLIENT_VID_H262,
  450. H245_CLIENT_VID_H263,
  451. H245_CLIENT_VID_IS11172,
  452. H245_CLIENT_AUD_NONSTD,
  453. H245_CLIENT_AUD_G711_ALAW64,
  454. H245_CLIENT_AUD_G711_ALAW56,
  455. H245_CLIENT_AUD_G711_ULAW64,
  456. H245_CLIENT_AUD_G711_ULAW56,
  457. H245_CLIENT_AUD_G722_64,
  458. H245_CLIENT_AUD_G722_56,
  459. H245_CLIENT_AUD_G722_48,
  460. H245_CLIENT_AUD_G723,
  461. H245_CLIENT_AUD_G728,
  462. H245_CLIENT_AUD_G729,
  463. H245_CLIENT_AUD_GDSVD,
  464. H245_CLIENT_AUD_IS11172,
  465. H245_CLIENT_AUD_IS13818,
  466. H245_CLIENT_DAT_NONSTD,
  467. H245_CLIENT_DAT_T120,
  468. H245_CLIENT_DAT_DSMCC,
  469. H245_CLIENT_DAT_USERDATA,
  470. H245_CLIENT_DAT_T84,
  471. H245_CLIENT_DAT_T434,
  472. H245_CLIENT_DAT_H224,
  473. H245_CLIENT_DAT_NLPID,
  474. H245_CLIENT_DAT_DSVD,
  475. H245_CLIENT_DAT_H222,
  476. H245_CLIENT_ENCRYPTION_TX,
  477. H245_CLIENT_ENCRYPTION_RX,
  478. H245_CLIENT_CONFERENCE,
  479. // Multiplex capabilities
  480. H245_CLIENT_MUX_NONSTD,
  481. H245_CLIENT_MUX_H222,
  482. H245_CLIENT_MUX_H223,
  483. H245_CLIENT_MUX_VGMUX,
  484. H245_CLIENT_MUX_H2250,
  485. H245_CLIENT_MUX_H223_ANNEX_A
  486. } H245_CLIENT_T;
  487. /* H245_CAP_T */
  488. typedef union
  489. {
  490. H245_CAP_NONSTANDARD_T H245_NonStd; /* not implemented */
  491. H245_CAP_NONSTANDARD_T H245Vid_NONSTD;
  492. H245_CAP_H261_T H245Vid_H261;
  493. H245_CAP_H262_T H245Vid_H262;
  494. H245_CAP_H263_T H245Vid_H263;
  495. H245_CAP_VIS11172_T H245Vid_IS11172;
  496. H245_CAP_NONSTANDARD_T H245Aud_NONSTD;
  497. unsigned short H245Aud_G711_ALAW64;
  498. unsigned short H245Aud_G711_ALAW56;
  499. unsigned short H245Aud_G711_ULAW64;
  500. unsigned short H245Aud_G711_ULAW56;
  501. unsigned short H245Aud_G722_64;
  502. unsigned short H245Aud_G722_56;
  503. unsigned short H245Aud_G722_48;
  504. H245_CAP_G723_T H245Aud_G723;
  505. unsigned short H245Aud_G728;
  506. unsigned short H245Aud_G729;
  507. unsigned short H245Aud_GDSVD;
  508. H245_CAP_AIS11172_T H245Aud_IS11172;
  509. H245_CAP_IS13818_T H245Aud_IS13818;
  510. H245_CAP_DATAAPPLICATION_T H245Dat_NONSTD;
  511. H245_CAP_DATAAPPLICATION_T H245Dat_T120;
  512. H245_CAP_DATAAPPLICATION_T H245Dat_DSMCC;
  513. H245_CAP_DATAAPPLICATION_T H245Dat_USERDATA;
  514. H245_CAP_DATAAPPLICATION_T H245Dat_T84;
  515. H245_CAP_DATAAPPLICATION_T H245Dat_T434;
  516. H245_CAP_DATAAPPLICATION_T H245Dat_H224;
  517. H245_CAP_DATAAPPLICATION_T H245Dat_NLPID;
  518. H245_CAP_DATAAPPLICATION_T H245Dat_DSVD;
  519. H245_CAP_DATAAPPLICATION_T H245Dat_H222;
  520. ASN1_BOOL H245Encryption_TX;
  521. unsigned char H245Encryption_RX;
  522. H245_CAP_CONFERENCE_T H245Conference;
  523. // Multiplex capabilities
  524. H245_CAP_NONSTANDARD_T H245Mux_NONSTD;
  525. H245_CAP_H222_T H245Mux_H222;
  526. H245_CAP_H223_T H245Mux_H223;
  527. H245_CAP_VGMUX_T H245Mux_VGMUX;
  528. H245_CAP_H2250_T H245Mux_H2250;
  529. } H245_CAP_T;
  530. /* H245_CAPID_T */
  531. typedef unsigned short H245_CAPID_T;
  532. #define H245_INVALID_CAPID ((H245_CAPID_T)-1)
  533. #define H245_MAX_CAPID (((H245_CAPID_T)-1) / 2)
  534. /* H245_CAPDESCID_T */
  535. typedef unsigned short H245_CAPDESCID_T;
  536. #define H245_INVALID_CAPDESCID ((H245_CAPDESCID_T)-1)
  537. /* H245_SIMCAP_T */
  538. #define H245_MAX_ALTCAPS 16
  539. typedef struct
  540. {
  541. unsigned short Length; /* number of CapId's in Array */
  542. H245_CAPID_T AltCaps[H245_MAX_ALTCAPS]; /* list of alternatives CapId's */
  543. } H245_SIMCAP_T;
  544. #define H245_MAX_SIMCAPS 16
  545. /* H245_CAPDESC_T */
  546. typedef struct
  547. {
  548. unsigned short Length;
  549. H245_SIMCAP_T SimCapArray[H245_MAX_SIMCAPS];
  550. } H245_CAPDESC_T;
  551. /* H245_TOTCAPDESC_T */
  552. typedef struct
  553. {
  554. H245_CAPDESCID_T CapDescId;
  555. H245_CAPDESC_T CapDesc;
  556. } H245_TOTCAPDESC_T;
  557. /* H245_TOTCAP_T */
  558. typedef struct
  559. {
  560. H245_CAPDIR_T Dir;
  561. H245_DATA_T DataType;
  562. H245_CLIENT_T ClientType;
  563. H245_CAPID_T CapId;
  564. H245_CAP_T Cap;
  565. } H245_TOTCAP_T;
  566. /* H245_CONFIG_T */
  567. typedef enum
  568. {
  569. H245_CONF_H324 = 1,
  570. H245_CONF_H323,
  571. H245_CONF_H310,
  572. H245_CONF_GVD
  573. } H245_CONFIG_T;
  574. /* H245_ACC_REJ_T */
  575. typedef unsigned long H245_ACC_REJ_T;
  576. #define H245_ACC 0
  577. #define H245_REJ 1 // unspecified
  578. // Master Slave Determination reject causes
  579. #define H245_REJ_MSD_IDENTICAL identicalNumbers_chosen
  580. // Terminal Capability Set reject causes
  581. #define H245_REJ_UNDEF_TBL_ENTRY undefinedTableEntryUsed_chosen
  582. #define H245_REJ_DIS_CAP_EXCEED dscrptrCpctyExcdd_chosen
  583. #define H245_REJ_TBLENTRY_CAP_EXCEED tblEntryCpctyExcdd_chosen
  584. // Open Logical Channel reject causes
  585. #define H245_REJ_REV_PARAM unstblRvrsPrmtrs_chosen
  586. #define H245_REJ_TYPE_NOTSUPPORT dataTypeNotSupported_chosen
  587. #define H245_REJ_TYPE_NOTAVAIL dataTypeNotAvailable_chosen
  588. #define H245_REJ_TYPE_UNKNOWN unknownDataType_chosen
  589. #define H245_REJ_AL_COMB dtTypALCmbntnNtSpprtd_chosen
  590. #define H245_REJ_MULTICAST mltcstChnnlNtAllwd_chosen
  591. #define H245_REJ_BANDWIDTH insufficientBandwidth_chosen
  592. #define H245_REJ_STACK sprtStckEstblshmntFld_chosen
  593. #define H245_REJ_SESSION_ID invalidSessionID_chosen
  594. #define H245_REJ_MASTER_SLAVE_CONFLICT masterSlaveConflict_chosen
  595. // Request Channel Close reject causes - use H245_REJ
  596. // Multiplex Table Entry Send reject causes
  597. #define H245_REJ_MUX_COMPLICATED descriptorTooComplex_chosen
  598. // Request Mode reject causes
  599. #define H245_REJ_UNAVAILABLE modeUnavailable_chosen
  600. #define H245_REJ_MULTIPOINT multipointConstraint_chosen
  601. #define H245_REJ_DENIED requestDenied_chosen
  602. /* H245_ACC_REJ_MUX_T */
  603. typedef struct
  604. {
  605. H245_ACC_REJ_T AccRej;
  606. unsigned long MuxEntryId;
  607. } H245_ACC_REJ_MUX_T[15];
  608. /* H245_H222_LOGICAL_PARAM_T */
  609. typedef struct
  610. {
  611. unsigned short resourceID;
  612. unsigned short subChannelID;
  613. ASN1_BOOL pcr_pidPresent;
  614. unsigned short pcr_pid; // optional
  615. H245_OCTET_STRING_T programDescriptors; // optional
  616. H245_OCTET_STRING_T streamDescriptors; // optional
  617. } H245_H222_LOGICAL_PARAM_T;
  618. /* H245_H223_LOGICAL_PARAM_T */
  619. typedef enum
  620. {
  621. H245_H223_AL_NONSTD = H223LCPs_aLTp_nnStndrd_chosen,
  622. H245_H223_AL_AL1FRAMED = H223LCPs_aLTp_al1Frmd_chosen,
  623. H245_H223_AL_AL1NOTFRAMED = H223LCPs_aLTp_al1NtFrmd_chosen,
  624. H245_H223_AL_AL2NOSEQ = H223LCPs_aLTp_a2WSNs_1_chosen,
  625. H245_H223_AL_AL2SEQ = H223LCPs_aLTp_a2WSNs_2_chosen,
  626. H245_H223_AL_AL3 = H223LCPs_aLTp_al3_chosen
  627. } H245_H223_AL_T;
  628. typedef struct
  629. {
  630. H245_H223_AL_T AlType;
  631. unsigned int SndBufSize; // 0..16777215
  632. unsigned char CtlFldOctet; // 0..2
  633. ASN1_BOOL SegmentFlag;
  634. H245_NONSTANDARD_PARAMETER_T H223_NONSTD;
  635. } H245_H223_LOGICAL_PARAM_T;
  636. /* H245_VGMUX_LOGICAL_PARAM_T */
  637. typedef enum
  638. {
  639. H245_V76_CRC8BIT = crc8bit_chosen,
  640. H245_V76_CRC16BIT = crc16bit_chosen,
  641. H245_V76_CRC32BIT = crc32bit_chosen
  642. } H245_V76_CRC_LENGTH_T;
  643. typedef enum
  644. {
  645. H245_V76_WITH_ADDRESS = wAddress_chosen,
  646. H245_V76_WITHOUT_ADDRESS = woAddress_chosen
  647. } H245_V76_SUSPEND_RESUME_T;
  648. typedef enum
  649. {
  650. H245_V76_ERM = eRM_chosen,
  651. H245_V76_UNERM = uNERM_chosen
  652. } H245_V76_MODE_T;
  653. typedef enum
  654. {
  655. H245_V76_REJ = rej_chosen,
  656. H245_V76_SREJ = sREJ_chosen,
  657. H245_V76_MSREJ = mSREJ_chosen
  658. } H245_V76_RECOVERY_T;
  659. typedef struct
  660. {
  661. H245_V76_CRC_LENGTH_T crcLength;
  662. unsigned short n401;
  663. ASN1_BOOL loopbackTestProcedure;
  664. H245_V76_SUSPEND_RESUME_T suspendResume;
  665. ASN1_BOOL uIH;
  666. H245_V76_MODE_T mode;
  667. unsigned short windowSize; // Only valid if mode = ERM
  668. H245_V76_RECOVERY_T recovery; // Only valid if mode = ERM
  669. ASN1_BOOL audioHeaderPresent;
  670. } H245_VGMUX_LOGICAL_PARAM_T;
  671. typedef struct
  672. {
  673. unsigned char type;
  674. /* Note: All unicast types should be odd */
  675. #define H245_IP_UNICAST 1
  676. #define H245_IP_MULTICAST 2
  677. #define H245_IP6_UNICAST 3
  678. #define H245_IP6_MULTICAST 4
  679. #define H245_IPSSR_UNICAST 5 // IP Strict Source Route
  680. #define H245_IPLSR_UNICAST 6 // IP Loose Source Route
  681. #define H245_IPX_UNICAST 9
  682. #define H245_NETBIOS_UNICAST 11
  683. union
  684. {
  685. // type == H245_IP_UNICAST or H245_IP_MULTICAST
  686. struct
  687. {
  688. unsigned short tsapIdentifier;
  689. unsigned char network[4];
  690. } ip;
  691. // type == H245_IP6_UNICAST or H245_IP6_MULTICAST
  692. struct
  693. {
  694. unsigned short tsapIdentifier;
  695. unsigned char network[16];
  696. } ip6;
  697. // type == H245_IPSSR_UNICAST or H245_IPLSR_UNICAST
  698. struct
  699. {
  700. unsigned short tsapIdentifier;
  701. unsigned char network[4];
  702. unsigned char * route; // Routing info
  703. unsigned long dwCount; // Number of addresses in above
  704. } ipSourceRoute;
  705. // type == H245_IPX_UNICAST
  706. struct
  707. {
  708. unsigned char node[6];
  709. unsigned char netnum[4];
  710. unsigned char tsapIdentifier[2];
  711. } ipx;
  712. // type == H245_NETBIOS_UNICAST
  713. unsigned char netBios[16];
  714. } u;
  715. } H245_TRANSPORT_ADDRESS_T;
  716. /* H245_H2250_LOGICAL_PARAM_T */
  717. typedef struct
  718. {
  719. // Note: first 8 fields MUST be same as H245_H2250ACK_LOGICAL_PARAM_T
  720. H2250LCPs_nnStndrdLink nonStandardList; // Optional
  721. H245_TRANSPORT_ADDRESS_T mediaChannel; // Media Channel Address
  722. ASN1_BOOL mediaChannelPresent; // TRUE if previous field used
  723. H245_TRANSPORT_ADDRESS_T mediaControlChannel; // Reverse RTCP channel
  724. ASN1_BOOL mediaControlChannelPresent; // TRUE if previous field used
  725. unsigned char dynamicRTPPayloadType; // 96..127
  726. ASN1_BOOL dynamicRTPPayloadTypePresent; // TRUE if previous field used
  727. unsigned char sessionID; // 0..255
  728. unsigned char associatedSessionID; // 1..255
  729. ASN1_BOOL associatedSessionIDPresent; // TRUE if previous field used
  730. ASN1_BOOL mediaGuaranteed; // TRUE if guaranteed delivery
  731. ASN1_BOOL mediaGuaranteedPresent; // TRUE if previous field used
  732. ASN1_BOOL mediaControlGuaranteed; // TRUE if previous field used
  733. ASN1_BOOL mediaControlGuaranteedPresent;// TRUE if previous field used
  734. ASN1_BOOL silenceSuppression; // TRUE if using silence suppression
  735. ASN1_BOOL silenceSuppressionPresent; // TRUE if previous field used
  736. H245_TERMINAL_LABEL_T destination; // Terminal label for destination
  737. ASN1_BOOL destinationPresent; // TRUE if previous field used
  738. ASN1_BOOL h261aVideoPacketization;
  739. } H245_H2250_LOGICAL_PARAM_T;
  740. /* H245_H2250ACK_LOGICAL_PARAM_T */
  741. typedef struct
  742. {
  743. H2250LCAPs_nnStndrdLink nonStandardList; // Optional
  744. H245_TRANSPORT_ADDRESS_T mediaChannel; // Transport address
  745. ASN1_BOOL mediaChannelPresent; // TRUE if previous field used
  746. H245_TRANSPORT_ADDRESS_T mediaControlChannel; // Forward RTCP channel
  747. ASN1_BOOL mediaControlChannelPresent; // TRUE if previous field used
  748. unsigned char dynamicRTPPayloadType; // 96..127
  749. ASN1_BOOL dynamicRTPPayloadTypePresent;// TRUE if previous field used
  750. unsigned char sessionID; // 1..255
  751. ASN1_BOOL sessionIDPresent; // TRUE if previous field used
  752. } H245_H2250ACK_LOGICAL_PARAM_T;
  753. // Comments from MikeV.
  754. // 07/17/98, mikev comments: this enum is hacky - it's using the ASN.1 choice
  755. // integers to tag internal structures. The internal structures don't always
  756. // have a 1:1 relationship with the ASN.1. For example, H245_H2250ACK_LOGICAL_PARAM_T
  757. // is tagged H245_H2250ACK, and there is no real "choice" for that
  758. /* H245_MUX_T */
  759. typedef enum
  760. {
  761. H245_H222 = fLCPs_mPs_h222LCPs_chosen,
  762. H245_H223 = fLCPs_mPs_h223LCPs_chosen,
  763. H245_VGMUX = fLCPs_mPs_v76LCPs_chosen,
  764. H245_H2250 = fLCPs_mPs_h2250LCPs_chosen,
  765. H245_H2250ACK = H245_H2250 + 1
  766. } H245_MUX_KIND_T;
  767. typedef struct
  768. {
  769. H245_MUX_KIND_T Kind;
  770. union
  771. {
  772. H245_H222_LOGICAL_PARAM_T H222;
  773. H245_H223_LOGICAL_PARAM_T H223;
  774. H245_VGMUX_LOGICAL_PARAM_T VGMUX;
  775. H245_H2250_LOGICAL_PARAM_T H2250;
  776. H245_H2250ACK_LOGICAL_PARAM_T H2250ACK;
  777. } u;
  778. } H245_MUX_T;
  779. /*
  780. H245_MUX_ENTRY_ELEMENT_T
  781. This structure defines the multiplex pattern
  782. which will be used to decode bit patterns in
  783. a given mux table entry. the Kind defines
  784. whether this is a recursive structure (i.e.
  785. pointing to yet another Mux Entry Element) or
  786. whether it is a terminating leaf in the recursive
  787. mux tree.
  788. RepeatCount indicates how many bits should be
  789. used for this channel. If bit count == 0 this
  790. indicates repeat sequence until close flag
  791. */
  792. typedef enum
  793. {
  794. H245_MUX_LOGICAL_CHANNEL = 1, /* logical channel number (Terminate list) */
  795. H245_MUX_ENTRY_ELEMENT /* recursive.. yet another one */
  796. } H245_MUX_ENTRY_KIND_T;
  797. typedef struct H245_MUX_ENTRY_ELEMENT_T
  798. {
  799. struct H245_MUX_ENTRY_ELEMENT_T *pNext;
  800. H245_MUX_ENTRY_KIND_T Kind;
  801. union
  802. {
  803. H245_CHANNEL_T Channel;
  804. struct H245_MUX_ENTRY_ELEMENT_T *pMuxTblEntryElem;
  805. } u;
  806. /* RepeatCount */
  807. /* RepeatCount == 0 -> repeat until close */
  808. /* RepeatCount != 0 -> repeate count */
  809. unsigned long RepeatCount;
  810. } H245_MUX_ENTRY_ELEMENT_T;
  811. /*
  812. H245_MUX_TABLE_T
  813. an H245 Mux Table is defined as a linked list of
  814. Mux Entry Descriptors. Each descriptor has an
  815. associated entry number. These entry numbers
  816. range from 1-15 and must be unique within the table.
  817. The end of the list is designated by a pNext == NULL
  818. */
  819. typedef struct H245_MUX_TABLE_T
  820. {
  821. struct H245_MUX_TABLE_T *pNext;
  822. unsigned long MuxEntryId;
  823. H245_MUX_ENTRY_ELEMENT_T *pMuxTblEntryElem; /* NULL indicates delete entry */
  824. } H245_MUX_TABLE_T;
  825. /********************/
  826. /********************/
  827. /* Indicator Code */
  828. /********************/
  829. /********************/
  830. #define H245_IND_MSTSLV 0x01
  831. #define H245_IND_CAP 0x02
  832. #define H245_IND_CESE_RELEASE 0x30
  833. #define H245_IND_OPEN 0x03
  834. #define H245_IND_OPEN_CONF 0x04
  835. #define H245_IND_CLOSE 0x05
  836. #define H245_IND_REQ_CLOSE 0x06
  837. #define H245_IND_CLCSE_RELEASE 0x31
  838. #define H245_IND_MUX_TBL 0x07
  839. #define H245_IND_MTSE_RELEASE 0x08
  840. #define H245_IND_RMESE 0x09
  841. #define H245_IND_RMESE_RELEASE 0x0A
  842. #define H245_IND_MRSE 0x0B
  843. #define H245_IND_MRSE_RELEASE 0x0C
  844. #define H245_IND_MLSE 0x0D
  845. #define H245_IND_MLSE_RELEASE 0x0E
  846. #define H245_IND_NONSTANDARD_REQUEST 0x0F
  847. #define H245_IND_NONSTANDARD_RESPONSE 0x10
  848. #define H245_IND_NONSTANDARD_COMMAND 0x11
  849. #define H245_IND_NONSTANDARD 0x12
  850. #define H245_IND_MISC_COMMAND 0x13
  851. #define H245_IND_MISC 0x14
  852. #define H245_IND_COMM_MODE_REQUEST 0x15
  853. #define H245_IND_COMM_MODE_RESPONSE 0x16
  854. #define H245_IND_COMM_MODE_COMMAND 0x17
  855. #define H245_IND_CONFERENCE_REQUEST 0x18
  856. #define H245_IND_CONFERENCE_RESPONSE 0x19
  857. #define H245_IND_CONFERENCE_COMMAND 0x1A
  858. #define H245_IND_CONFERENCE 0x1B
  859. #define H245_IND_SEND_TERMCAP 0x1C
  860. #define H245_IND_ENCRYPTION 0x1D
  861. #define H245_IND_FLOW_CONTROL 0x1E
  862. #define H245_IND_ENDSESSION 0x1F
  863. #define H245_IND_FUNCTION_NOT_UNDERSTOOD 0x20
  864. #define H245_IND_JITTER 0x21
  865. #define H245_IND_H223_SKEW 0x22
  866. #define H245_IND_NEW_ATM_VC 0x23
  867. #define H245_IND_USERINPUT 0x24
  868. #define H245_IND_H2250_MAX_SKEW 0x25
  869. #define H245_IND_MC_LOCATION 0x26
  870. #define H245_IND_VENDOR_ID 0x27
  871. #define H245_IND_FUNCTION_NOT_SUPPORTED 0x28
  872. #define H245_IND_H223_RECONFIG 0x29
  873. #define H245_IND_H223_RECONFIG_ACK 0x2A
  874. #define H245_IND_H223_RECONFIG_REJECT 0x2B
  875. /* H245_MSTSLV_T */
  876. typedef enum
  877. {
  878. H245_INDETERMINATE = 0, // Master/Slave Determination failed
  879. H245_MASTER = master_chosen, // Local terminal is Master
  880. H245_SLAVE = slave_chosen // Local terminal is Slave
  881. } H245_MSTSLV_T;
  882. /* H245_IND_OPEN_T */
  883. typedef struct
  884. {
  885. /* for receive */
  886. H245_CHANNEL_T RxChannel;
  887. H245_PORT_T RxPort; // optional
  888. H245_DATA_T RxDataType;
  889. H245_CLIENT_T RxClientType;
  890. H245_CAP_T *pRxCap;
  891. H245_MUX_T *pRxMux;
  892. /* for bi-directional channel */
  893. /* requested transmit stuff */
  894. H245_DATA_T TxDataType;
  895. H245_CLIENT_T TxClientType;
  896. H245_CAP_T *pTxCap;
  897. H245_MUX_T *pTxMux;
  898. H245_ACCESS_T *pSeparateStack; // optional
  899. } H245_IND_OPEN_T;
  900. /* H245_IND_OPEN_CONF_T */
  901. typedef struct
  902. {
  903. /* receive channel */
  904. /* remote requested channel # */
  905. H245_CHANNEL_T RxChannel;
  906. /* transmit channel */
  907. /* locally opened transmit channel # */
  908. H245_CHANNEL_T TxChannel;
  909. } H245_IND_OPEN_CONF_T;
  910. /* H245_IND_CLOSE_T */
  911. typedef enum
  912. {
  913. H245_USER = user_chosen,
  914. H245_LCSE = lcse_chosen
  915. } H245_IND_CLOSE_REASON_T;
  916. typedef struct
  917. {
  918. H245_CHANNEL_T Channel;
  919. H245_IND_CLOSE_REASON_T Reason;
  920. } H245_IND_CLOSE_T;
  921. /* H245_IND_MUX_TBL */
  922. typedef struct
  923. {
  924. H245_MUX_TABLE_T *pMuxTbl;
  925. unsigned long Count;
  926. } H245_IND_MUXTBL_T;
  927. /* H245_RMESE_T */
  928. typedef struct
  929. {
  930. unsigned short awMultiplexTableEntryNumbers[15];
  931. unsigned long dwCount;
  932. } H245_RMESE_T;
  933. /* H245_IND_MRSE_T */
  934. typedef struct
  935. {
  936. RequestedModesLink pRequestedModes;
  937. } H245_IND_MRSE_T;
  938. /* H245_MLSE_T */
  939. typedef enum
  940. {
  941. H245_SYSTEM_LOOP = systemLoop_chosen,
  942. H245_MEDIA_LOOP = mediaLoop_chosen,
  943. H245_CHANNEL_LOOP = logicalChannelLoop_chosen
  944. } H245_LOOP_TYPE_T;
  945. typedef struct
  946. {
  947. H245_LOOP_TYPE_T LoopType;
  948. H245_CHANNEL_T Channel;
  949. } H245_MLSE_T;
  950. /* H245_IND_ENDSESSION_T */
  951. typedef enum
  952. {
  953. H245_ENDSESSION_NONSTD = EndSssnCmmnd_nonStandard_chosen,
  954. H245_ENDSESSION_DISCONNECT = disconnect_chosen,
  955. H245_ENDSESSION_TELEPHONY,
  956. H245_ENDSESSION_V8BIS,
  957. H245_ENDSESSION_V34DSVD,
  958. H245_ENDSESSION_V34DUPFAX,
  959. H245_ENDSESSION_V34H324
  960. } H245_ENDSESSION_T;
  961. typedef struct
  962. {
  963. H245_ENDSESSION_T SessionMode;
  964. /* if non standard chosen */
  965. H245_NONSTANDARD_PARAMETER_T SessionNonStd;
  966. } H245_IND_ENDSESSION_T;
  967. /* H245_IND_NONSTANDARD_T */
  968. typedef struct
  969. {
  970. unsigned char * pData;
  971. unsigned long dwDataLength;
  972. unsigned short * pwObjectId;
  973. unsigned long dwObjectIdLength;
  974. unsigned char byCountryCode;
  975. unsigned char byExtension;
  976. unsigned short wManufacturerCode;
  977. } H245_IND_NONSTANDARD_T;
  978. typedef struct
  979. {
  980. CMTEy_nnStndrdLink pNonStandard; // NULL if not present
  981. unsigned char sessionID; // 0..255
  982. unsigned char associatedSessionID; // 1..255
  983. ASN1_BOOL associatedSessionIDPresent; // TRUE if previous field used
  984. H245_TERMINAL_LABEL_T terminalLabel;
  985. ASN1_BOOL terminalLabelPresent;
  986. unsigned short * pSessionDescription;
  987. unsigned short wSessionDescriptionLength;
  988. H245_TOTCAP_T dataType;
  989. H245_TRANSPORT_ADDRESS_T mediaChannel; // Media Channel Address
  990. ASN1_BOOL mediaChannelPresent; // TRUE if previous field used
  991. H245_TRANSPORT_ADDRESS_T mediaControlChannel; // Reverse RTCP channel
  992. ASN1_BOOL mediaControlChannelPresent; // TRUE if previous field used
  993. ASN1_BOOL mediaGuaranteed; // TRUE if guaranteed delivery
  994. ASN1_BOOL mediaGuaranteedPresent; // TRUE if previous field used
  995. ASN1_BOOL mediaControlGuaranteed; // TRUE if previous field used
  996. ASN1_BOOL mediaControlGuaranteedPresent;// TRUE if previous field used
  997. } H245_COMM_MODE_ENTRY_T;
  998. typedef struct
  999. {
  1000. H245_COMM_MODE_ENTRY_T *pTable;
  1001. unsigned char byTableCount;
  1002. } H245_IND_COMM_MODE_T;
  1003. typedef enum
  1004. {
  1005. H245_REQ_TERMINAL_LIST = terminalListRequest_chosen,
  1006. H245_REQ_MAKE_ME_CHAIR = makeMeChair_chosen,
  1007. H245_REQ_CANCEL_MAKE_ME_CHAIR = cancelMakeMeChair_chosen,
  1008. H245_REQ_DROP_TERMINAL = dropTerminal_chosen,
  1009. H245_REQ_TERMINAL_ID = requestTerminalID_chosen,
  1010. H245_REQ_ENTER_H243_PASSWORD = enterH243Password_chosen,
  1011. H245_REQ_ENTER_H243_TERMINAL_ID = enterH243TerminalID_chosen,
  1012. H245_REQ_ENTER_H243_CONFERENCE_ID = enterH243ConferenceID_chosen
  1013. } H245_CONFER_REQ_ENUM_T;
  1014. typedef struct
  1015. {
  1016. H245_CONFER_REQ_ENUM_T RequestType;
  1017. unsigned char byMcuNumber;
  1018. unsigned char byTerminalNumber;
  1019. } H245_CONFER_REQ_T;
  1020. typedef enum
  1021. {
  1022. H245_RSP_MC_TERMINAL_ID = mCTerminalIDResponse_chosen,
  1023. H245_RSP_TERMINAL_ID = terminalIDResponse_chosen,
  1024. H245_RSP_CONFERENCE_ID = conferenceIDResponse_chosen,
  1025. H245_RSP_PASSWORD = passwordResponse_chosen,
  1026. H245_RSP_TERMINAL_LIST = terminalListResponse_chosen,
  1027. H245_RSP_VIDEO_COMMAND_REJECT = videoCommandReject_chosen,
  1028. H245_RSP_TERMINAL_DROP_REJECT = terminalDropReject_chosen,
  1029. H245_RSP_DENIED_CHAIR_TOKEN,
  1030. H245_RSP_GRANTED_CHAIR_TOKEN
  1031. } H245_CONFER_RSP_ENUM_T;
  1032. typedef struct
  1033. {
  1034. H245_CONFER_RSP_ENUM_T ResponseType;
  1035. unsigned char byMcuNumber;
  1036. unsigned char byTerminalNumber;
  1037. unsigned char *pOctetString;
  1038. unsigned char byOctetStringLength;
  1039. TerminalLabel *pTerminalList;
  1040. unsigned short wTerminalListCount;
  1041. } H245_CONFER_RSP_T;
  1042. typedef enum
  1043. {
  1044. H245_CMD_BROADCAST_CHANNEL = brdcstMyLgclChnnl_chosen,
  1045. H245_CMD_CANCEL_BROADCAST_CHANNEL = cnclBrdcstMyLgclChnnl_chosen,
  1046. H245_CMD_BROADCASTER = makeTerminalBroadcaster_chosen,
  1047. H245_CMD_CANCEL_BROADCASTER = cnclMkTrmnlBrdcstr_chosen,
  1048. H245_CMD_SEND_THIS_SOURCE = sendThisSource_chosen,
  1049. H245_CMD_CANCEL_SEND_THIS_SOURCE = cancelSendThisSource_chosen,
  1050. H245_CMD_DROP_CONFERENCE = dropConference_chosen
  1051. } H245_CONFER_CMD_ENUM_T;
  1052. typedef struct
  1053. {
  1054. H245_CONFER_CMD_ENUM_T CommandType;
  1055. H245_CHANNEL_T Channel;
  1056. unsigned char byMcuNumber;
  1057. unsigned char byTerminalNumber;
  1058. } H245_CONFER_CMD_T;
  1059. typedef enum
  1060. {
  1061. H245_IND_SBE_NUMBER = sbeNumber_chosen,
  1062. H245_IND_TERMINAL_NUMBER_ASSIGN = terminalNumberAssign_chosen,
  1063. H245_IND_TERMINAL_JOINED = terminalJoinedConference_chosen,
  1064. H245_IND_TERMINAL_LEFT = terminalLeftConference_chosen,
  1065. H245_IND_SEEN_BY_ONE_OTHER = seenByAtLeastOneOther_chosen,
  1066. H245_IND_CANCEL_SEEN_BY_ONE_OTHER = cnclSnByAtLstOnOthr_chosen,
  1067. H245_IND_SEEN_BY_ALL = seenByAll_chosen,
  1068. H245_IND_CANCEL_SEEN_BY_ALL = cancelSeenByAll_chosen,
  1069. H245_IND_TERMINAL_YOU_ARE_SEEING = terminalYouAreSeeing_chosen,
  1070. H245_IND_REQUEST_FOR_FLOOR = requestForFloor_chosen
  1071. } H245_CONFER_IND_ENUM_T;
  1072. typedef struct
  1073. {
  1074. H245_CONFER_IND_ENUM_T IndicationType;
  1075. unsigned char bySbeNumber;
  1076. unsigned char byMcuNumber;
  1077. unsigned char byTerminalNumber;
  1078. } H245_CONFER_IND_T;
  1079. typedef enum
  1080. {
  1081. H245_SCOPE_CHANNEL_NUMBER = FCCd_scp_lgclChnnlNmbr_chosen,
  1082. H245_SCOPE_RESOURCE_ID = FlwCntrlCmmnd_scp_rsrcID_chosen,
  1083. H245_SCOPE_WHOLE_MULTIPLEX = FCCd_scp_whlMltplx_chosen
  1084. } H245_SCOPE_T;
  1085. #define H245_NO_RESTRICTION 0xFFFFFFFFL
  1086. typedef struct
  1087. {
  1088. H245_SCOPE_T Scope;
  1089. H245_CHANNEL_T Channel; // only used if Scope is H245_SCOPE_CHANNEL_NUMBER
  1090. unsigned short wResourceID; // only used if Scope is H245_SCOPE_RESOURCE_ID
  1091. unsigned long dwRestriction; // H245_NO_RESTRICTION if no restriction
  1092. } H245_IND_FLOW_CONTROL_T;
  1093. /* H245_USERINPUT_T */
  1094. typedef enum
  1095. {
  1096. H245_USERINPUT_NONSTD = UsrInptIndctn_nnStndrd_chosen,
  1097. H245_USERINPUT_STRING = alphanumeric_chosen
  1098. } H245_USERINPUT_KIND_T;
  1099. typedef struct
  1100. {
  1101. H245_USERINPUT_KIND_T Kind;
  1102. union
  1103. {
  1104. WCHAR * pGenString;
  1105. H245_NONSTANDARD_PARAMETER_T NonStd;
  1106. } u;
  1107. } H245_IND_USERINPUT_T;
  1108. typedef struct
  1109. {
  1110. H245_CHANNEL_T LogicalChannelNumber1;
  1111. H245_CHANNEL_T LogicalChannelNumber2;
  1112. unsigned short wSkew;
  1113. } H245_IND_SKEW_T;
  1114. typedef struct
  1115. {
  1116. H245_NONSTANDID_T Identifier;
  1117. unsigned char *pProductNumber;
  1118. unsigned char byProductNumberLength;
  1119. unsigned char *pVersionNumber;
  1120. unsigned char byVersionNumberLength;
  1121. } H245_IND_VENDOR_ID_T;
  1122. typedef enum
  1123. {
  1124. UNKNOWN,
  1125. REQ_NONSTANDARD,
  1126. REQ_MASTER_SLAVE,
  1127. REQ_TERMCAP_SET,
  1128. REQ_OPEN_LOGICAL_CHANNEL,
  1129. REQ_CLOSE_LOGICAL_CHANNEL,
  1130. REQ_REQUEST_CHANNEL_CLOSE,
  1131. REQ_MULTIPLEX_ENTRY_SEND,
  1132. REQ_REQUEST_MULTIPLEX_ENTRY,
  1133. REQ_REQUEST_MODE,
  1134. REQ_ROUND_TRIP_DELAY,
  1135. REQ_MAINTENANCE_LOOP,
  1136. REQ_COMMUNICATION_MODE,
  1137. REQ_CONFERENCE,
  1138. REQ_H223_ANNEX_A_RECONFIG,
  1139. RSP_NONSTANDARD,
  1140. RSP_MASTER_SLAVE_ACK,
  1141. RSP_MASTER_SLAVE_REJECT,
  1142. RSP_TERMCAP_SET_ACK,
  1143. RSP_TERMCAP_SET_REJECT,
  1144. RSP_OPEN_LOGICAL_CHANNEL_ACK,
  1145. RSP_OPEN_LOGICAL_CHANNEL_REJECT,
  1146. RSP_CLOSE_LOGICAL_CHANNEL_ACK,
  1147. RSP_REQUEST_CHANNEL_CLOSE_ACK,
  1148. RSP_REQUEST_CHANNEL_CLOSE_REJECT,
  1149. RSP_MULTIPLEX_ENTRY_SEND_ACK,
  1150. RSP_MULTIPLEX_ENTRY_SEND_REJECT,
  1151. RSP_REQUEST_MULTIPLEX_ENTRY_ACK,
  1152. RSP_REQUEST_MULTIPLEX_ENTRY_REJECT,
  1153. RSP_REQUEST_MODE_ACK,
  1154. RSP_REQUEST_MODE_REJECT,
  1155. RSP_ROUND_TRIP_DELAY,
  1156. RSP_MAINTENANCE_LOOP_ACK,
  1157. RSP_MAINTENANCE_LOOP_REJECT,
  1158. RSP_COMMUNICATION_MODE,
  1159. RSP_CONFERENCE,
  1160. RSP_H223_ANNEX_A_RECONFIG_ACK,
  1161. RSP_H223_ANNEX_A_RECONFIG_REJECT,
  1162. CMD_NONSTANDARD,
  1163. CMD_MAINTENANCE_LOOP_OFF,
  1164. CMD_SEND_TERMCAP,
  1165. CMD_ENCRYPTION,
  1166. CMD_FLOW_CONTROL,
  1167. CMD_END_SESSION,
  1168. CMD_MISCELLANEOUS,
  1169. CMD_COMMUNICATION_MODE,
  1170. CMD_CONFERENCE,
  1171. IND_NONSTANDARD,
  1172. IND_FUNCTION_NOT_UNDERSTOOD,
  1173. IND_MASTER_SLAVE_RELEASE,
  1174. IND_TERMCAP_SET_RELEASE,
  1175. IND_OPEN_LOGICAL_CHANNEL_CONFIRM,
  1176. IND_REQUEST_CHANNEL_CLOSE_RELEASE,
  1177. IND_MULTIPLEX_ENTRY_SEND_RELEASE,
  1178. IND_REQUEST_MULTIPLEX_ENTRY_RELEASE,
  1179. IND_REQUEST_MODE_RELEASE,
  1180. IND_MISCELLANEOUS,
  1181. IND_JITTER,
  1182. IND_H223_SKEW,
  1183. IND_NEW_ATM_VC,
  1184. IND_USER_INPUT,
  1185. IND_H2250_MAX_SKEW,
  1186. IND_MC_LOCATION,
  1187. IND_CONFERENCE_INDICATION,
  1188. IND_VENDOR_IDENTIFICATION,
  1189. IND_FUNCTION_NOT_SUPPORTED,
  1190. } H245_SUBMESSAGE_T;
  1191. typedef enum
  1192. {
  1193. H245_SYNTAX_ERROR = syntaxError_chosen,
  1194. H245_SEMANTIC_ERROR = semanticError_chosen,
  1195. H245_UNKNOWN_FUNCTION = unknownFunction_chosen
  1196. } H245_FNS_CAUSE_T;
  1197. typedef struct
  1198. {
  1199. H245_FNS_CAUSE_T Cause;
  1200. H245_SUBMESSAGE_T Type;
  1201. } H245_IND_FNS_T;
  1202. /**************/
  1203. /* H245_IND_T */
  1204. /**************/
  1205. typedef struct
  1206. {
  1207. unsigned long Indicator; // Type
  1208. unsigned long dwPreserved; // User supplied dwPreserved from H245Init()
  1209. union
  1210. {
  1211. H245_MSTSLV_T IndMstSlv; // H245_IND_MSTSLV
  1212. // H245_IND_CAP
  1213. // H245_IND_CESE_RELEASE
  1214. H245_IND_OPEN_T IndOpen; // H245_IND_OPEN
  1215. H245_IND_OPEN_CONF_T IndOpenConf; // H245_IND_OPEN_CONF
  1216. H245_IND_CLOSE_T IndClose; // H245_IND_CLOSE
  1217. H245_CHANNEL_T IndReqClose; // H245_IND_REQ_CLOSE
  1218. // H245_IND_CLCSE_RELEASE
  1219. H245_IND_MUXTBL_T IndMuxTbl; // H245_IND_MUX_TBL
  1220. // H245_IND_MTSE_RELEASE
  1221. H245_RMESE_T IndRmese; // H245_IND_RMESE
  1222. // H245_IND_RMESE_RELEASE
  1223. H245_IND_MRSE_T IndMrse; // H245_IND_MRSE
  1224. // H245_IND_MRSE_RELEASE
  1225. H245_MLSE_T IndMlse; // H245_IND_MLSE
  1226. // H245_IND_MLSE_RELEASE
  1227. H245_IND_NONSTANDARD_T IndNonstandardRequest; // H245_IND_NONSTANDARD_REQUEST
  1228. H245_IND_NONSTANDARD_T IndNonstandardResponse; // H245_IND_NONSTANDARD_RESPONSE
  1229. H245_IND_NONSTANDARD_T IndNonstandardCommand; // H245_IND_NONSTANDARD_COMMAND
  1230. H245_IND_NONSTANDARD_T IndNonstandard; // H245_IND_NONSTANDARD
  1231. // H245_IND_MISC_COMMAND
  1232. // H245_IND_MISC
  1233. // H245_IND_COMM_MODE_REQUEST
  1234. H245_IND_COMM_MODE_T IndCommRsp; // H245_IND_COMM_MODE_RESPONSE
  1235. H245_IND_COMM_MODE_T IndCommCmd; // H245_IND_COMM_MODE_COMMAND
  1236. H245_CONFER_REQ_T IndConferReq; // H245_IND_CONFERENCE_REQUEST
  1237. H245_CONFER_RSP_T IndConferRsp; // H245_IND_CONFERENCE_RESPONSE
  1238. H245_CONFER_CMD_T IndConferCmd; // H245_IND_CONFERENCE_COMMAND
  1239. H245_CONFER_IND_T IndConfer; // H245_IND_CONFERENCE
  1240. // H245_IND_SEND_TERMCAP
  1241. // H245_IND_ENCRYPTION
  1242. H245_IND_FLOW_CONTROL_T IndFlowControl; // H245_IND_FLOW_CONTROL
  1243. H245_IND_ENDSESSION_T IndEndSession; // H245_IND_ENDSESSION
  1244. // H245_IND_FUNCTION_NOT_UNDERSTOOD
  1245. // H245_IND_JITTER
  1246. H245_IND_SKEW_T IndH223Skew; // H245_IND_H223_SKEW
  1247. // H245_IND_NEW_ATM_VC
  1248. H245_IND_USERINPUT_T IndUserInput; // H245_IND_USERINPUT
  1249. H245_IND_SKEW_T IndH2250MaxSkew; // H245_IND_H2250_MAX_SKEW
  1250. H245_TRANSPORT_ADDRESS_T IndMcLocation; // H245_IND_MC_LOCATION
  1251. H245_IND_VENDOR_ID_T IndVendorId; // H245_IND_VENDOR_ID
  1252. H245_IND_FNS_T IndFns; // H245_IND_FUNCTION_NOT_SUPPORTED
  1253. // H245_IND_H223_RECONFIG
  1254. // H245_IND_H223_RECONFIG_ACK
  1255. // H245_IND_H223_RECONFIG_REJECT
  1256. } u;
  1257. } H245_IND_T;
  1258. /********************/
  1259. /********************/
  1260. /* Confirm Code */
  1261. /********************/
  1262. /********************/
  1263. #define H245_CONF_INIT_MSTSLV 0x101
  1264. #define H245_CONF_SEND_TERMCAP 0x102
  1265. #define H245_CONF_OPEN 0x103
  1266. #define H245_CONF_NEEDRSP_OPEN 0x104
  1267. #define H245_CONF_CLOSE 0x105
  1268. #define H245_CONF_REQ_CLOSE 0x106
  1269. #define H245_CONF_MUXTBL_SND 0x107
  1270. #define H245_CONF_RMESE 0x109
  1271. #define H245_CONF_RMESE_REJECT 0x10A
  1272. #define H245_CONF_RMESE_EXPIRED 0x10B
  1273. #define H245_CONF_MRSE 0x10C
  1274. #define H245_CONF_MRSE_REJECT 0x10D
  1275. #define H245_CONF_MRSE_EXPIRED 0x10E
  1276. #define H245_CONF_MLSE 0x10F
  1277. #define H245_CONF_MLSE_REJECT 0x110
  1278. #define H245_CONF_MLSE_EXPIRED 0x111
  1279. #define H245_CONF_RTDSE 0x112
  1280. #define H245_CONF_RTDSE_EXPIRED 0x113
  1281. /* H245_CONF_SEND_TERMCAP_T */
  1282. typedef struct
  1283. {
  1284. H245_ACC_REJ_T AccRej;
  1285. } H245_CONF_SEND_TERMCAP_T;
  1286. /* H245_CONF_OPEN_T */
  1287. typedef struct
  1288. {
  1289. H245_ACC_REJ_T AccRej;
  1290. H245_CHANNEL_T TxChannel;
  1291. H245_MUX_T * pTxMux; // optional
  1292. H245_CHANNEL_T RxChannel; // bi-dir only
  1293. H245_MUX_T * pRxMux; // bi-dir only
  1294. H245_PORT_T RxPort; // bi-dir only
  1295. H245_ACCESS_T * pSeparateStack; // optional
  1296. } H245_CONF_OPEN_T;
  1297. typedef H245_CONF_OPEN_T H245_CONF_NEEDRSP_OPEN_T;
  1298. /* H245_CONF_CLOSE_T */
  1299. typedef struct
  1300. {
  1301. H245_ACC_REJ_T AccRej;
  1302. H245_CHANNEL_T Channel;
  1303. } H245_CONF_CLOSE_T;
  1304. /* H245_CONF_REQ_CLOSE_T */
  1305. typedef H245_CONF_CLOSE_T H245_CONF_REQ_CLOSE_T;
  1306. /* H245_CONF_MUXTBL_T */
  1307. typedef struct
  1308. {
  1309. H245_ACC_REJ_T AccRej;
  1310. unsigned long MuxEntryId;
  1311. } H245_CONF_MUXTBL_T;
  1312. /***************/
  1313. /* H245_CONF_T */
  1314. /***************/
  1315. typedef struct
  1316. {
  1317. unsigned long Confirm; // Type
  1318. unsigned long dwPreserved; // User supplied dwPreserved from H245Init()
  1319. unsigned long dwTransId; // User supplied dwTransId from originating call
  1320. HRESULT Error; // Error code
  1321. union // Data for specific indications:
  1322. {
  1323. H245_MSTSLV_T ConfMstSlv; // H245_CONF_INIT_MSTSLV
  1324. H245_CONF_SEND_TERMCAP_T ConfSndTcap; // H245_CONF_SEND_TERMCAP
  1325. H245_CONF_OPEN_T ConfOpen; // H245_CONF_OPEN
  1326. H245_CONF_NEEDRSP_OPEN_T ConfOpenNeedRsp; // H245_CONF_NEEDRSP_OPEN
  1327. H245_CONF_CLOSE_T ConfClose; // H245_CONF_CLOSE
  1328. H245_CONF_REQ_CLOSE_T ConfReqClose; // H245_CONF_REQ_CLOSE
  1329. H245_CONF_MUXTBL_T ConfMuxSnd; // H245_CONF_MUXTBL_SND
  1330. H245_RMESE_T ConfRmese; // H245_CONF_RMESE
  1331. H245_RMESE_T ConfRmeseReject; // H245_CONF_RMESE_REJECT
  1332. // H245_CONF_RMESE_EXPIRED
  1333. unsigned short ConfMrse; // H245_CONF_MRSE
  1334. unsigned short ConfMrseReject; // H245_CONF_MRSE_REJECT
  1335. // H245_CONF_MRSE_EXPIRED
  1336. H245_MLSE_T ConfMlse; // H245_CONF_MLSE
  1337. H245_MLSE_T ConfMlseReject; // H245_CONF_MLSE_REJECT
  1338. // H245_CONF_MLSE_EXPIRED
  1339. // H245_CONF_RTDSE
  1340. // H245_CONF_RTDSE_EXPIRED
  1341. } u;
  1342. } H245_CONF_T;
  1343. typedef enum
  1344. {
  1345. H245_MESSAGE_REQUEST = MltmdSystmCntrlMssg_rqst_chosen,
  1346. H245_MESSAGE_RESPONSE = MSCMg_rspns_chosen,
  1347. H245_MESSAGE_COMMAND = MSCMg_cmmnd_chosen,
  1348. H245_MESSAGE_INDICATION = indication_chosen
  1349. } H245_MESSAGE_TYPE_T;
  1350. /*******************/
  1351. /* H245_CONF_IND_T */
  1352. /*******************/
  1353. typedef enum
  1354. {
  1355. H245_CONF = 1,
  1356. H245_IND
  1357. } H245_CONF_IND_KIND_T;
  1358. typedef struct
  1359. {
  1360. H245_CONF_IND_KIND_T Kind;
  1361. union
  1362. {
  1363. H245_CONF_T Confirm;
  1364. H245_IND_T Indication;
  1365. } u;
  1366. } H245_CONF_IND_T;
  1367. /***************************/
  1368. /* SYSTEM CONTROL MESSAGES */
  1369. /***************************/
  1370. typedef struct
  1371. {
  1372. unsigned long NumPduTx; /* number of tranmitted pdu's */
  1373. unsigned long NumPduRx; /* number of received pdu's */
  1374. unsigned long NumCRCErrors; /* number of crc errors */
  1375. unsigned long NumPduReTx; /* number of pdu's retransmitted */
  1376. } H245_SYSCON_STATS_T;
  1377. #define H245_SYSCON_TRACE_LVL 0x0100 /* pData = &dwTraceLevel */
  1378. #define H245_SYSCON_DUMP_TRACKER 0x0200 /* pData = NULL (debug) */
  1379. #define H245_SYSCON_GET_STATS 0x0300 /* pData = &H245_SYSCON_STATS_T */
  1380. #define H245_SYSCON_RESET_STATS 0x0400 /* pData = NULL */
  1381. #define H245_SYSCON_SET_FSM_N100 0x1000 /* pData = &dwRetryCount */
  1382. #define H245_SYSCON_SET_FSM_T101 0x1100 /* pData = &dwMilliseconds */
  1383. #define H245_SYSCON_SET_FSM_T102 0x1200 /* pData = &dwMilliseconds */
  1384. #define H245_SYSCON_SET_FSM_T103 0x1300 /* pData = &dwMilliseconds */
  1385. #define H245_SYSCON_SET_FSM_T104 0x1400 /* pData = &dwMilliseconds */
  1386. #define H245_SYSCON_SET_FSM_T105 0x1500 /* pData = &dwMilliseconds */
  1387. #define H245_SYSCON_SET_FSM_T106 0x1600 /* pData = &dwMilliseconds */
  1388. #define H245_SYSCON_SET_FSM_T107 0x1700 /* pData = &dwMilliseconds */
  1389. #define H245_SYSCON_SET_FSM_T108 0x1800 /* pData = &dwMilliseconds */
  1390. #define H245_SYSCON_SET_FSM_T109 0x1900 /* pData = &dwMilliseconds */
  1391. #define H245_SYSCON_GET_FSM_N100 0x2000 /* pData = &dwRetryCount */
  1392. #define H245_SYSCON_GET_FSM_T101 0x2100 /* pData = &dwMilliseconds */
  1393. #define H245_SYSCON_GET_FSM_T102 0x2200 /* pData = &dwMilliseconds */
  1394. #define H245_SYSCON_GET_FSM_T103 0x2300 /* pData = &dwMilliseconds */
  1395. #define H245_SYSCON_GET_FSM_T104 0x2400 /* pData = &dwMilliseconds */
  1396. #define H245_SYSCON_GET_FSM_T105 0x2500 /* pData = &dwMilliseconds */
  1397. #define H245_SYSCON_GET_FSM_T106 0x2600 /* pData = &dwMilliseconds */
  1398. #define H245_SYSCON_GET_FSM_T107 0x2700 /* pData = &dwMilliseconds */
  1399. #define H245_SYSCON_GET_FSM_T108 0x2800 /* pData = &dwMilliseconds */
  1400. #define H245_SYSCON_GET_FSM_T109 0x2900 /* pData = &dwMilliseconds */
  1401. /************************/
  1402. /* PROTOCOL ID FOR H245 */
  1403. /************************/
  1404. #define H245_PROTOID "0.0.8.245.0.2"
  1405. /**************************************************/
  1406. /* API Procedure Call Typedefs and API Prototypes */
  1407. /**************************************************/
  1408. typedef unsigned long H245_INST_T;
  1409. typedef HRESULT (*H245_CONF_IND_CALLBACK_T)(H245_CONF_IND_T *, void *);
  1410. typedef int (*H245_CAP_CALLBACK_T)(unsigned long, H245_TOTCAP_T *);
  1411. typedef int (*H245_CAPDESC_CALLBACK_T)(unsigned long, H245_TOTCAPDESC_T *);
  1412. #ifdef __cplusplus
  1413. extern "C" {
  1414. #endif
  1415. H245DLL H245_INST_T
  1416. H245Init (
  1417. H245_CONFIG_T Configuration,
  1418. unsigned long dwPhysId,
  1419. unsigned long *pdwLinkLayerPhysId,
  1420. unsigned long dwPreserved,
  1421. H245_CONF_IND_CALLBACK_T CallBack,
  1422. unsigned char byTerminalType
  1423. );
  1424. H245DLL H245_INST_T
  1425. H245GetInstanceId (unsigned long dwPhysicalId);
  1426. H245DLL HRESULT
  1427. H245EndSession (
  1428. H245_INST_T dwInst,
  1429. H245_ENDSESSION_T Mode,
  1430. const H245_NONSTANDARD_PARAMETER_T * pNonStd
  1431. );
  1432. H245DLL HRESULT
  1433. H245ShutDown (H245_INST_T dwInst);
  1434. H245DLL HRESULT
  1435. H245InitMasterSlave (
  1436. H245_INST_T dwInst,
  1437. unsigned long dwTransId
  1438. );
  1439. H245DLL HRESULT
  1440. H245SetLocalCap (
  1441. H245_INST_T dwInst,
  1442. H245_TOTCAP_T * pTotCap,
  1443. H245_CAPID_T * pCapId
  1444. );
  1445. H245DLL HRESULT
  1446. H245DelLocalCap (
  1447. H245_INST_T dwInst,
  1448. H245_CAPID_T CapId
  1449. );
  1450. H245DLL HRESULT
  1451. H245SetCapDescriptor (
  1452. H245_INST_T dwInst,
  1453. H245_CAPDESC_T *pCapDesc,
  1454. H245_CAPDESCID_T *pCapDescId
  1455. );
  1456. H245DLL HRESULT
  1457. H245DelCapDescriptor (
  1458. H245_INST_T dwInst,
  1459. H245_CAPDESCID_T CapDescId
  1460. );
  1461. H245DLL HRESULT
  1462. H245SendTermCaps (
  1463. H245_INST_T dwInst,
  1464. unsigned long dwTransId
  1465. );
  1466. H245DLL HRESULT
  1467. H245EnumCaps (
  1468. H245_INST_T dwInst,
  1469. unsigned long dwTransId,
  1470. H245_CAPDIR_T Direction,
  1471. H245_DATA_T DataType,
  1472. H245_CLIENT_T ClientType,
  1473. H245_CAP_CALLBACK_T pfCapCallback,
  1474. H245_CAPDESC_CALLBACK_T pfCapDescCallback
  1475. );
  1476. H245DLL HRESULT
  1477. H245GetCaps (
  1478. H245_INST_T dwInst,
  1479. H245_CAPDIR_T Direction,
  1480. H245_DATA_T DataType,
  1481. H245_CLIENT_T ClientType,
  1482. H245_TOTCAP_T * * ppTotCap,
  1483. unsigned long * pdwTotCapLen,
  1484. H245_TOTCAPDESC_T * * ppCapDesc,
  1485. unsigned long * pdwCapDescLen
  1486. );
  1487. H245DLL HRESULT
  1488. H245CopyCap (H245_TOTCAP_T **ppDestTotCap,
  1489. const H245_TOTCAP_T *pTotCap);
  1490. H245DLL HRESULT
  1491. H245FreeCap (H245_TOTCAP_T *pTotCap);
  1492. H245DLL HRESULT
  1493. H245CopyCapDescriptor (H245_TOTCAPDESC_T **ppDestCapDesc,
  1494. const H245_TOTCAPDESC_T *pCapDesc);
  1495. H245DLL HRESULT
  1496. H245FreeCapDescriptor (H245_TOTCAPDESC_T *pCapDesc);
  1497. H245DLL H245_MUX_T *
  1498. H245CopyMux (const H245_MUX_T * pMux);
  1499. H245DLL HRESULT
  1500. H245FreeMux (H245_MUX_T * pMux);
  1501. H245DLL HRESULT
  1502. H245OpenChannel (
  1503. H245_INST_T dwInst,
  1504. unsigned long dwTransId,
  1505. H245_CHANNEL_T wTxChannel,
  1506. const H245_TOTCAP_T * pTxMode,
  1507. const H245_MUX_T * pTxMux,
  1508. H245_PORT_T dwTxPort, // optional
  1509. const H245_TOTCAP_T * pRxMode, // bi-dir only
  1510. const H245_MUX_T * pRxMux, // bi-dir only
  1511. const H245_ACCESS_T * pSeparateStack // optional
  1512. );
  1513. H245DLL HRESULT
  1514. H245OpenChannelAccept (
  1515. H245_INST_T dwInst,
  1516. unsigned long dwTransId,
  1517. H245_CHANNEL_T wRxChannel, // RxChannel from IND_OPEN
  1518. const H245_MUX_T * pRxMux, // optional H2250LogicalChannelAckParameters
  1519. H245_CHANNEL_T wTxChannel, // bi-dir only
  1520. const H245_MUX_T * pTxMux, // bi-dir only optional H2250LogicalChannelParameters
  1521. H245_PORT_T dwTxPort, // bi-dir only optional
  1522. const H245_ACCESS_T * pSeparateStack // optional
  1523. );
  1524. H245DLL HRESULT
  1525. H245OpenChannelReject (
  1526. H245_INST_T dwInst,
  1527. H245_CHANNEL_T wRxChannel, // RxChannel from IND_OPEN
  1528. unsigned short wCause
  1529. );
  1530. H245DLL HRESULT
  1531. H245CloseChannel (
  1532. H245_INST_T dwInst,
  1533. unsigned long dwTransId,
  1534. H245_CHANNEL_T wTxChannel
  1535. );
  1536. H245DLL HRESULT
  1537. H245CloseChannelReq (
  1538. H245_INST_T dwInst,
  1539. unsigned long dwTransId,
  1540. H245_CHANNEL_T wRxChannel
  1541. );
  1542. H245DLL HRESULT
  1543. H245CloseChannelReqResp (
  1544. H245_INST_T dwInst,
  1545. H245_ACC_REJ_T AccRej,
  1546. H245_CHANNEL_T wChannel
  1547. );
  1548. H245DLL HRESULT
  1549. H245SendLocalMuxTable (
  1550. H245_INST_T dwInst,
  1551. unsigned long dwTransId,
  1552. H245_MUX_TABLE_T *pMuxTable
  1553. );
  1554. H245DLL HRESULT
  1555. H245MuxTableIndResp (
  1556. H245_INST_T dwInst,
  1557. H245_ACC_REJ_MUX_T AccRejMux,
  1558. unsigned long dwCount
  1559. );
  1560. H245DLL HRESULT
  1561. H245RequestMultiplexEntry (
  1562. H245_INST_T dwInst,
  1563. unsigned long dwTransId,
  1564. const unsigned short * pwMultiplexTableEntryNumbers,
  1565. unsigned long dwCount
  1566. );
  1567. H245DLL HRESULT
  1568. H245RequestMultiplexEntryAck (
  1569. H245_INST_T dwInst,
  1570. const unsigned short * pwMultiplexTableEntryNumbers,
  1571. unsigned long dwCount
  1572. );
  1573. H245DLL HRESULT
  1574. H245RequestMultiplexEntryReject (
  1575. H245_INST_T dwInst,
  1576. const unsigned short * pwMultiplexTableEntryNumbers,
  1577. unsigned long dwCount
  1578. );
  1579. /*
  1580. H245DLL HRESULT
  1581. H245RequestMode (
  1582. H245_INST_T dwInst,
  1583. unsigned long dwTransId,
  1584. const ModeElement * pModeElements,
  1585. unsigned long dwCount
  1586. );
  1587. */
  1588. H245DLL HRESULT
  1589. H245RequestMode (
  1590. H245_INST_T dwInst,
  1591. unsigned long dwTransId,
  1592. // const ModeElement * pModeElements,
  1593. //[email protected]
  1594. ModeDescription ModeDescriptions[],
  1595. //[email protected]
  1596. unsigned long dwCount
  1597. ) ;
  1598. H245DLL HRESULT
  1599. H245RequestModeAck (
  1600. H245_INST_T dwInst,
  1601. unsigned short wResponse
  1602. );
  1603. H245DLL HRESULT
  1604. H245RequestModeReject (
  1605. H245_INST_T dwInst,
  1606. unsigned short wCause
  1607. );
  1608. H245DLL HRESULT
  1609. H245RoundTripDelayRequest (
  1610. H245_INST_T dwInst,
  1611. unsigned long dwTransId
  1612. );
  1613. H245DLL HRESULT
  1614. H245MaintenanceLoop (
  1615. H245_INST_T dwInst,
  1616. unsigned long dwTransId,
  1617. H245_LOOP_TYPE_T dwLoopType,
  1618. H245_CHANNEL_T wChannel
  1619. );
  1620. H245DLL HRESULT
  1621. H245MaintenanceLoopRelease (H245_INST_T dwInst);
  1622. H245DLL HRESULT
  1623. H245MaintenanceLoopAccept (
  1624. H245_INST_T dwInst,
  1625. H245_CHANNEL_T wChannel
  1626. );
  1627. H245DLL HRESULT
  1628. H245MaintenanceLoopReject (
  1629. H245_INST_T dwInst,
  1630. H245_CHANNEL_T wChannel,
  1631. unsigned short wCause
  1632. );
  1633. H245DLL HRESULT
  1634. H245NonStandardObject (
  1635. H245_INST_T dwInst,
  1636. H245_MESSAGE_TYPE_T MessageType,
  1637. const unsigned char * pData,
  1638. unsigned long dwDataLength,
  1639. const unsigned short * pwObjectId,
  1640. unsigned long dwObjectIdLength
  1641. );
  1642. H245DLL HRESULT
  1643. H245NonStandardH221 (
  1644. H245_INST_T dwInst,
  1645. H245_MESSAGE_TYPE_T MessageType,
  1646. const unsigned char * pData,
  1647. unsigned long dwDataLength,
  1648. unsigned char byCountryCode,
  1649. unsigned char byExtension,
  1650. unsigned short wManufacturerCode
  1651. );
  1652. H245DLL HRESULT
  1653. H245CommunicationModeRequest(H245_INST_T dwInst);
  1654. H245DLL HRESULT
  1655. H245CommunicationModeResponse(
  1656. H245_INST_T dwInst,
  1657. const H245_COMM_MODE_ENTRY_T *pTable,
  1658. unsigned char byTableCount
  1659. );
  1660. H245DLL HRESULT
  1661. H245CommunicationModeCommand(
  1662. H245_INST_T dwInst,
  1663. const H245_COMM_MODE_ENTRY_T *pTable,
  1664. unsigned char byTableCount
  1665. );
  1666. H245DLL HRESULT
  1667. H245ConferenceRequest (
  1668. H245_INST_T dwInst,
  1669. H245_CONFER_REQ_ENUM_T RequestType,
  1670. unsigned char byMcuNumber,
  1671. unsigned char byTerminalNumber
  1672. );
  1673. H245DLL HRESULT
  1674. H245ConferenceResponse (
  1675. H245_INST_T dwInst,
  1676. H245_CONFER_RSP_ENUM_T ResponseType,
  1677. unsigned char byMcuNumber,
  1678. unsigned char byTerminalNumber,
  1679. const unsigned char *pOctetString,
  1680. unsigned char byOctetStringLength,
  1681. const TerminalLabel *pTerminalList,
  1682. unsigned short wTerminalListCount
  1683. );
  1684. H245DLL HRESULT
  1685. H245ConferenceCommand (
  1686. H245_INST_T dwInst,
  1687. H245_CONFER_CMD_ENUM_T CommandType,
  1688. H245_CHANNEL_T Channel,
  1689. unsigned char byMcuNumber,
  1690. unsigned char byTerminalNumber
  1691. );
  1692. H245DLL HRESULT
  1693. H245ConferenceIndication(
  1694. H245_INST_T dwInst,
  1695. H245_CONFER_IND_ENUM_T IndicationType,
  1696. unsigned char bySbeNumber,
  1697. unsigned char byMcuNumber,
  1698. unsigned char byTerminalNumber
  1699. );
  1700. H245DLL HRESULT
  1701. H245UserInput (
  1702. H245_INST_T dwInst,
  1703. const WCHAR * pGenString,
  1704. const H245_NONSTANDARD_PARAMETER_T * pNonStd
  1705. );
  1706. H245DLL HRESULT
  1707. H245FlowControl (
  1708. H245_INST_T dwInst,
  1709. H245_SCOPE_T Scope,
  1710. H245_CHANNEL_T Channel, // only used if Scope is H245_SCOPE_CHANNEL_NUMBER
  1711. unsigned short wResourceID, // only used if Scope is H245_SCOPE_RESOURCE_ID
  1712. unsigned long dwRestriction // H245_NO_RESTRICTION if no restriction
  1713. );
  1714. H245DLL HRESULT
  1715. H245H223SkewIndication (
  1716. H245_INST_T dwInst,
  1717. H245_CHANNEL_T wLogicalChannelNumber1,
  1718. H245_CHANNEL_T wLogicalChannelNumber2,
  1719. unsigned short wSkew
  1720. );
  1721. H245DLL HRESULT
  1722. H245H2250MaximumSkewIndication(
  1723. H245_INST_T dwInst,
  1724. H245_CHANNEL_T wLogicalChannelNumber1,
  1725. H245_CHANNEL_T wLogicalChannelNumber2,
  1726. unsigned short wMaximumSkew
  1727. );
  1728. H245DLL HRESULT
  1729. H245MCLocationIndication(
  1730. H245_INST_T dwInst,
  1731. const H245_TRANSPORT_ADDRESS_T * pSignalAddress
  1732. );
  1733. H245DLL HRESULT
  1734. H245VendorIdentification(
  1735. H245_INST_T dwInst,
  1736. const H245_NONSTANDID_T *pIdentifier,
  1737. const unsigned char *pProductNumber, // optional
  1738. unsigned char byProductNumberLength,// optional
  1739. const unsigned char *pVersionNumber, // optional
  1740. unsigned char byVersionNumberLength // optional
  1741. );
  1742. H245DLL HRESULT
  1743. H245SendPDU (
  1744. H245_INST_T dwInst,
  1745. PDU_T * pPdu
  1746. );
  1747. H245DLL HRESULT
  1748. H245SystemControl (
  1749. H245_INST_T dwInst,
  1750. unsigned long dwRequest,
  1751. void * pData
  1752. );
  1753. #ifdef __cplusplus
  1754. }
  1755. #endif
  1756. #endif