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
b50347d4
Commit
b50347d4
authored
Oct 22, 2004
by
Robert Reif
Committed by
Alexandre Julliard
Oct 22, 2004
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Don't consider a bad format an error unless the capabilities say it
should be supported. Don't consider a device already in use an error.
parent
eb883577
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
34 additions
and
27 deletions
+34
-27
capture.c
dlls/dsound/tests/capture.c
+9
-2
dsound_test.h
dlls/dsound/tests/dsound_test.h
+25
-25
No files found.
dlls/dsound/tests/capture.c
View file @
b50347d4
...
...
@@ -435,7 +435,7 @@ static BOOL WINAPI dscenum_callback(LPGUID lpGuid, LPCSTR lpcstrDescription,
if
(
winetest_interactive
)
trace
(
" Testing the capture buffer at %s
\n
"
,
format_string
(
&
wfx
));
rc
=
IDirectSoundCapture_CreateCaptureBuffer
(
dsco
,
&
bufdesc
,
&
dscbo
,
NULL
);
ok
((
rc
==
DS_OK
)
&&
(
dscbo
!=
NULL
),
ok
((
(
rc
==
DS_OK
)
&&
(
dscbo
!=
NULL
))
||
(
rc
==
DSERR_BADFORMAT
)
||
(
rc
==
DSERR_ALLOCATED
),
"IDirectSoundCapture_CreateCaptureBuffer() failed to create a "
"capture buffer: %s
\n
"
,
DXGetErrorString8
(
rc
));
if
(
rc
==
DS_OK
)
{
...
...
@@ -443,7 +443,14 @@ static BOOL WINAPI dscenum_callback(LPGUID lpGuid, LPCSTR lpcstrDescription,
ref
=
IDirectSoundCaptureBuffer_Release
(
dscbo
);
ok
(
ref
==
0
,
"IDirectSoundCaptureBuffer_Release() has %d references, "
"should have 0
\n
"
,
ref
);
}
}
else
if
(
rc
==
DSERR_BADFORMAT
)
{
ok
(
!
(
dsccaps
.
dwFormats
&
formats
[
f
][
3
]),
"IDirectSoundCapture_CreateCaptureBuffer() failed to create a "
"capture buffer: format listed as supported but using it failed
\n
"
);
if
(
!
(
dsccaps
.
dwFormats
&
formats
[
f
][
3
]))
trace
(
" Format not supported: %s
\n
"
,
format_string
(
&
wfx
));
}
else
if
(
rc
==
DSERR_ALLOCATED
)
trace
(
" Already In Use
\n
"
);
}
/* try a non PCM format */
...
...
dlls/dsound/tests/dsound_test.h
View file @
b50347d4
...
...
@@ -18,31 +18,31 @@
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
static
const
unsigned
int
formats
[][
3
]
=
{
{
8000
,
8
,
1
},
{
8000
,
8
,
2
},
{
8000
,
16
,
1
},
{
8000
,
16
,
2
},
{
11025
,
8
,
1
},
{
11025
,
8
,
2
},
{
11025
,
16
,
1
},
{
11025
,
16
,
2
},
{
22050
,
8
,
1
},
{
22050
,
8
,
2
},
{
22050
,
16
,
1
},
{
22050
,
16
,
2
},
{
44100
,
8
,
1
},
{
44100
,
8
,
2
},
{
44100
,
16
,
1
},
{
44100
,
16
,
2
},
{
48000
,
8
,
1
},
{
48000
,
8
,
2
},
{
48000
,
16
,
1
},
{
48000
,
16
,
2
},
{
96000
,
8
,
1
},
{
96000
,
8
,
2
},
{
96000
,
16
,
1
},
{
96000
,
16
,
2
}
static
const
unsigned
int
formats
[][
4
]
=
{
{
8000
,
8
,
1
,
0
},
{
8000
,
8
,
2
,
0
},
{
8000
,
16
,
1
,
0
},
{
8000
,
16
,
2
,
0
},
{
11025
,
8
,
1
,
WAVE_FORMAT_1M08
},
{
11025
,
8
,
2
,
WAVE_FORMAT_1S08
},
{
11025
,
16
,
1
,
WAVE_FORMAT_1M16
},
{
11025
,
16
,
2
,
WAVE_FORMAT_1S16
},
{
22050
,
8
,
1
,
WAVE_FORMAT_2M08
},
{
22050
,
8
,
2
,
WAVE_FORMAT_2S08
},
{
22050
,
16
,
1
,
WAVE_FORMAT_2M16
},
{
22050
,
16
,
2
,
WAVE_FORMAT_2S16
},
{
44100
,
8
,
1
,
WAVE_FORMAT_4M08
},
{
44100
,
8
,
2
,
WAVE_FORMAT_4S08
},
{
44100
,
16
,
1
,
WAVE_FORMAT_4M16
},
{
44100
,
16
,
2
,
WAVE_FORMAT_4S16
},
{
48000
,
8
,
1
,
WAVE_FORMAT_48M08
},
{
48000
,
8
,
2
,
WAVE_FORMAT_48S08
},
{
48000
,
16
,
1
,
WAVE_FORMAT_48M16
},
{
48000
,
16
,
2
,
WAVE_FORMAT_48S16
},
{
96000
,
8
,
1
,
WAVE_FORMAT_96M08
},
{
96000
,
8
,
2
,
WAVE_FORMAT_96S08
},
{
96000
,
16
,
1
,
WAVE_FORMAT_96M16
},
{
96000
,
16
,
2
,
WAVE_FORMAT_96S16
}
};
#define NB_FORMATS (sizeof(formats)/sizeof(*formats))
...
...
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