[Coco] OVCC project update.

Joel Rees joel.rees at gmail.com
Sat Aug 18 06:30:57 EDT 2018


Wish I could send you more help than a thumbs-up.

2018年8月17日(金) 10:14 Walter Zambotti <zambotti at iinet.net.au>:

> So the audio/sound component of direct/x/sound is the last component to be
> converted to SDL.
>
>
>
> In comparison to the graphics conversion it has been challenging.  Where
> the
> graphics models between directx and sdl are similar enough that the
> conversion was straight forward the audio models are considerably
> different.
>
>
>
> Direct Sound has devices and devices are allocated sound buffers. The user
> has sound samples stored in memory. The user copies his sound sample from
> memory to a sound buffer.  Basically a memory to memory copy.  It was up to
> VCC to figure out what and where to copy.  So in VCC there were a lot of
> buffer pointers maintained and logic to maintain a circular buffer.
>
>
>
> SDL however has sound devices and sound queues (not buffers).  The user has
> samples stored in memory. The user just submits the sample to the queue.
> There's no concept of manipulating the sound buffers after that stage.
>
>
>
> So all the VCC sound buffer logic seems irrelevant.  So my SDL sound
> interface has very little code.
>
>
>
> In VCC whenever something is written to the sound register at FF22 (from
> memory) that value is also recorded in a small buffer (array) and once
> every
> 1/60 sec that small buffer is sent to the direct sound interface to place
> in
> the next position in the sound device's circular buffer.
>
>
>
> In SDL all I can do with that small buffer is queue it to the SDL sound
> device.
>
>
>
> So I have written the SDL sound code that I believe will work and I now
> begin to debug it.
>
>
>
> So keep your fingers crossed that that is all I need to do (queue it) !!!
>
>
>
> Walter
>
>
>
>
>
>
> --
> Coco mailing list
> Coco at maltedmedia.com
> https://pairlist5.pair.net/mailman/listinfo/coco
>


More information about the Coco mailing list