Bug 8002 - SoundPlayer does not play wav files
Summary: SoundPlayer does not play wav files
Status: NEW
Alias: None
Product: Class Libraries
Classification: Mono
Component: System (show other bugs)
Version: unspecified
Hardware: PC Linux
: --- normal
Target Milestone: Untriaged
Assignee: Bugzilla
URL:
Depends on:
Blocks:
 
Reported: 2012-10-25 15:36 UTC by Robert Pickering
Modified: 2014-07-08 03:02 UTC (History)
2 users (show)

See Also:
Tags:
Is this bug a regression?: ---
Last known good build:


Attachments
example of sound player not playing sound (314 bytes, text/x-csharp)
2012-10-25 15:36 UTC, Robert Pickering
Details

Description Robert Pickering 2012-10-25 15:36:45 UTC
Created attachment 2795 [details]
example of sound player not playing sound

I'm trying to use the sound player to play a wave file. I've attached a simple repo, you'll need to update the path to valid wav file. Neither the .Play() or .PlaySync() methods play any sound, both return immediately and no exception is thrown. I've noticed if I put an invalid path an exception is thrown, so the file is at least being loaded. 

I'm running this on Ubuntu 12.10 and I've checked that playing a sound though the built in player does work. 

Here's the output of mono version:
Mono JIT compiler version 2.11.4 (tarball Tue Oct 23 06:18:52 CEST 2012)
Copyright (C) 2002-2012 Novell, Inc, Xamarin Inc and Contributors. www.mono-project.com
	TLS:           __thread
	SIGSEGV:       altstack
	Notifications: epoll
	Architecture:  amd64
	Disabled:      none
	Misc:          softdebug 
	LLVM:          supported, not enabled.
	GC:            Included Boehm (with typed GC and Parallel Mark)


Thanks for your help!
Comment 1 chrys 2014-07-08 03:02:25 UTC
confirmed as descriped.
it seems that is does also not work if i try to play a stream like this:
	class MainClass
	{

			FileStream file = new FileStream("test.wav", 
				FileMode.Open, FileAccess.Read, FileShare.Read);
			SoundPlayer player = new SoundPlayer(file);
			player.PlaySync();
	}

i work on arch.

[chrys@blackbeast Debug]$ mono --version
Mono JIT compiler version 3.4.0 (tarball Wed Jun 25 20:39:03 UTC 2014)
Copyright (C) 2002-2014 Novell, Inc, Xamarin Inc and Contributors. www.mono-project.com
	TLS:           __thread
	SIGSEGV:       altstack
	Notifications: epoll
	Architecture:  amd64
	Disabled:      none
	Misc:          softdebug 
	LLVM:          supported, not enabled.
	GC:            sgen

Note You need to log in before you can comment on or make changes to this bug.