mirror of
https://github.com/TwilitRealm/dusklight
synced 2026-06-03 18:06:02 -04:00
4df8ccc871
* Reorganize files into libs/{dolphin,JSystem,PowerPC_EABI_Support,revolution,TRK_MINNOW_DOLPHIN}
* Update configure.py and project.py for new libs structure
* Refactor `#include <dolphin/x.h>` -> `<x.h>`
* Remove `__REVOLUTION_SDK__` forwards from dolphin
* Fix dolphin/ references in revolution
* Wrap `#include <dolphin.h>` in `!__REVOLUTION_SDK__`
* Always build TRK against dolphin headers
* Resolve revolution SDK header resolution issues
30 lines
598 B
C
30 lines
598 B
C
#ifndef UTILS_COMMON_CIRCLEBUFFER_H
|
|
#define UTILS_COMMON_CIRCLEBUFFER_H
|
|
|
|
#include <types.h>
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
typedef struct CircleBuffer {
|
|
u8* read_ptr;
|
|
u8* write_ptr;
|
|
u8* start_ptr;
|
|
u32 size;
|
|
s32 mBytesToRead;
|
|
u32 mBytesToWrite;
|
|
u32 mCriticalSection;
|
|
} CircleBuffer;
|
|
|
|
int CircleBufferReadBytes(CircleBuffer*, u8*, u32);
|
|
int CircleBufferWriteBytes(CircleBuffer*, u8*, u32);
|
|
void CircleBufferInitialize(CircleBuffer*, u8*, s32);
|
|
u32 CBGetBytesAvailableForRead(CircleBuffer*);
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|
|
|
|
#endif /* UTILS_COMMON_CIRCLEBUFFER_H */
|