AkSoundEngineExport.h 3.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889
  1. /*******************************************************************************
  2. The content of this file includes portions of the AUDIOKINETIC Wwise Technology
  3. released in source code form as part of the SDK installer package.
  4. Commercial License Usage
  5. Licensees holding valid commercial licenses to the AUDIOKINETIC Wwise Technology
  6. may use this file in accordance with the end user license agreement provided
  7. with the software or, alternatively, in accordance with the terms contained in a
  8. written agreement between you and Audiokinetic Inc.
  9. Apache License Usage
  10. Alternatively, this file may be used under the Apache License, Version 2.0 (the
  11. "Apache License"); you may not use this file except in compliance with the
  12. Apache License. You may obtain a copy of the Apache License at
  13. http://www.apache.org/licenses/LICENSE-2.0.
  14. Unless required by applicable law or agreed to in writing, software distributed
  15. under the Apache License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES
  16. OR CONDITIONS OF ANY KIND, either express or implied. See the Apache License for
  17. the specific language governing permissions and limitations under the License.
  18. Copyright (c) 2023 Audiokinetic Inc.
  19. *******************************************************************************/
  20. // AkSoundEngineExport.h
  21. /// \file
  22. /// Export/calling convention definitions.
  23. #ifndef _AK_SOUNDENGINE_EXPORT_H_
  24. #define _AK_SOUNDENGINE_EXPORT_H_
  25. #include <AK/AkPlatforms.h>
  26. #ifndef AK_DLLEXPORT
  27. #define AK_DLLEXPORT
  28. #endif
  29. #ifndef AK_DLLIMPORT
  30. #define AK_DLLIMPORT
  31. #endif
  32. #ifndef AK_ATTR_USED
  33. #define AK_ATTR_USED
  34. #endif
  35. #ifdef AKSOUNDENGINE_DLL
  36. #ifdef AKSOUNDENGINE_EXPORTS
  37. /// Sound Engine API import/export definition
  38. #define AKSOUNDENGINE_API AK_DLLEXPORT
  39. #else
  40. /// Sound Engine API import/export definition
  41. #define AKSOUNDENGINE_API AK_DLLIMPORT
  42. #endif // Export
  43. #else
  44. #define AKSOUNDENGINE_API
  45. #endif
  46. #ifndef AKSOUNDENGINE_CALL
  47. #define AKSOUNDENGINE_CALL
  48. #endif
  49. /// Declare a function
  50. /// \param _type Return type of the function
  51. /// \param _name Name of the function
  52. /// \remarks This must be followed by the parentheses containing the function arguments declaration
  53. #define AK_FUNC( _type, _name ) _type AKSOUNDENGINE_CALL _name
  54. /// Declare an extern function
  55. /// \param _type Return type of the function
  56. /// \param _name Name of the function
  57. /// \remarks This must be followed by the parentheses containing the function arguments declaration
  58. #define AK_EXTERNFUNC( _type, _name ) extern _type AKSOUNDENGINE_CALL _name
  59. /// Declare an extern function that is exported/imported
  60. /// \param _type Return type of the function
  61. /// \param _name Name of the function
  62. /// \remarks This must be followed by the parentheses containing the function arguments declaration
  63. #define AK_EXTERNAPIFUNC( _type, _name ) extern AKSOUNDENGINE_API _type AKSOUNDENGINE_CALL _name
  64. /// Declare a callback function type
  65. /// \param _type Return type of the function
  66. /// \param _name Name of the function
  67. /// \remarks This must be followed by the parentheses containing the function arguments declaration
  68. #define AK_CALLBACK( _type, _name ) typedef _type ( AKSOUNDENGINE_CALL *_name )
  69. #endif //_AK_SOUNDENGINE_EXPORT_H_