ps2sdk
1.1
A collection of Open Source libraries used for developing applications on Sony's PlayStation 2® (PS2).
|
#include <string.h>
#include <kernel.h>
#include <sifrpc.h>
#include <iopheap.h>
#include <stdio.h>
#include <ps2snd.h>
Go to the source code of this file.
Functions | |
int | sceSdInit (int flag) |
void | sceSdSetParam (u16 entry, u16 value) |
u16 | sceSdGetParam (u16 entry) |
void | sceSdSetSwitch (u16 entry, u32 value) |
u32 | sceSdGetSwitch (u16 entry) |
void | sceSdSetAddr (u16 entry, u32 value) |
u32 | sceSdGetAddr (u16 entry) |
void | sceSdSetCoreAttr (u16 entry, u16 value) |
u16 | sceSdGetCoreAttr (u16 entry) |
u16 | sceSdNote2Pitch (u16 center_note, u16 center_fine, u16 note, s16 fine) |
u16 | sceSdPitch2Note (u16 center_note, u16 center_fine, u16 pitch) |
int | sceSdProcBatch (sceSdBatch *batch, u32 returns[], u32 num) |
int | sceSdProcBatchEx (sceSdBatch *batch, u32 returns[], u32 num, u32 voice) |
int | sceSdVoiceTrans (s16 channel, u16 mode, u8 *m_addr, u32 *s_addr, u32 size) |
int | sceSdBlockTrans (s16 channel, u16 mode, u8 *m_addr, u32 size,...) |
u32 | sceSdVoiceTransStatus (s16 channel, s16 flag) |
u32 | sceSdBlockTransStatus (s16 channel, s16 flag) |
int | sceSdSetEffectAttr (int core, sceSdEffectAttr *attr) |
void | sceSdGetEffectAttr (int core, sceSdEffectAttr *attr) |
int | sceSdClearEffectWorkArea (int core, int channel, int effect_mode) |
u32 | sndQueryMaxFreeMemSize (void) |
int | sndStreamOpen (char *file, u32 voices, u32 flags, u32 bufaddr, u32 bufsize) |
int | sndStreamClose (void) |
int | sndStreamPlay (void) |
int | sndStreamPause (void) |
int | sndStreamSetPosition (int block) |
int | sndStreamSetVolume (int left, int right) |
int | sndStreamGetPosition (void) |
int | sndLoadSample (void *buf, u32 spuaddr, int size) |
Variables | |
static SifRpcClientData_t | sd_client |
static int | sd_started = 0 |
Definition at line 167 of file ps2snd.c.
References ALIGNED, NULL, PS2SND_BlockTransStatus, sd_client, and SifCallRpc().
int sceSdClearEffectWorkArea | ( | int | core, |
int | channel, | ||
int | effect_mode | ||
) |
Definition at line 197 of file ps2snd.c.
References ALIGNED, NULL, PS2SND_ClearEffectWorkArea, sd_client, and SifCallRpc().
Definition at line 90 of file ps2snd.c.
References ALIGNED, NULL, PS2SND_GetAddr, sd_client, and SifCallRpc().
Definition at line 106 of file ps2snd.c.
References ALIGNED, NULL, PS2SND_GetCoreAttr, sd_client, and SifCallRpc().
void sceSdGetEffectAttr | ( | int | core, |
sceSdEffectAttr * | attr | ||
) |
Definition at line 189 of file ps2snd.c.
References ALIGNED, NULL, PS2SND_GetEffectAttr, sd_client, and SifCallRpc().
Definition at line 58 of file ps2snd.c.
References ALIGNED, NULL, PS2SND_GetParam, sd_client, and SifCallRpc().
Definition at line 74 of file ps2snd.c.
References ALIGNED, NULL, PS2SND_GetSwitch, sd_client, and SifCallRpc().
int sceSdInit | ( | int | flag | ) |
Definition at line 21 of file ps2snd.c.
References ALIGNED, BINDID_PS2SND, nopdelay(), NULL, PS2SND_Init, sd_client, sd_started, SifRpcClientData_t::server, SifBindRpc(), and SifCallRpc().
Referenced by main().
int sceSdProcBatch | ( | sceSdBatch * | batch, |
u32 | returns[], | ||
u32 | num | ||
) |
int sceSdProcBatchEx | ( | sceSdBatch * | batch, |
u32 | returns[], | ||
u32 | num, | ||
u32 | voice | ||
) |
Definition at line 82 of file ps2snd.c.
References ALIGNED, NULL, PS2SND_SetAddr, sd_client, and SifCallRpc().
Definition at line 98 of file ps2snd.c.
References ALIGNED, NULL, PS2SND_SetCoreAttr, sd_client, and SifCallRpc().
int sceSdSetEffectAttr | ( | int | core, |
sceSdEffectAttr * | attr | ||
) |
Definition at line 180 of file ps2snd.c.
References ALIGNED, NULL, PS2SND_SetEffectAttr, sd_client, and SifCallRpc().
Definition at line 50 of file ps2snd.c.
References ALIGNED, NULL, PS2SND_SetParam, sd_client, and SifCallRpc().
Referenced by main().
Definition at line 66 of file ps2snd.c.
References ALIGNED, NULL, PS2SND_SetSwitch, sd_client, and SifCallRpc().
Definition at line 139 of file ps2snd.c.
References ALIGNED, mode, NULL, PS2SND_VoiceTrans, sd_client, and SifCallRpc().
Referenced by sndLoadSample().
Definition at line 157 of file ps2snd.c.
References ALIGNED, NULL, PS2SND_VoiceTransStatus, sd_client, and SifCallRpc().
Referenced by sndLoadSample().
int sndLoadSample | ( | void * | buf, |
u32 | spuaddr, | ||
int | size | ||
) |
Definition at line 276 of file ps2snd.c.
References SifDmaTransfer_t::attr, SifDmaTransfer_t::dest, FlushCache(), sceSdVoiceTrans(), sceSdVoiceTransStatus(), SD_TRANS_WRITE, SifAllocIopHeap(), SifDmaStat(), SifFreeIopHeap(), SifSetDma(), SifDmaTransfer_t::size, sndQueryMaxFreeMemSize(), and SifDmaTransfer_t::src.
u32 sndQueryMaxFreeMemSize | ( | void | ) |
Definition at line 208 of file ps2snd.c.
References ALIGNED, NULL, PS2SND_QueryMaxFreeMemSize, sd_client, and SifCallRpc().
Referenced by sndLoadSample().
int sndStreamClose | ( | void | ) |
Definition at line 230 of file ps2snd.c.
References ALIGNED, NULL, PS2SND_StreamClose, sd_client, and SifCallRpc().
int sndStreamGetPosition | ( | void | ) |
Definition at line 269 of file ps2snd.c.
References ALIGNED, NULL, PS2SND_StreamGetPosition, sd_client, and SifCallRpc().
Definition at line 215 of file ps2snd.c.
References ALIGNED, NULL, PS2SND_StreamOpen, sd_client, and SifCallRpc().
Referenced by main().
int sndStreamPause | ( | void | ) |
Definition at line 245 of file ps2snd.c.
References ALIGNED, NULL, PS2SND_StreamPause, sd_client, and SifCallRpc().
int sndStreamPlay | ( | void | ) |
Definition at line 237 of file ps2snd.c.
References ALIGNED, NULL, PS2SND_StreamPlay, sd_client, and SifCallRpc().
Referenced by main().
int sndStreamSetPosition | ( | int | block | ) |
Definition at line 252 of file ps2snd.c.
References ALIGNED, NULL, PS2SND_StreamSetPosition, sd_client, and SifCallRpc().
int sndStreamSetVolume | ( | int | left, |
int | right | ||
) |
Definition at line 260 of file ps2snd.c.
References ALIGNED, NULL, PS2SND_StreamSetVolume, sd_client, and SifCallRpc().
|
static |
Definition at line 18 of file ps2snd.c.
Referenced by sceSdBlockTransStatus(), sceSdClearEffectWorkArea(), sceSdGetAddr(), sceSdGetCoreAttr(), sceSdGetEffectAttr(), sceSdGetParam(), sceSdGetSwitch(), sceSdInit(), sceSdSetAddr(), sceSdSetCoreAttr(), sceSdSetEffectAttr(), sceSdSetParam(), sceSdSetSwitch(), sceSdVoiceTrans(), sceSdVoiceTransStatus(), sndQueryMaxFreeMemSize(), sndStreamClose(), sndStreamGetPosition(), sndStreamOpen(), sndStreamPause(), sndStreamPlay(), sndStreamSetPosition(), and sndStreamSetVolume().
|
static |
Definition at line 19 of file ps2snd.c.
Referenced by sceSdInit().