Previous 15994 Revisions Next

r1806 Friday 29th February, 2008 at 03:55:06 UTC by R. Belmont
[SDLMESS] Updated for 0.123u3.
[ROOT]makefile.sdl
[src/osd/sdl]input.c input.h os2work.c sound.c video.c

src/osd/sdl/video.c
r1805r1806
341341//  osd_update
342342//============================================================
343343
344void osd_update(int skip_redraw)
344void osd_update(running_machine *machine, int skip_redraw)
345345{
346346   sdl_window_info *window;
347347
r1805r1806
355355   }
356356
357357   // poll the joystick values here
358   sdlinput_poll();
358   sdlinput_poll(machine);
359359   check_osd_inputs();
360360
361361#ifdef ENABLE_DEBUGGER
src/osd/sdl/os2work.c
r1805r1806
178178
179179
180180INLINE INT32 scalable_lock_acquire(scalable_lock *lock)
181
181{
182182    INT32 myslot = (atomic_increment32(&lock->nextindex) - 1) & (WORK_MAX_THREADS - 1);
183183
184184#if defined(__i386__) || defined(__x86_64__)
r1805r1806
511511//  osd_Twork_item_queue_multiple
512512//============================================================
513513
514osd_work_item *osd_work_item_queue_multiple(osd_work_queue *queue, osd_work_callback callback, INT32 numitems, void
515parambase, INT32 paramstep, UINT32 flags)
514osd_work_item *osd_work_item_queue_multiple(osd_work_queue *queue, osd_work_callback callback, INT32 numitems, void *parambase, INT32 paramstep, UINT32 flags)
516515{
517516    osd_work_item *itemlist = NULL;
518517    osd_work_item **item_tailptr = &itemlist;
r1805r1806
750749//  worker_thread_process
751750//============================================================
752751
753static int execute_work_item(osd_work_item *item)
752static void worker_thread_process(osd_work_queue *queue, work_thread_info *thread)
754753{
755754   int threadid = thread - queue->thread;
756755
src/osd/sdl/sound.c
r1805r1806
2525#include "window.h"
2626#include "video.h"
2727#include "osdsdl.h"
28#include "deprecat.h"
2928
3029//============================================================
3130//   DEBUGGING
r1805r1806
278277//   osd_update_audio_stream
279278//============================================================
280279
281void osd_update_audio_stream(INT16 *buffer, int samples_this_frame)
280void osd_update_audio_stream(running_machine *machine, INT16 *buffer, int samples_this_frame)
282281{
283282   // if nothing to do, don't do it
284   if (Machine->sample_rate != 0 && stream_buffer)
283   if (machine->sample_rate != 0 && stream_buffer)
285284   {
286285      int bytes_this_frame = samples_this_frame * sizeof(INT16) * 2;
287286      int play_position, write_position, orig_write, stream_in;
288287
289288      play_position = stream_playpos;
290289
291      write_position = stream_playpos + ((Machine->sample_rate / 50) * sizeof(INT16) * 2);
290      write_position = stream_playpos + ((machine->sample_rate / 50) * sizeof(INT16) * 2);
292291      orig_write = write_position;
293292
294293      if (!stream_in_initialized)
src/osd/sdl/input.c
r1805r1806
2222#include "osdepend.h"
2323#include "driver.h"
2424#include "ui.h"
25#include "deprecat.h"
2625
2726// MAMEOS headers
2827#include "window.h"
r1805r1806
904903}
905904#endif
906905
907void sdlinput_poll(void)
906void sdlinput_poll(running_machine *machine)
908907{
909908   device_info *devinfo;
910909   SDL_Event event;
r1805r1806
939938      }
940939      switch(event.type) {
941940      case SDL_QUIT:
942         mame_schedule_exit(Machine);
941         mame_schedule_exit(machine);
943942         break;
944943      case SDL_KEYDOWN:
945944         #ifdef MESS
src/osd/sdl/input.h
r1805r1806
1818//============================================================
1919
2020void sdlinput_init(running_machine *machine);
21void sdlinput_poll(void);
21void sdlinput_poll(running_machine *machine);
2222int  sdlinput_should_hide_mouse(void);
2323
2424#ifdef SDLMAME_WIN32
makefile.sdl
r1805r1806
11###########################################################################
22#
3#   makefile.sdl
3#   makefile
44#
5#   Core makefile for building SDLMAME and derivatives
5#   Core makefile for building MAME and derivatives
66#
7#   Copyright (c) 1996-2007, Nicola Salmoria and the MAME Team.
7#   Copyright (c) Nicola Salmoria and the MAME Team.
88#   Visit http://mamedev.org for licensing and usage restrictions.
99#
10#   SDLMAME/MESS by Olivier Galibert and R. Belmont
11#
1210###########################################################################
1311
1412
r1805r1806
4543OSD = sdl
4644endif
4745
46ifndef CROSS_BUILD_OSD
47CROSS_BUILD_OSD = $(OSD)
48endif
4849
49
5050#-------------------------------------------------
5151# specify OS target, which further differentiates
5252# the underlying OS; supported values are:
r1805r1806
9898# uncomment next line to enable the debugger
9999# DEBUGGER = 1
100100
101# uncomment next line to include the debugger
101# uncomment next line to build a debug version
102102# DEBUG = 1
103103
104104# uncomment next line to include the internal profiler
r1805r1806
110110# uncomment next line to use DRC PowerPC engine
111111X86_PPC_DRC = 1
112112
113# uncomment next line to use DRC Voodoo rasterizers
114# X86_VOODOO_DRC = 1
113# uncomment next line to build using unix-style libsdl on Mac OS X
114# (vs. the native framework port).  Normal users should not enable this.
115# MACOSX_USE_LIBSDL = 1
115116
116117
117
118118#-------------------------------------------------
119119# specify build options; see each option below
120120# for details
r1805r1806
192192EXE = .exe
193193endif
194194
195ifndef BUILD_EXE
196BUILD_EXE = $(EXE)
197endif
198
195199# compiler, linker and utilities
196200AR = @ar
197201CC = @gcc
198202LD = @gcc
199HHC = @-hhc
200203MD = -mkdir$(EXE)
201204RM = @rm -f
202205
r1805r1806
206209# form the name of the executable
207210#-------------------------------------------------
208211
209# debug builds just get the 'd' suffix and nothing more
212# debugger builds just get the 'd' suffix and nothing more
210213ifdef DEBUGGER
211214DEBUGSUFFIX = d
212215endif
r1805r1806
283286DEFS += -DMAME_PROFILER
284287endif
285288
286# define VOODOO_DRC if we are building the DRC Voodoo engine
287ifdef X86_VOODOO_DRC
288DEFS += -DVOODOO_DRC
289endif
290289
291290
292
293291#-------------------------------------------------
294292# compile flags
295293#-------------------------------------------------
r1805r1806
332330# if we are optimizing, include optimization options
333331# and make all errors into warnings
334332ifneq ($(OPTIMIZE),0)
335#CFLAGS += -Werror $(ARCHOPTS) -fno-strict-aliasing
336333CFLAGS += $(ARCHOPTS) -fno-strict-aliasing
334ifneq ($(TARGETOS),os2)
335CFLAGS += -Werror
337336endif
337endif
338338
339339# if symbols are on, make sure we have frame pointers
340340ifdef SYMBOLS
r1805r1806
367367
368368# LDFLAGS are used generally; LDFLAGSEMULATOR are additional
369369# flags only used when linking the core emulator
370LDFLAGS =
370371ifneq ($(TARGETOS),macosx)
372ifneq ($(TARGETOS),os2)
371373LDFLAGS = -Wl,--warn-common
372else
373LDFLAGS=
374374endif
375endif
375376LDFLAGSEMULATOR =
376377
377378# add profiling information for the linker
r1805r1806
419420LIBSOUND = $(OBJ)/libsound.a
420421LIBUTIL = $(OBJ)/libutil.a
421422LIBOCORE = $(OBJ)/libocore.a
422LIBOCORE_NOMAIN = $(OBJ)/libocore_nomain.a
423423LIBOSD = $(OBJ)/libosd.a
424424
425425VERSIONOBJ = $(OBJ)/version.o
r1805r1806
462462all: maketree buildtools emulator tools
463463
464464
465#-------------------------------------------------
466# defines needed by multiple make files
467#-------------------------------------------------
465468
469BUILDSRC = $(SRC)/build
470BUILDOBJ = $(OBJ)/build
471BUILDOUT = $(BUILDOBJ)
472
473
466474#-------------------------------------------------
467475# include the various .mak files
468476#-------------------------------------------------
r1805r1806
475483include $(SRC)/emu/emu.mak
476484include $(SRC)/lib/lib.mak
477485include $(SRC)/build/build.mak
486-include $(SRC)/osd/$(CROSS_BUILD_OSD)/build.mak
478487include $(SRC)/tools/tools.mak
479488
480489# combine the various definitions to one
r1805r1806
492501
493502tools: maketree $(TOOLS)
494503
495help: maketree $(HELP)
496
497504maketree: $(sort $(OBJDIRS))
498505
499506clean:
r1805r1806
533540
534541endif
535542
536
537
538543#-------------------------------------------------
539544# generic rules
540545#-------------------------------------------------

Previous 15994 Revisions Next


© 1998-2018 The MESS Team