Add a free FEC block cache to avoid memory allocations
This commit is contained in:
parent
fb9aab0e57
commit
f01103af23
2 changed files with 64 additions and 3 deletions
|
|
@ -12,6 +12,9 @@
|
|||
#define RTPA_FEC_SHARDS 2
|
||||
#define RTPA_TOTAL_SHARDS (RTPA_DATA_SHARDS + RTPA_FEC_SHARDS)
|
||||
|
||||
// Maximum number of FEC block entries to cache
|
||||
#define RTPA_CACHED_FEC_BLOCK_LIMIT 4
|
||||
|
||||
typedef struct _AUDIO_FEC_HEADER {
|
||||
uint8_t fecShardIndex;
|
||||
uint8_t payloadType;
|
||||
|
|
@ -50,6 +53,9 @@ typedef struct _RTP_AUDIO_QUEUE {
|
|||
|
||||
reed_solomon* rs;
|
||||
|
||||
PRTPA_FEC_BLOCK freeBlockHead;
|
||||
uint16_t freeBlockCount;
|
||||
|
||||
uint16_t nextRtpSequenceNumber;
|
||||
uint16_t oldestRtpBaseSequenceNumber;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue