--- deliantra/Deliantra-Client/Client.xs 2007/08/28 01:23:47 1.235 +++ deliantra/Deliantra-Client/Client.xs 2007/11/03 12:08:43 1.238 @@ -621,6 +621,8 @@ const_iv (KMOD_NUM), const_iv (KMOD_CAPS), const_iv (KMOD_MODE), + + const_iv (MIX_DEFAULT_FORMAT), # undef const_iv }; @@ -700,7 +702,7 @@ if (m && m != (SDL_Rect **)-1) while (*m) { - if ((*m)->w >= 640 && (*m)->h >= 480) + if ((*m)->w >= 800 && (*m)->h >= 600) { AV *av = newAV (); av_push (av, newSViv ((*m)->w)); @@ -734,7 +736,7 @@ { av_clear (texture_av); - SDL_WM_SetCaption ("Crossfire TRT Client " VERSION, "Crossfire TRT"); + SDL_WM_SetCaption ("Deliantra MORPG Client " VERSION, "Deliantra"); #define GL_FUNC(ptr,name) gl.name = (ptr)SDL_GL_GetProcAddress ("gl" # name); #include "glfunc.h" #undef GL_FUNC @@ -830,12 +832,28 @@ } int -Mix_OpenAudio (int frequency = 44100, int format = MIX_DEFAULT_FORMAT, int channels = 2, int chunksize = 1024) +Mix_OpenAudio (int frequency = 44100, int format = MIX_DEFAULT_FORMAT, int channels = 2, int chunksize = 4096) POSTCALL: Mix_HookMusicFinished (music_finished); Mix_ChannelFinished (channel_finished); void +Mix_QuerySpec () + PPCODE: +{ + int freq, channels; + Uint16 format; + + if (Mix_QuerySpec (&freq, &format, &channels)) + { + EXTEND (SP, 3); + PUSHs (sv_2mortal (newSViv (freq))); + PUSHs (sv_2mortal (newSViv (format))); + PUSHs (sv_2mortal (newSViv (channels))); + } +} + +void Mix_CloseAudio () int