[Scummvm-devel] Keyboard & mouse

Max Horn max at quendi.de
Wed Aug 6 10:30:08 CEST 2003


Am Mittwoch, 06.08.03 um 17:39 Uhr schrieb David Given:

> Further to my quest to get write a new ScummVM backend...
>
> I'm having trouble getting the mouse pointer drawn. set_mouse_cursor() 
> is
> being called, and I'm constructing a 8-bit paletted pixmap from the 
> data it's
> giving to me, but for some reason it's always appearing as a black 
> square.
> The palette *is* the same as for the main screen, right? The 
> transparent
> colour is 0xFF?
Yes to all.

> Is the data pointer it gives me persistent, or should I copy
> the data?
>
You must copy it. I would strongly recommend you look at existing 
backends whenever you are in doubt, in particular the SDL backend, 
which essentially is the "reference backend".

> I also having a bit of trouble with the keyboard --- the main thing is 
> that I
> can't seem to find a list of the available key codes anywhere. The 
> closest
> I've found is the SDL port's mapKey() function, which seems to tell me 
> that
> F1 is 315, the keypad is mapped to ASCII numbers, the cursor keys are, 
> um,
> the same that SDL uses internally...
Exactly.

>  is there a definitive list anywhere?

Nope.

> And I've had a quick look at the audio system. I'm sorry to say it, 
> but intent
> is going to get on really badly with ScummVM's internal mixer. It 
> would much
> prefer a higher-level interface where ScummVM talks to intent directly
> whenever it wants to play something. I can pretty much guarantee that 
> intent
> will support whatever features ScummVM wants... can this be done, or 
> will it
> require huge redesign of ScummVM's audio system?
>
It will require a huge redesign of the backend system and the audio 
system.


Max





More information about the Scummvm-devel mailing list