dmusic: framework for file loading
Christian Costa
titan.costa at wanadoo.fr
Sun Jun 22 18:22:32 CDT 2003
Raphaël Junqueira wrote:
>-----BEGIN PGP SIGNED MESSAGE-----
>Hash: SHA1
>
>Hi rok ;)
>
>> As I've mentioned, we'll need a function for loading chunks from dmusic
>>files. I tried to write one, and here's result; it's not very nice, but
>>it works (sort of).
>> At the time being, it only "loads" and displays data
>>(--debugmsg=+dmfile for debug and --debugmsg=+dmfiledat for the display
>>of data). I couldn't make it load data into IDirectMusic*Impl
>>interfaces, because whatever I did, exception occured (maybe someone
>>more familiar with this could do this (Raphael?)). Also, if someone has
>>more robust and simpler function, please tell me.
>> DMUSIC_FillSegmentFromFileHandle loads sample.sgt from DX SDK
>>completely... however, i didn't try the other.
>>
>
>Impressive work ;)
>
Indeed, good job! ;-)
>
>
>> Also "fixed" a problem I've encountered while running 3DAudio.exe (from
>>SDK). One of the latest patches added this clause:
>>
>>if (!ppDirectSound)
>> IDirectSound_Release(*ppDirectSound);
>>
>
>well, seem another christian regression ;)
>
;-)
I suppose the first regression is the crash when DirectSoundCreate
failed when no driver is selected in the config file... :-)
In that case, I was thinking to myself if we should be able to create
DirectPerformance or DirectMusic objects or not.
If so, Init and InitAudio functions should failed with an error.
The error value could be DSERR_NODRIVER, E_NOINTERFACE or
DSERR_UNINITIALIZED.
Any idea?
>
>for what i understand, this code must be the correct one:
>if (!ppDirectSound)
> IDirectSound_Release(This->dsound);
>
This is right. :-)
>
>
>>I don't know why, but it causes exception (i've commented it).
>>
>
>well Releasing a NULL object ;)
>
>>ChangeLog:
>> - wine/dlls/dmusic/dmusic_private.h: added some new structs
>> - wine/dlls/dmusic/dmusic_loader.c: load file
>> - wine/dlls/dmusic/dmusic_preformance.c: minor fix
>> - wine/dlls/dmusic/helper.c: new file with file loading functions
>>
>
>Regards,
>Raphael
>-----BEGIN PGP SIGNATURE-----
>Version: GnuPG v1.2.2 (GNU/Linux)
>
>iD8DBQE+9ctCp7NA3AmQTU4RAnTBAJ9rsoPKZWAzvofqiK2ENFqi6Ja73gCfTICO
>thCaWwcK4Qcria2lDYb2AFU=
>=TGgh
>-----END PGP SIGNATURE-----
>
>
More information about the wine-devel
mailing list