Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
4b40180e
Commit
4b40180e
authored
Sep 04, 2003
by
Christian Costa
Committed by
Alexandre Julliard
Sep 04, 2003
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix modLongData.
Enable opening of MOD_SYNTH type devices. Add some comments.
parent
c7a539d8
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
4 deletions
+12
-4
midi.c
dlls/winmm/wineoss/midi.c
+12
-4
No files found.
dlls/winmm/wineoss/midi.c
View file @
4b40180e
...
...
@@ -115,6 +115,8 @@ static int MIDI_UnixToWindowsDeviceType(int type)
* MOD_SQSYNTH square wave internal synth
* MOD_FMSYNTH FM internal synth
* MOD_MAPPER MIDI mapper
* MOD_WAVETABLE hardware watetable internal synth
* MOD_SWSYNTH software internal synth
*/
/* FIXME Is this really the correct equivalence from UNIX to
...
...
@@ -566,9 +568,9 @@ static void midReceiveChar(WORD wDevID, unsigned char value, DWORD dwTime)
static
VOID
WINAPI
midTimeCallback
(
HWND
hwnd
,
UINT
msg
,
UINT
id
,
DWORD
dwTime
)
{
unsigned
char
buffer
[
256
];
int
len
,
idx
;
unsigned
char
buffer
[
256
];
int
len
,
idx
;
TRACE
(
"(%p, %d, %d, %lu)
\n
"
,
hwnd
,
msg
,
id
,
dwTime
);
len
=
read
(
midiSeqFD
,
buffer
,
sizeof
(
buffer
));
...
...
@@ -1048,6 +1050,7 @@ static DWORD modOpen(WORD wDevID, LPMIDIOPENDESC lpDesc, DWORD dwFlags)
}
break
;
case
MOD_MIDIPORT
:
case
MOD_SYNTH
:
if
(
midiOpenSeq
()
<
0
)
{
return
MMSYSERR_ALLOCATED
;
}
...
...
@@ -1421,6 +1424,11 @@ static DWORD modLongData(WORD wDevID, LPMIDIHDR lpMidiHdr, DWORD dwSize)
TRACE
(
"(%04X, %p, %08lX);
\n
"
,
wDevID
,
lpMidiHdr
,
dwSize
);
/* Note: MS doc does not say much about the dwBytesRecorded member of the MIDIHDR structure
* but it seems to be used only for midi input.
* Taking a look at the WAVEHDR structure (which is quite similar) confirms this assumption.
*/
if
(
wDevID
>=
MODM_NumDevs
)
return
MMSYSERR_BADDEVICEID
;
if
(
!
MidiOutDev
[
wDevID
].
bEnabled
)
return
MIDIERR_NODEVICE
;
...
...
@@ -1465,7 +1473,7 @@ static DWORD modLongData(WORD wDevID, LPMIDIHDR lpMidiHdr, DWORD dwSize)
WARN
(
"Adding missing 0xF0 marker at the beginning of "
"system exclusive byte stream
\n
"
);
}
for
(
count
=
0
;
count
<
lpMidiHdr
->
dwB
ytesRecorded
;
count
++
)
{
for
(
count
=
0
;
count
<
lpMidiHdr
->
dwB
ufferLength
;
count
++
)
{
SEQ_MIDIOUT
(
wDevID
-
MODM_NumFMSynthDevs
,
lpData
[
count
]);
}
if
(
lpData
[
count
-
1
]
!=
0xF7
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment