Re: Is there any easy way to make sound in programming

From: Lew Pitcher (lpitcher_at_sympatico.ca)
Date: 04/17/05


Date: Sun, 17 Apr 2005 01:30:19 -0400


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Zheng Da wrote:
> I want my program can make sound.
> The sound may be like the sound when a error dialog appears in the
> system.
> These sounds, in windows, is made by playing a small .wav file.
> What about Linux?
> Is there any easy way to make sound? or How?
> Thank you.

  #include <stdlib.h>
  system("/usr/bin/play /usr/local/share/sounds/Error.Dialog.wav");

- --
Lew Pitcher

Master Codewright & JOAT-in-training | GPG public key available on request
Registered Linux User #112576 (http://counter.li.org/)
Slackware - Because I know what I'm doing.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (GNU/Linux)

iD8DBQFCYfRragVFX4UWr64RAqb8AJwKG6STV00FuOAoahfGuiaMxt8BHQCgrX1L
4ltXNC/Ig+rs10YBplIYPJ8=
=wUoa
-----END PGP SIGNATURE-----



Relevant Pages

  • Re: New wheezy and problems setting up alsa for mpd
    ... video in 'Movie Player' with good sound, its just it doesn't seem to happen ... efever = http://sharon04.livejournal.com/ ... Registered Linux user 334501 ...
    (Debian-User)
  • [kde-linux] alsamixer error
    ... The sound works, the video plays, but I get this annoying ... Registered Linux user # 367800 ...
    (KDE)
  • Re: An Open Letter to Turtle Beach regarding the Riviera
    ... > Then they decided to dwindle out of existence thanks to pressure from ... Voyetra has gone for the low end with the Turtle Beach sound cards, ... should definitely have Linux support to boot. ... Registered Linux user #378193 ...
    (alt.os.linux.suse)
  • Re: Updates broke sound
    ... Thats odd... ... but the sound channels definitely are _not_ muted. ... Registered Linux User: 473690 ... Registered Ubuntu User: 22747 ...
    (Ubuntu)
  • [OT]: ffmpeg screen capture with webcam output
    ... capture my screen with sound I use the following command: ... I also would like the output of webcam to be on the screen at the same ... I was trying to use cheese but it locks sound even in picture ... Registered Linux User #487982. ...
    (Fedora)