Source code of Windows XP (NT5)
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.

144 lines
4.9 KiB

  1. /****************************************************************************
  2. *
  3. * $Archive: S:/STURGEON/SRC/INCLUDE/VCS/reg.h_v $
  4. *
  5. * INTEL Corporation Prorietary Information
  6. *
  7. * This listing is supplied under the terms of a license agreement
  8. * with INTEL Corporation and may not be copied nor disclosed except
  9. * in accordance with the terms of that agreement.
  10. *
  11. * Copyright (c) 1993-1994 Intel Corporation.
  12. *
  13. * $Revision: 1.11 $
  14. * $Date: Nov 13 1996 14:11:28 $
  15. * $Author: rdowning $
  16. *
  17. * Deliverable:
  18. *
  19. * Abstract:
  20. *
  21. * Notes:
  22. *
  23. ***************************************************************************/
  24. #ifndef __REG_HEADER__
  25. #define __REG_HEADER__
  26. #include <winreg.h>
  27. #include "h245api.h"
  28. #include "q931.h"
  29. #include "callcont.h"
  30. #include <winerror.h>
  31. #include "apierror.h"
  32. #ifdef __cplusplus
  33. extern "C" { // Assume C declarations for C++.
  34. #endif // __cplusplus
  35. extern __declspec(dllexport) long CreateRegStringValue(char *pKey,char *pSubKey,char *pValue,char *pValueData,int iRootKey);
  36. extern __declspec(dllexport) long CreateRegNumValue(char *pKey,char *pSubKey,char *pValue,DWORD dwValueData,int iRootKey);
  37. extern __declspec(dllexport) long GetRegNumValue(char *pKey,char *pSubKey,char *pValue,DWORD *pRetBuf,int iRootKey);
  38. extern __declspec(dllexport) long GetRegStringValue(char *pKey,char *pSubKey,char *pValue,BYTE *pRetBuf,DWORD *pRetBufSize,int iRootKey);
  39. extern __declspec(dllexport) long GetNumSubkeys(char *pKey,char *pSubKey,DWORD *pRetBuf,int iRootKey);
  40. extern __declspec(dllexport) long GetSubkeyString(char *pKey,char *pSubKey,DWORD iIndex,char *pRetBuf,DWORD *pRetBufSize,int iRootKey);
  41. // Capability read/write to the registry.
  42. // Read a single capability structure out of the given key and
  43. // subkey. The format of the capability is defined as follows:
  44. //
  45. //
  46. // Key/SubKey
  47. // CapabilityType = REG_SZ (G723 | LNH | H263)
  48. // The CapabilityType value is common to any capability
  49. // It defines the format of the capability structure and
  50. // the further values to read.
  51. //
  52. //
  53. // G723 audio capability fields All DWORDs
  54. //
  55. // MaxALSDUAudioFrames
  56. // SilenceSupression
  57. //
  58. // H263 video capability fields All DWORDs
  59. //
  60. // SqcifMPI
  61. // QcifMPI
  62. // CifMPI
  63. // Cif4MPI
  64. // Cif16MPI
  65. // Hrdb
  66. // Maxkb
  67. // MaxBitRate
  68. // UnrestrictedVector
  69. // ArithmeticCoding
  70. // AdvancedPrediction
  71. // Frames
  72. // TemporalSpatialTradeoff
  73. //
  74. // L&H audio capability fields All DWORDs
  75. // Stored into a nonStandardCapability structure
  76. //
  77. // FormatTag
  78. // DataRate
  79. // FrameSize
  80. // FramesPerPkt
  81. // UseSilenceDet
  82. // UsePostFilter
  83. //
  84. //
  85. extern __declspec(dllexport) HRESULT GetRegCapability(char *pKey, char *pSubKey, CC_TERMCAP *CapEntry, int iRootKey);
  86. extern __declspec(dllexport) HRESULT CreateRegCapability(char *pKey, char *pSubKey, CC_TERMCAP *CapEntry, int iRootKey);
  87. // Check for compatibility between two capabilities
  88. extern __declspec(dllexport) BOOLEAN IsCapInteroperable(CC_TERMCAP *CapEntry1, CC_TERMCAP *CapEntry2);
  89. extern __declspec(dllexport) HRESULT IsVideoCapInteroperable(CC_TERMCAP *CapEntry1, CC_TERMCAP *CapEntry2, CC_TERMCAP *CapEntry0);
  90. // Read an entire capability list from the registry.
  91. // GetRegCapTable - Allocate and read a capability table from
  92. // the registry.
  93. // A Capability table is stored in the registry as follows
  94. // Key/SubKey/CapTable
  95. // NumEntries REG_DWORD
  96. // Entry0 REG_SZ
  97. // Entry1 REG_SZ
  98. // ...
  99. // Each entry is numbered and will be returned in the corresponding
  100. // position in the array. This allows the capability table to
  101. // define an order of the entries.
  102. // Each entry is a string which corresponds to the name of a key
  103. // in the
  104. // HKEY_LOCAL_MACHINE\SOFTWARE\Intel\RMS\CodecCapabilities
  105. // area. From this new key, the system can get all of the
  106. // fields of the indicated capability.
  107. //
  108. // The return values are:
  109. // RetCapEntryTable, Value is an allocated pointer to the array of
  110. // capability structures. The caller is responsible
  111. // to free this memory when they are finished with it.
  112. // RetCapEntryTableSize Size of the allocated array in number of cap entries
  113. //
  114. extern __declspec(dllexport) HRESULT GetRegCapTable(char *pProdKey, char* pCapKey, char *pSubKey, CC_TERMCAP **RetCapEntryTable, int *RetCapEntryTableSize, int iRootKey);
  115. // Return codes for the registry capability functions
  116. #define CR_OK ((HRESULT)MAKE_HRESULT(SEVERITY_SUCCESS, FACILITY_CAPREG, ERROR_SUCCESS))
  117. #define CR_KEYINVALID ((HRESULT)MAKE_HRESULT(SEVERITY_ERROR, FACILITY_CAPREG, ERROR_BADKEY))
  118. #define CR_OUTOFMEM ((HRESULT)MAKE_HRESULT(SEVERITY_ERROR, FACILITY_CAPREG, ERROR_OUTOFMEMORY))
  119. #define CR_UNKNOWNCAP ((HRESULT)MAKE_HRESULT(SEVERITY_ERROR, FACILITY_CAPREG, ERROR_NOT_SUPPORTED))
  120. #ifdef __cplusplus
  121. } // End of extern "C" {
  122. #endif // __cplusplus
  123. #define GetRegStringSize(pKey,pSubKey,pValue,pSize,iRootKey) GetRegStringValue(pKey,pSubKey,pValue,NULL,pSize,iRootKey)
  124. #define CURRENT_USER 0
  125. #define LOCAL_MACHINE 1
  126. #define CLASSES_ROOT 2
  127. #define USERS 3
  128. #endif