PS2SDK
PS2 Homebrew Libraries
Loading...
Searching...
No Matches
ssinit.c
1/*
2# _____ ___ ____ ___ ____
3# ____| | ____| | | |____|
4# | ___| |____ ___| ____| | \ PS2DEV Open Source Project.
5#-----------------------------------------------------------------------
6# Copyright ps2dev - http://www.ps2dev.org
7# Licenced under Academic Free License version 2.0
8# Review ps2sdk README & LICENSE files for further details.
9*/
10
11#include "libsnd2_internal.h"
12
13unsigned int _snd_vmask = 0u;
14static s16 volume_dat_2[16] = {16383, 16383, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0};
15
16libsnd2_sequence_marker_t _SsMarkCallback[32];
17int VBLANK_MINUS;
18unsigned int _snd_openflag;
19int _snd_ev_flag;
20_SsFCALL SsFCALL;
21libsnd2_sequence_struct_t *_ss_score[32];
22s16 _snd_seq_s_max;
23s16 _snd_seq_t_max;
24
25void _SsInit(void)
26{
27 s16 *reg_set_ptr;
28 int i;
29 int j;
30
31 reg_set_ptr = (s16 *)0xBF900760;
32 for ( i = 0; i < 16; i += 1 )
33 {
34 reg_set_ptr[i] = volume_dat_2[i];
35 }
36 _SsVmInit(24);
37 for ( j = 0; j < 32; j += 1 )
38 {
39 for ( i = 0; i < 16; i += 1 )
40 {
41 _SsMarkCallback[j].m_entries[i] = 0;
42 }
43 }
44 VBLANK_MINUS = 60;
45 _snd_openflag = 0;
46 _snd_ev_flag = 0;
47}