Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
140d8cd9
Commit
140d8cd9
authored
Oct 12, 2000
by
Eric Pouech
Committed by
Alexandre Julliard
Oct 12, 2000
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added PCM converter internal driver.
A few driver handling fixes.
parent
bd8ede1b
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
39 additions
and
29 deletions
+39
-29
Makefile.in
dlls/msacm/Makefile.in
+1
-0
driver.c
dlls/msacm/driver.c
+22
-22
format.c
dlls/msacm/format.c
+1
-1
internal.c
dlls/msacm/internal.c
+8
-5
msacm32.spec
dlls/msacm/msacm32.spec
+3
-0
pcmconverter.c
dlls/msacm/pcmconverter.c
+0
-0
wineacm.h
dlls/msacm/wineacm.h
+4
-1
No files found.
dlls/msacm/Makefile.in
View file @
140d8cd9
...
@@ -14,6 +14,7 @@ C_SRCS = \
...
@@ -14,6 +14,7 @@ C_SRCS = \
internal.c
\
internal.c
\
msacm32_main.c
\
msacm32_main.c
\
msacm_main.c
\
msacm_main.c
\
pcmconverter.c
\
stream.c
stream.c
RC_SRCS
=
\
RC_SRCS
=
\
...
...
dlls/msacm/driver.c
View file @
140d8cd9
...
@@ -76,27 +76,32 @@ MMRESULT WINAPI acmDriverAddW(PHACMDRIVERID phadid, HINSTANCE hinstModule,
...
@@ -76,27 +76,32 @@ MMRESULT WINAPI acmDriverAddW(PHACMDRIVERID phadid, HINSTANCE hinstModule,
*/
*/
MMRESULT
WINAPI
acmDriverClose
(
HACMDRIVER
had
,
DWORD
fdwClose
)
MMRESULT
WINAPI
acmDriverClose
(
HACMDRIVER
had
,
DWORD
fdwClose
)
{
{
PWINE_ACMDRIVER
p
;
PWINE_ACMDRIVER
pad
;
PWINE_ACMDRIVER
*
tp
;
PWINE_ACMDRIVERID
padid
;
PWINE_ACMDRIVER
*
tpad
;
if
(
fdwClose
)
if
(
fdwClose
)
return
MMSYSERR_INVALFLAG
;
return
MMSYSERR_INVALFLAG
;
p
=
MSACM_GetDriver
(
had
);
p
ad
=
MSACM_GetDriver
(
had
);
if
(
!
p
)
if
(
!
p
ad
)
return
MMSYSERR_INVALHANDLE
;
return
MMSYSERR_INVALHANDLE
;
for
(
tp
=
&
(
p
->
obj
.
pACMDriverID
->
pACMDriverList
);
*
tp
;
*
tp
=
(
*
tp
)
->
pNextACMDriver
)
{
padid
=
pad
->
obj
.
pACMDriverID
;
if
(
*
tp
==
p
)
{
*
tp
=
(
*
tp
)
->
pNextACMDriver
;
/* remove driver from list */
for
(
tpad
=
&
(
padid
->
pACMDriverList
);
*
tpad
;
*
tpad
=
(
*
tpad
)
->
pNextACMDriver
)
{
if
(
*
tpad
==
pad
)
{
*
tpad
=
(
*
tpad
)
->
pNextACMDriver
;
break
;
break
;
}
}
}
}
if
(
p
->
hDrvr
&&
!
p
->
obj
.
pACMDriverID
->
pACMDriverList
)
/* close driver if it has been opened */
CloseDriver
(
p
->
hDrvr
,
0
,
0
);
if
(
pad
->
hDrvr
&&
!
padid
->
hInstModule
)
CloseDriver
(
pad
->
hDrvr
,
0
,
0
);
HeapFree
(
MSACM_hHeap
,
0
,
p
);
HeapFree
(
MSACM_hHeap
,
0
,
p
ad
);
return
MMSYSERR_NOERROR
;
return
MMSYSERR_NOERROR
;
}
}
...
@@ -232,30 +237,25 @@ MMRESULT WINAPI acmDriverOpen(PHACMDRIVER phad, HACMDRIVERID hadid, DWORD fdwOpe
...
@@ -232,30 +237,25 @@ MMRESULT WINAPI acmDriverOpen(PHACMDRIVER phad, HACMDRIVERID hadid, DWORD fdwOpe
if
(
!
phad
)
if
(
!
phad
)
return
MMSYSERR_INVALPARAM
;
return
MMSYSERR_INVALPARAM
;
if
(
fdwOpen
)
return
MMSYSERR_INVALFLAG
;
padid
=
MSACM_GetDriverID
(
hadid
);
padid
=
MSACM_GetDriverID
(
hadid
);
if
(
!
padid
)
if
(
!
padid
)
return
MMSYSERR_INVALHANDLE
;
return
MMSYSERR_INVALHANDLE
;
if
(
fdwOpen
)
return
MMSYSERR_INVALFLAG
;
pad
=
HeapAlloc
(
MSACM_hHeap
,
0
,
sizeof
(
WINE_ACMDRIVER
));
pad
=
HeapAlloc
(
MSACM_hHeap
,
0
,
sizeof
(
WINE_ACMDRIVER
));
if
(
!
pad
)
return
MMSYSERR_NOMEM
;
if
(
!
pad
)
return
MMSYSERR_NOMEM
;
pad
->
obj
.
dwType
=
WINE_ACMOBJ_DRIVER
;
pad
->
obj
.
dwType
=
WINE_ACMOBJ_DRIVER
;
pad
->
obj
.
pACMDriverID
=
padid
;
pad
->
obj
.
pACMDriverID
=
padid
;
if
(
!
padid
->
hInstModule
)
if
(
!
(
pad
->
hDrvr
=
padid
->
hInstModule
)
&&
padid
->
pszDriverAlias
)
pad
->
hDrvr
=
OpenDriverA
(
padid
->
pszDriverAlias
,
"drivers32"
,
0
);
pad
->
hDrvr
=
OpenDriverA
(
padid
->
pszDriverAlias
,
NULL
,
0
);
else
pad
->
hDrvr
=
padid
->
hInstModule
;
if
(
!
pad
->
hDrvr
)
{
if
(
!
pad
->
hDrvr
)
{
HeapFree
(
MSACM_hHeap
,
0
,
pad
);
HeapFree
(
MSACM_hHeap
,
0
,
pad
);
return
MMSYSERR_ERROR
;
return
MMSYSERR_ERROR
;
}
}
pad
->
pfnDriverProc
=
GetProcAddress
(
pad
->
hDrvr
,
"DriverProc"
);
/* insert new pad at beg of list */
/* insert new pad at beg of list */
pad
->
pNextACMDriver
=
padid
->
pACMDriverList
;
pad
->
pNextACMDriver
=
padid
->
pACMDriverList
;
...
@@ -263,7 +263,7 @@ MMRESULT WINAPI acmDriverOpen(PHACMDRIVER phad, HACMDRIVERID hadid, DWORD fdwOpe
...
@@ -263,7 +263,7 @@ MMRESULT WINAPI acmDriverOpen(PHACMDRIVER phad, HACMDRIVERID hadid, DWORD fdwOpe
/* FIXME: Create a WINE_ACMDRIVER32 */
/* FIXME: Create a WINE_ACMDRIVER32 */
*
phad
=
(
HACMDRIVER
)
pad
;
*
phad
=
(
HACMDRIVER
)
pad
;
TRACE
(
"'%s' => %08lx
\n
"
,
padid
->
pszDriverAlias
,
(
DWORD
)
pad
);
return
MMSYSERR_NOERROR
;
return
MMSYSERR_NOERROR
;
}
}
...
...
dlls/msacm/format.c
View file @
140d8cd9
...
@@ -484,7 +484,7 @@ MMRESULT WINAPI acmFormatEnumW(HACMDRIVER had, PACMFORMATDETAILSW pafd,
...
@@ -484,7 +484,7 @@ MMRESULT WINAPI acmFormatEnumW(HACMDRIVER had, PACMFORMATDETAILSW pafd,
if
(
fdwEnum
&
(
ACM_FORMATENUMF_CONVERT
|
ACM_FORMATENUMF_SUGGEST
|
if
(
fdwEnum
&
(
ACM_FORMATENUMF_CONVERT
|
ACM_FORMATENUMF_SUGGEST
|
ACM_FORMATENUMF_INPUT
|
ACM_FORMATENUMF_OUTPUT
))
ACM_FORMATENUMF_INPUT
|
ACM_FORMATENUMF_OUTPUT
))
FIXME
(
"Unsupported fdwEnum values
\n
"
);
FIXME
(
"Unsupported fdwEnum values
%08lx
\n
"
,
fdwEnum
);
if
(
had
)
{
if
(
had
)
{
HACMDRIVERID
hadid
;
HACMDRIVERID
hadid
;
...
...
dlls/msacm/internal.c
View file @
140d8cd9
...
@@ -42,8 +42,8 @@ PWINE_ACMDRIVERID MSACM_RegisterDriver(LPSTR pszDriverAlias, LPSTR pszFileName,
...
@@ -42,8 +42,8 @@ PWINE_ACMDRIVERID MSACM_RegisterDriver(LPSTR pszDriverAlias, LPSTR pszFileName,
padid
=
(
PWINE_ACMDRIVERID
)
HeapAlloc
(
MSACM_hHeap
,
0
,
sizeof
(
WINE_ACMDRIVERID
));
padid
=
(
PWINE_ACMDRIVERID
)
HeapAlloc
(
MSACM_hHeap
,
0
,
sizeof
(
WINE_ACMDRIVERID
));
padid
->
obj
.
dwType
=
WINE_ACMOBJ_DRIVERID
;
padid
->
obj
.
dwType
=
WINE_ACMOBJ_DRIVERID
;
padid
->
obj
.
pACMDriverID
=
padid
;
padid
->
obj
.
pACMDriverID
=
padid
;
padid
->
pszDriverAlias
=
HEAP_strdupA
(
MSACM_hHeap
,
0
,
pszDriverAlias
)
;
padid
->
pszDriverAlias
=
pszDriverAlias
?
HEAP_strdupA
(
MSACM_hHeap
,
0
,
pszDriverAlias
)
:
NULL
;
padid
->
pszFileName
=
HEAP_strdupA
(
MSACM_hHeap
,
0
,
pszFileName
)
;
padid
->
pszFileName
=
pszFileName
?
HEAP_strdupA
(
MSACM_hHeap
,
0
,
pszFileName
)
:
NULL
;
padid
->
hInstModule
=
hinstModule
;
padid
->
hInstModule
=
hinstModule
;
padid
->
bEnabled
=
TRUE
;
padid
->
bEnabled
=
TRUE
;
padid
->
pACMDriverList
=
NULL
;
padid
->
pACMDriverList
=
NULL
;
...
@@ -65,7 +65,7 @@ void MSACM_RegisterAllDrivers(void)
...
@@ -65,7 +65,7 @@ void MSACM_RegisterAllDrivers(void)
{
{
LPSTR
pszBuffer
;
LPSTR
pszBuffer
;
DWORD
dwBufferLength
;
DWORD
dwBufferLength
;
/* FIXME
/* FIXME
* What if the user edits system.ini while the program is running?
* What if the user edits system.ini while the program is running?
* Does Windows handle that?
* Does Windows handle that?
...
@@ -85,8 +85,9 @@ void MSACM_RegisterAllDrivers(void)
...
@@ -85,8 +85,9 @@ void MSACM_RegisterAllDrivers(void)
char
*
s2
=
s
;
char
*
s2
=
s
;
while
(
*
s2
!=
'\0'
&&
*
s2
!=
'='
)
s2
++
;
while
(
*
s2
!=
'\0'
&&
*
s2
!=
'='
)
s2
++
;
if
(
*
s2
)
{
if
(
*
s2
)
{
*
s2
++
=
'\0'
;
*
s2
=
'\0'
;
MSACM_RegisterDriver
(
s
,
s2
,
0
);
MSACM_RegisterDriver
(
s
,
s2
+
1
,
0
);
*
s2
=
'='
;
}
}
}
}
s
+=
strlen
(
s
)
+
1
;
/* Either next char or \0 */
s
+=
strlen
(
s
)
+
1
;
/* Either next char or \0 */
...
@@ -94,6 +95,8 @@ void MSACM_RegisterAllDrivers(void)
...
@@ -94,6 +95,8 @@ void MSACM_RegisterAllDrivers(void)
}
}
HeapFree
(
MSACM_hHeap
,
0
,
pszBuffer
);
HeapFree
(
MSACM_hHeap
,
0
,
pszBuffer
);
MSACM_RegisterDriver
(
"msacm32.dll"
,
"msacm32.dll"
,
0
);
}
}
/***********************************************************************
/***********************************************************************
...
...
dlls/msacm/msacm32.spec
View file @
140d8cd9
...
@@ -51,3 +51,6 @@ import kernel32.dll
...
@@ -51,3 +51,6 @@ import kernel32.dll
42 stdcall acmStreamReset(long long) acmStreamReset
42 stdcall acmStreamReset(long long) acmStreamReset
43 stdcall acmStreamSize(long long ptr long) acmStreamSize
43 stdcall acmStreamSize(long long ptr long) acmStreamSize
44 stdcall acmStreamUnprepareHeader(long ptr long) acmStreamUnprepareHeader
44 stdcall acmStreamUnprepareHeader(long ptr long) acmStreamUnprepareHeader
# this is wine only
@ stdcall DriverProc(long long long long long) PCM_DriverProc
dlls/msacm/pcmconverter.c
0 → 100644
View file @
140d8cd9
This diff is collapsed.
Click to expand it.
dlls/msacm/wineacm.h
View file @
140d8cd9
...
@@ -285,7 +285,6 @@ typedef struct _WINE_ACMDRIVER
...
@@ -285,7 +285,6 @@ typedef struct _WINE_ACMDRIVER
{
{
WINE_ACMOBJ
obj
;
WINE_ACMOBJ
obj
;
HDRVR
hDrvr
;
HDRVR
hDrvr
;
DRIVERPROC
pfnDriverProc
;
PWINE_ACMDRIVER
pNextACMDriver
;
PWINE_ACMDRIVER
pNextACMDriver
;
}
WINE_ACMDRIVER
;
}
WINE_ACMDRIVER
;
...
@@ -328,6 +327,10 @@ extern MMRESULT MSACM_Message(HACMDRIVER, UINT, LPARAM, LPARAM);
...
@@ -328,6 +327,10 @@ extern MMRESULT MSACM_Message(HACMDRIVER, UINT, LPARAM, LPARAM);
/* From msacm32.c */
/* From msacm32.c */
extern
HINSTANCE
MSACM_hInstance32
;
extern
HINSTANCE
MSACM_hInstance32
;
/* From pcmcnvtr.c */
LRESULT
CALLBACK
PCM_DriverProc
(
DWORD
dwDevID
,
HDRVR
hDriv
,
UINT
wMsg
,
LPARAM
dwParam1
,
LPARAM
dwParam2
);
/* Dialog box templates */
/* Dialog box templates */
#define DLG_ACMFORMATCHOOSE_ID 70
#define DLG_ACMFORMATCHOOSE_ID 70
#define IDD_ACMFORMATCHOOSE_BTN_HELP 9
#define IDD_ACMFORMATCHOOSE_BTN_HELP 9
...
...
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