AkDelayLineMemoryStream.h 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  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. // Length of delay line is mapped on 4 frames boundary (i.e. may not be suited for reverberation for example)
  21. // Handling code for triple buffering processing on position independent code platforms is provided
  22. // This is not a delay line implementation, but rather just some services for memory managment related
  23. // to specific delay line execution needs as detailed by clients
  24. #include <AK/AkPlatforms.h>
  25. #ifndef _AKDSP_DELAYLINEMEMORYSTREAM_
  26. #define _AKDSP_DELAYLINEMEMORYSTREAM_
  27. #include <AK/DSP/AkDelayLineMemory.h>
  28. namespace AK
  29. {
  30. namespace DSP
  31. {
  32. template < class T_SAMPLETYPE >
  33. class CAkDelayLineMemoryStream : public CAkDelayLineMemory< T_SAMPLETYPE >
  34. {
  35. public:
  36. T_SAMPLETYPE * GetCurrentPointer( AkUInt32 in_uOffset, AkUInt32 in_uChannelIndex )
  37. {
  38. return this->m_ppDelay[in_uChannelIndex] + in_uOffset;
  39. }
  40. };
  41. } // namespace DSP
  42. } // namespace AK
  43. #endif // _AKDSP_DELAYLINEMEMORYSTREAM_