[Scummvm-cvs-logs] CVS: scummvm/backends/x11 x11.cpp,1.22,1.23
Max Horn
fingolfin at users.sourceforge.net
Tue Feb 24 14:56:02 CET 2004
- Previous message: [Scummvm-cvs-logs] CVS: scummvm/backends/dc audio.cpp,1.10,1.11 dc.h,1.18,1.19 display.cpp,1.15,1.16
- Next message: [Scummvm-cvs-logs] CVS: scummvm/backends/sdl sdl-common.cpp,1.106,1.107 sdl-common.h,1.46,1.47 sdl.cpp,1.57,1.58
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Update of /cvsroot/scummvm/scummvm/backends/x11
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12241/backends/x11
Modified Files:
x11.cpp
Log Message:
the OSystem changes we discussed on the ML (note: renaming of the existing OSystem API is not yet finished); porters will have to fix their ports to get them to compile again
Index: x11.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/backends/x11/x11.cpp,v
retrieving revision 1.22
retrieving revision 1.23
diff -u -d -r1.22 -r1.23
--- x11.cpp 13 Feb 2004 00:44:30 -0000 1.22
+++ x11.cpp 24 Feb 2004 22:39:37 -0000 1.23
@@ -60,7 +60,7 @@
// Set the size of the video bitmap.
// Typically, 320x200
- void init_size(uint w, uint h);
+ void initSize(uint w, uint h);
// Draw a bitmap to screen.
// The screen will not be updated to reflect the new bitmap
@@ -99,9 +99,9 @@
bool poll_event(Event *event);
// Set function that generates samples
- bool set_sound_proc(SoundProc proc, void *param, SoundFormat format);
+ bool setSoundCallback(SoundProc proc, void *param);
- void clear_sound_proc();
+ void clearSoundCallback();
// Poll cdrom status
// Returns true if cd audio is playing
@@ -203,7 +203,6 @@
typedef struct {
OSystem::SoundProc sound_proc;
void *param;
- byte format;
} THREAD_PARAM;
#undef CAPTURE_SOUND
@@ -417,7 +416,7 @@
((current_time.tv_usec - start_time.tv_usec) / 1000));
}
-void OSystem_X11::init_size(uint w, uint h)
+void OSystem_X11::initSize(uint w, uint h)
{
static XShmSegmentInfo shminfo;
@@ -456,24 +455,20 @@
palette = (uint16 *)calloc(256, sizeof(uint16));
}
-bool OSystem_X11::set_sound_proc(SoundProc proc, void *param, SoundFormat format)
+bool OSystem_X11::setSoundCallback(SoundProc proc, void *param)
{
static THREAD_PARAM thread_param;
/* And finally start the music thread */
thread_param.param = param;
thread_param.sound_proc = proc;
- thread_param.format = format;
- if (format == SOUND_16BIT)
- pthread_create(&sound_thread, NULL, sound_and_music_thread, (void *)&thread_param);
- else
- warning("Only support 16 bit sound for now. Disabling sound ");
+ pthread_create(&sound_thread, NULL, sound_and_music_thread, (void *)&thread_param);
return true;
}
-void OSystem_X11::clear_sound_proc() {
+void OSystem_X11::clearSoundCallback() {
// TODO implement this...
// The sound_thread has to be stopped in a nice way. In particular,
// using pthread_kill would be a bad idea. Rather, use pthread_cancel,
- Previous message: [Scummvm-cvs-logs] CVS: scummvm/backends/dc audio.cpp,1.10,1.11 dc.h,1.18,1.19 display.cpp,1.15,1.16
- Next message: [Scummvm-cvs-logs] CVS: scummvm/backends/sdl sdl-common.cpp,1.106,1.107 sdl-common.h,1.46,1.47 sdl.cpp,1.57,1.58
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the Scummvm-git-logs
mailing list