Subject: Re: Gnome Sounds on Xterminal
To: Jenkins, Graham K <Graham.K.Jenkins@team.telstra.com>
From: Greg A. Woods <woods@weird.com>
List: port-i386
Date: 11/09/2001 15:00:10
[ On Friday, November 9, 2001 at 15:31:38 (+1100), Jenkins, Graham K wrote: ]
> Subject: Gnome Sounds on Xterminal
>
> Hi.  I am using a number of NetBSD machines
> as Xterminals - with XDM control from remote
> Solaris machines running Gnome.  
> 
> This works well - except I can't figure how to make
> the Gnome (or other X) sound effects come out of
> the Xterminal.

[[ this is really a netbsd-users question, not just port-i386 -- redirected ]]

The first step is to install pgksrc/audio/nas on all of the machines
involved (including on the servers hosting your X11 clients).  There are
many little utilities included to talk to the audio server.

I'm not sure exactly what you would do for Gnome's window manager, but
for example with ctwm you add something like this to its config:

	# Define some useful functions for motion-based actions.
	# DefaultFunction must come after fonts....
	#
	ChangeWorkspaceFunction		!"auplay /usr/local/lib/sounds/wm-wschange &"
	IconifyFunction			!"auplay /usr/local/lib/sounds/wm-iconify &"
	DeIconifyFunction		!"auplay /usr/local/lib/sounds/wm-deiconify &"
	DefaultFunction			!"auplay /usr/local/lib/sounds/wm-default &"

There's a NAS output plugin available for xmms, and mpg123 can be built
with NAS support too.  I submitted a PR with a pkgsrc module for the
latter (PR#14317) and one of these days soon I'll get around to doing
the same for the xmms-nas plugin too.

Lots of other tools can send AU format audio to stdout, and that can be
fed to auplay too:

	ogg123 -v -d au -f - some_file.ogg | auplay

I use all of the above with my NCD-HMX terminal (the newest software for
the NCD-19c has NAS support too, but there's no external audio-out jack
and the internal speaker is small and un-amplified).  I hope to one day
soon upgrade my diskless SS-1+ and get NAS working on it too (it's no-go
on NetBSD/sparc-1.3.2).

Supposedly Festival, OpenOffice(StarOffice), XAnim, XBoing, XPilot, and
Alsaplayer all have NAS support, and there's a libaudiooss pre-load
dynamic shared library that might be ported to NetBSD (it fakes OSS
programs into thinking your NAS server is just another sound card).
There's also native NAS support available in the Qt library and libSDL.

-- 
							Greg A. Woods

+1 416 218-0098      VE3TCP      <gwoods@acm.org>     <woods@robohack.ca>
Planix, Inc. <woods@planix.com>;   Secrets of the Weird <woods@weird.com>