[Scummvm-devel] Woohoo! It runs!

Max Horn max at quendi.de
Fri Aug 1 11:41:07 CEST 2003


Am Freitag, 01.08.03 um 19:53 Uhr schrieb David Given:

> Not bad for about four hours work, I must say. Once I worked out the 
> quirks in
> the API it was all pretty straightforward.
>
> There's lots to do yet, so you won't be seeing it for a while, but it's
> playing the non-interactive part of monkeyEGA (the only demo I can lay 
> my
> hands on) happily.
>
> Still to do: keyboard input, sound output, threads, shakes, save file 
> manager,
> etc, etc. But it runs! Yay!
>
Congrats :-)

> I still have some questions.
>
> * How is sound generated? The main engine registers a callback with 
> me; I call
> this callback whenever I need to populate an audio fragment, right?
Yes

> How are things like latency or queuing issues handled?

Latency: well, you call the callback whenever you need new sound data; 
how often that is depends on your target system. Usually the callback 
should be "fast enough", but of course that depends on your target 
system. You may have to do double buffering if your machine is too slow 
to generate the samples in real time (most audio systems will do such a 
thing automatically anyway) . Not sure what you mean with "queuing" 
issues.


> * What is set_cursor_pos() for? Is it just to tell the backend where to
> display the mouse pointer? On my hosted environment, the mouse cursor 
> will be
> moved around by the GUI system itself, so I don't need to manually 
> move it
> every time a mouse motion event comes in. Can I implement it as a 
> noop, or is
> there ever a situation where the mouse pointer needs to be displayed 
> in a
> position other than where it is?

You can probably get along with making set_mouse_pos  a nop. It just 
"informs" the backend about where the mouse is. If your backend keeps 
track of that information itself, fine. warp_mouse is a different case 
of course.

> * What's the format of the mouse pointer bitmap?
Well, it's straight forward. You get a memory block with width*height 
256 color pixels.


> * Is there ever going to be more than one OSystem object at a time?
No. Only one OSystem object is ever created. That happens in main.cpp, 
when it invokes detector.createSystem().

>  I notice  that another object is created when a game is picked off 
> the menu; is the old  one always discarded first?

Eh? Where do you read that in the code?!? I am 99% sure you are 
mistaken there, we create one and only one OSystem object... it would 
be a serious bug to create a second one.


> Also, and slightly embarassingly, all my Scumm games are packed away in
> storage with my other computer. If anyone has a copy of the Monkey 
> Island
> VGA, Monkey Island 2, Sam & Max or Fate of Atlantis *demos*, would they
> please get in touch? monkeyEGA is not exactly going to wow the 
> bosses...

Normally I'd point you at http://www.scummvm.org/demos.php, but sadly 
Mixnmojo is still offline, so most of the demos linked there are 
offline, too.


Cheers,

Max





More information about the Scummvm-devel mailing list