DXTypes.pas 6.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177
  1. {******************************************************************************}
  2. {* *}
  3. {* Copyright (C) Microsoft Corporation. All Rights Reserved. *}
  4. {* *}
  5. {* Files: dxsdkver.h, extracts from various DirectX SDK include files *}
  6. {* Content: DirectX 9.0 headers common types *}
  7. {* *}
  8. {* DirectX 9.0 Delphi / FreePascal adaptation by Alexey Barkovoy *}
  9. {* E-Mail: [email protected] *}
  10. {* *}
  11. {* Latest version can be downloaded from: *}
  12. {* http://www.clootie.ru *}
  13. {* http://sourceforge.net/projects/delphi-dx9sdk *}
  14. {* *}
  15. {*----------------------------------------------------------------------------*}
  16. {* $Id: DXTypes.pas,v 1.23 2007/04/14 20:57:43 clootie Exp $ }
  17. {******************************************************************************}
  18. { }
  19. { The contents of this file are used with permission, subject to the Mozilla }
  20. { Public License Version 1.1 (the "License"); you may not use this file except }
  21. { in compliance with the License. You may obtain a copy of the License at }
  22. { http://www.mozilla.org/MPL/MPL-1.1.html }
  23. { }
  24. { Software distributed under the License is distributed on an "AS IS" basis, }
  25. { WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for }
  26. { the specific language governing rights and limitations under the License. }
  27. { }
  28. { Alternatively, the contents of this file may be used under the terms of the }
  29. { GNU Lesser General Public License (the "LGPL License"), in which case the }
  30. { provisions of the LGPL License are applicable instead of those above. }
  31. { If you wish to allow use of your version of this file only under the terms }
  32. { of the LGPL License and not to allow others to use your version of this file }
  33. { under the MPL, indicate your decision by deleting the provisions above and }
  34. { replace them with the notice and other provisions required by the LGPL }
  35. { License. If you do not delete the provisions above, a recipient may use }
  36. { your version of this file under either the MPL or the LGPL License. }
  37. { }
  38. { For more information about the LGPL: http://www.gnu.org/copyleft/lesser.html }
  39. { }
  40. {******************************************************************************}
  41. { I DirectX.inc}
  42. {$WEAKPACKAGEUNIT}
  43. {$MINENUMSIZE 4}
  44. unit DXTypes;
  45. interface
  46. (*$HPPEMIT '#include "dxsdkver.h"' *)
  47. uses Windows;
  48. (*==========================================================================;
  49. *
  50. * File: dxsdkver.h
  51. * Content: DirectX SDK Version Include File
  52. *
  53. ****************************************************************************)
  54. const
  55. _DXSDK_PRODUCT_MAJOR = 9;
  56. {$EXTERNALSYM _DXSDK_PRODUCT_MAJOR}
  57. _DXSDK_PRODUCT_MINOR = 18;
  58. {$EXTERNALSYM _DXSDK_PRODUCT_MINOR}
  59. _DXSDK_BUILD_MAJOR = 944;
  60. {$EXTERNALSYM _DXSDK_BUILD_MAJOR}
  61. _DXSDK_BUILD_MINOR = 0000;
  62. {$EXTERNALSYM _DXSDK_BUILD_MINOR}
  63. (****************************************************************************
  64. * Other files
  65. ****************************************************************************)
  66. type
  67. // TD3DValue is the fundamental Direct3D fractional data type
  68. D3DVALUE = Single;
  69. {$EXTERNALSYM D3DVALUE}
  70. TD3DValue = D3DVALUE;
  71. {$NODEFINE TD3DValue}
  72. PD3DValue = ^TD3DValue;
  73. {$NODEFINE PD3DValue}
  74. D3DCOLOR = type DWord;
  75. {$EXTERNALSYM D3DCOLOR}
  76. TD3DColor = D3DCOLOR;
  77. {$NODEFINE TD3DColor}
  78. PD3DColor = ^TD3DColor;
  79. {$NODEFINE PD3DColor}
  80. _D3DVECTOR = packed record
  81. x: Single;
  82. y: Single;
  83. z: Single;
  84. end {_D3DVECTOR};
  85. {$EXTERNALSYM _D3DVECTOR}
  86. D3DVECTOR = _D3DVECTOR;
  87. {$EXTERNALSYM D3DVECTOR}
  88. TD3DVector = _D3DVECTOR;
  89. {$NODEFINE TD3DVector}
  90. PD3DVector = ^TD3DVector;
  91. {$NODEFINE PD3DVector}
  92. REFERENCE_TIME = LONGLONG;
  93. {$EXTERNALSYM REFERENCE_TIME}
  94. TReferenceTime = REFERENCE_TIME;
  95. {$NODEFINE TReferenceTime}
  96. PReferenceTime = ^TReferenceTime;
  97. {$NODEFINE PReferenceTime}
  98. // ==================================================================
  99. // Here comes generic Windows types for Win32 / Win64 compatibility
  100. //
  101. UInt64 = Int64; // for a while
  102. //
  103. // The INT_PTR is guaranteed to be the same size as a pointer. Its
  104. // size with change with pointer size (32/64). It should be used
  105. // anywhere that a pointer is cast to an integer type. UINT_PTR is
  106. // the unsigned variation.
  107. //
  108. {$EXTERNALSYM INT_PTR}
  109. {$EXTERNALSYM UINT_PTR}
  110. {$EXTERNALSYM LONG_PTR}
  111. {$EXTERNALSYM ULONG_PTR}
  112. {$EXTERNALSYM DWORD_PTR}
  113. INT_PTR = Longint;
  114. UINT_PTR = LongWord;
  115. LONG_PTR = Longint;
  116. ULONG_PTR = LongWord;
  117. DWORD_PTR = LongWord;
  118. PINT_PTR = ^INT_PTR;
  119. PUINT_PTR = ^UINT_PTR;
  120. PLONG_PTR = ^LONG_PTR;
  121. PULONG_PTR = ^ULONG_PTR;
  122. PtrInt = Longint;
  123. PtrUInt = Longword;
  124. PPtrInt = ^PtrInt;
  125. PPtrUInt = ^PtrUInt;
  126. //
  127. // SIZE_T used for counts or ranges which need to span the range of
  128. // of a pointer. SSIZE_T is the signed variation.
  129. //
  130. {$EXTERNALSYM SIZE_T}
  131. {$EXTERNALSYM SSIZE_T}
  132. SIZE_T = ULONG_PTR;
  133. SSIZE_T = LONG_PTR;
  134. PSIZE_T = ^SIZE_T;
  135. PSSIZE_T = ^SSIZE_T;
  136. SizeInt = SSIZE_T;
  137. SizeUInt = SIZE_T;
  138. PSizeInt = PSSIZE_T;
  139. PSizeUInt = PSIZE_T;
  140. implementation
  141. end.