ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/Deliantra-Client/Client.xs
(Generate patch)

Comparing deliantra/Deliantra-Client/Client.xs (file contents):
Revision 1.71 by root, Fri May 5 19:05:47 2006 UTC vs.
Revision 1.74 by root, Sat May 6 20:14:57 2006 UTC

277{ 277{
278 SDL_UserEvent ev; 278 SDL_UserEvent ev;
279 279
280 ev.type = SDL_USEREVENT; 280 ev.type = SDL_USEREVENT;
281 ev.code = 1; 281 ev.code = 1;
282 ev.data1 = channel; 282 ev.data1 = (void *)(long)channel;
283 ev.data2 = 0; 283 ev.data2 = 0;
284 284
285 SDL_PushEvent ((SDL_Event *)&ev); 285 SDL_PushEvent ((SDL_Event *)&ev);
286} 286}
287 287
501 hv_store (hv, "button", 6, newSViv (ev.button.button), 0); 501 hv_store (hv, "button", 6, newSViv (ev.button.button), 0);
502 hv_store (hv, "state", 5, newSViv (ev.button.state), 0); 502 hv_store (hv, "state", 5, newSViv (ev.button.state), 0);
503 hv_store (hv, "x", 1, newSViv (ev.button.x), 0); 503 hv_store (hv, "x", 1, newSViv (ev.button.x), 0);
504 hv_store (hv, "y", 1, newSViv (ev.button.y), 0); 504 hv_store (hv, "y", 1, newSViv (ev.button.y), 0);
505 break; 505 break;
506
507 case SDL_USEREVENT:
508 hv_store (hv, "code", 4, newSViv (ev.user.code), 0);
509 hv_store (hv, "data1", 5, newSViv ((IV)ev.user.data1), 0);
510 hv_store (hv, "data2", 5, newSViv ((IV)ev.user.data2), 0);
511 break;
506 } 512 }
507 513
508 XPUSHs (sv_2mortal (newRV_noinc ((SV *)hv))); 514 XPUSHs (sv_2mortal (newRV_noinc ((SV *)hv)));
509 } 515 }
510} 516}
511 517
512int 518int
513Mix_OpenAudio (int frequency = 22050, int format = MIX_DEFAULT_FORMAT, int channels = 1, int chunksize = 512) 519Mix_OpenAudio (int frequency = 48000, int format = MIX_DEFAULT_FORMAT, int channels = 1, int chunksize = 2048)
514 POSTCALL: 520 POSTCALL:
515 Mix_HookMusicFinished (music_finished); 521 Mix_HookMusicFinished (music_finished);
516 Mix_ChannelFinished (channel_finished); 522 Mix_ChannelFinished (channel_finished);
517 523
518void 524void

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines