| AAX SDK 2.8.0 Avid Audio Extensions Development Kit

- Welcome
- Manual
- Classes
- Files
- Lists
- Support

- File List
- File Members

Loading...
Searching...
No Matches
AAX_IDma.h
Go to the documentation of this file.
1/*================================================================================================*/
2/*
3 *
4 * Copyright 2014-2015, 2023-2024 Avid Technology, Inc.
5 * All rights reserved.
6 *
7 * This file is part of the Avid AAX SDK.
8 *
9 * The AAX SDK is subject to commercial or open-source licensing.
10 *
11 * By using the AAX SDK, you agree to the terms of both the Avid AAX SDK License
12 * Agreement and Avid Privacy Policy.
13 *
14 * AAX SDK License: https://developer.avid.com/aax
15 * Privacy Policy: https://www.avid.com/legal/privacy-policy-statement
16 *
17 * Or: You may also use this code under the terms of the GPL v3 (see
18 * www.gnu.org/licenses).
19 *
20 * THE AAX SDK IS PROVIDED "AS IS" WITHOUT ANY WARRANTY, AND ALL WARRANTIES, WHETHER
21 * EXPRESSED OR IMPLIED, INCLUDING MERCHANTABILITY AND FITNESS FOR PURPOSE, ARE
22 * DISCLAIMED.
23 *
24 */
25
32/*================================================================================================*/
33
34
35#pragma once
36
37#ifndef AAX_IDMA_H
38#define AAX_IDMA_H
39
40#include "AAX.h"
41
42
43#ifndef AAX_DMA_API
44# ifdef _MSC_VER
45# define AAX_DMA_API __cdecl
46# else
47# define AAX_DMA_API
48# endif
49#endif // AAX_DMA_API
50
62 class AAX_IDma
63{
64 public:
65 enum EState
66 {
67 eState_Error = -1,
68 eState_Init = 0,
69 eState_Running = 1,
70 eState_Complete = 2,
71 eState_Pending = 3
72 };
73
74 // WARNING! These need to be kept in sync with the TI dMAX microcode EventType IDs!
80 enum EMode
81 {
82 eMode_Error = -1,
83
84 eMode_Burst = 6,
85 eMode_Gather = 10,
86 eMode_Scatter = 11,
87
88 };
89
90
91 public:
92 virtual ~AAX_IDma() {}
93
95
110 virtual AAX_Result AAX_DMA_API PostRequest() = 0;
125 virtual int32_t AAX_DMA_API IsTransferComplete() = 0;
132 virtual AAX_Result AAX_DMA_API SetDmaState( EState iState ) = 0;
135 virtual EState AAX_DMA_API GetDmaState() const = 0;
140 virtual EMode AAX_DMA_API GetDmaMode() const = 0;
142
143
145
158 virtual AAX_Result AAX_DMA_API SetSrc( int8_t * iSrc ) = 0;
161 virtual int8_t * AAX_DMA_API GetSrc() = 0;
170 virtual AAX_Result AAX_DMA_API SetDst( int8_t * iDst ) = 0;
173 virtual int8_t * AAX_DMA_API GetDst() = 0;
174
182 virtual AAX_Result AAX_DMA_API SetBurstLength( int32_t iBurstLengthBytes ) = 0;
185 virtual int32_t AAX_DMA_API GetBurstLength() = 0;
198 virtual AAX_Result AAX_DMA_API SetNumBursts( int32_t iNumBursts ) = 0;
201 virtual int32_t AAX_DMA_API GetNumBursts() = 0;
209 virtual AAX_Result AAX_DMA_API SetTransferSize( int32_t iTransferSizeBytes ) = 0;
212 virtual int32_t AAX_DMA_API GetTransferSize() = 0;
214
215
217
227 virtual AAX_Result AAX_DMA_API SetFifoBuffer( int8_t * iFifoBase ) = 0;
230 virtual int8_t * AAX_DMA_API GetFifoBuffer() = 0;
235 virtual AAX_Result AAX_DMA_API SetLinearBuffer( int8_t * iLinearBase ) = 0;
238 virtual int8_t * AAX_DMA_API GetLinearBuffer() = 0;
251 virtual AAX_Result AAX_DMA_API SetOffsetTable( const int32_t * iOffsetTable ) = 0;
254 virtual const int32_t * AAX_DMA_API GetOffsetTable() = 0;
261 virtual AAX_Result AAX_DMA_API SetNumOffsets( int32_t iNumOffsets ) = 0;
264 virtual int32_t AAX_DMA_API GetNumOffsets() = 0;
274 virtual AAX_Result AAX_DMA_API SetBaseOffset( int32_t iBaseOffsetBytes ) = 0;
277 virtual int32_t AAX_DMA_API GetBaseOffset() = 0;
285 virtual AAX_Result AAX_DMA_API SetFifoSize( int32_t iSizeBytes ) = 0;
288 virtual int32_t AAX_DMA_API GetFifoSize() = 0;
290};
291
292
293
294#endif // AAX_IDMA_H
AAX.h
Various utility definitions for AAX.
AAX_Result
int32_t AAX_Result
Definition: AAX.h:347
AAX_DMA_API
#define AAX_DMA_API
Definition: AAX_IDma.h:47
AAX_IDma
Cross-platform interface for access to the host's direct memory access (DMA) facilities.
Definition: AAX_IDma.h:63
AAX_IDma::SetNumBursts
virtual AAX_Result AAX_DMA_API SetNumBursts(int32_t iNumBursts)=0
Sets the number of bursts to perform before giving up priority to other DMA transfers.
AAX_IDma::GetBaseOffset
virtual int32_t AAX_DMA_API GetBaseOffset()=0
Gets the relative base offset into the FIFO where transfers will begin.
AAX_IDma::GetLinearBuffer
virtual int8_t *AAX_DMA_API GetLinearBuffer()=0
Gets the address of the linear buffer for the DMA transfer.
AAX_IDma::GetTransferSize
virtual int32_t AAX_DMA_API GetTransferSize()=0
Gets the size of the whole transfer, in Bytes.
AAX_IDma::GetSrc
virtual int8_t *AAX_DMA_API GetSrc()=0
Gets the address of the source buffer.
AAX_IDma::IsTransferComplete
virtual int32_t AAX_DMA_API IsTransferComplete()=0
Query whether a transfer has completed.
AAX_IDma::SetDmaState
virtual AAX_Result AAX_DMA_API SetDmaState(EState iState)=0
Sets the DMA State.
AAX_IDma::SetTransferSize
virtual AAX_Result AAX_DMA_API SetTransferSize(int32_t iTransferSizeBytes)=0
Sets the size of the whole transfer.
AAX_IDma::GetNumOffsets
virtual int32_t AAX_DMA_API GetNumOffsets()=0
Gets the number of offets in the offset table.
AAX_IDma::SetNumOffsets
virtual AAX_Result AAX_DMA_API SetNumOffsets(int32_t iNumOffsets)=0
Sets the number of offets in the offset table.
AAX_IDma::EState
EState
Definition: AAX_IDma.h:66
AAX_IDma::eState_Complete
@ eState_Complete
Definition: AAX_IDma.h:70
AAX_IDma::eState_Init
@ eState_Init
Definition: AAX_IDma.h:68
AAX_IDma::eState_Error
@ eState_Error
Definition: AAX_IDma.h:67
AAX_IDma::eState_Running
@ eState_Running
Definition: AAX_IDma.h:69
AAX_IDma::eState_Pending
@ eState_Pending
Definition: AAX_IDma.h:71
AAX_IDma::~AAX_IDma
virtual ~AAX_IDma()
Definition: AAX_IDma.h:92
AAX_IDma::SetDst
virtual AAX_Result AAX_DMA_API SetDst(int8_t *iDst)=0
Sets the address of the destination buffer.
AAX_IDma::SetSrc
virtual AAX_Result AAX_DMA_API SetSrc(int8_t *iSrc)=0
Sets the address of the source buffer.
AAX_IDma::GetFifoBuffer
virtual int8_t *AAX_DMA_API GetFifoBuffer()=0
Gets the address of the FIFO buffer for the DMA transfer.
AAX_IDma::SetFifoSize
virtual AAX_Result AAX_DMA_API SetFifoSize(int32_t iSizeBytes)=0
Sets the size of the FIFO buffer, in bytes.
AAX_IDma::SetOffsetTable
virtual AAX_Result AAX_DMA_API SetOffsetTable(const int32_t *iOffsetTable)=0
Sets the offset table for the DMA transfer.
AAX_IDma::GetDmaMode
virtual EMode AAX_DMA_API GetDmaMode() const =0
Inquire to find the mode of the DMA instance.
AAX_IDma::GetOffsetTable
virtual const int32_t *AAX_DMA_API GetOffsetTable()=0
Gets the offset table for the DMA transfer.
AAX_IDma::GetDst
virtual int8_t *AAX_DMA_API GetDst()=0
Gets the address of the destination buffer.
AAX_IDma::GetFifoSize
virtual int32_t AAX_DMA_API GetFifoSize()=0
Gets the size of the FIFO buffer, in bytes.
AAX_IDma::GetDmaState
virtual EState AAX_DMA_API GetDmaState() const =0
Inquire to find the state of the DMA instance.
AAX_IDma::SetBaseOffset
virtual AAX_Result AAX_DMA_API SetBaseOffset(int32_t iBaseOffsetBytes)=0
Sets the relative base offset into the FIFO where transfers will begin.
AAX_IDma::GetBurstLength
virtual int32_t AAX_DMA_API GetBurstLength()=0
Gets the length of each burst.
AAX_IDma::PostRequest
virtual AAX_Result AAX_DMA_API PostRequest()=0
Posts the transfer request to the DMA server.
AAX_IDma::SetBurstLength
virtual AAX_Result AAX_DMA_API SetBurstLength(int32_t iBurstLengthBytes)=0
Sets the length of each burst.
AAX_IDma::SetLinearBuffer
virtual AAX_Result AAX_DMA_API SetLinearBuffer(int8_t *iLinearBase)=0
Sets the address of the linear buffer for the DMA transfer (usually the internal memory block)
AAX_IDma::GetNumBursts
virtual int32_t AAX_DMA_API GetNumBursts()=0
Gets the number of bursts to perform before giving up priority to other DMA transfers.
AAX_IDma::EMode
EMode
DMA mode IDs.
Definition: AAX_IDma.h:81
AAX_IDma::eMode_Burst
@ eMode_Burst
Burst mode (uncommon)
Definition: AAX_IDma.h:84
AAX_IDma::eMode_Error
@ eMode_Error
Definition: AAX_IDma.h:82
AAX_IDma::eMode_Scatter
@ eMode_Scatter
Scatter mode.
Definition: AAX_IDma.h:86
AAX_IDma::eMode_Gather
@ eMode_Gather
Gather mode.
Definition: AAX_IDma.h:85
AAX_IDma::SetFifoBuffer
virtual AAX_Result AAX_DMA_API SetFifoBuffer(int8_t *iFifoBase)=0
Sets the address of the FIFO buffer for the DMA transfer (usually the external memory block)