<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0">
  <channel>
    <title>'tones' Thread RSS Feed</title>
    <link>http://www.programmersheaven.com/</link>
    <description>Contains the latest posts from the thread 'tones' posted on the 'Java' forum at Programmer's Heaven.</description>
    <language>en</language>
    <copyright>Copyright 2013 Programmers Heaven</copyright>
    <pubDate>Sat, 18 May 2013 14:19:17 -0700</pubDate>
    <lastBuildDate>Sat, 18 May 2013 14:19:17 -0700</lastBuildDate>
    <generator>Argotic Syndication Framework 2007.3.0.1, http://www.codeplex.com/Argotic</generator>
    <docs>http://www.rssboard.org/rss-specification</docs>
    <ttl>360</ttl>
    <image>
      <url>http://www.programmersheaven.com/images/ph.gif</url>
      <title>Programmers Heaven</title>
      <link>http://www.programmersheaven.com/</link>
      <width>88</width>
      <height>31</height>
    </image>
    <item>
      <title>tones</title>
      <link>http://www.programmersheaven.com/mb/java/210108/210108/tones/</link>
      <description>is there a Java class for basic musical commands like qbasic has?&lt;br /&gt;</description>
      <guid isPermaLink="true">http://www.programmersheaven.com/mb/java/210108/210108/tones/</guid>
      <pubDate>Mon, 01 Sep 2003 03:42:45 -0700</pubDate>
      <category>Java</category>
    </item>
    <item>
      <title>Re: tones</title>
      <link>http://www.programmersheaven.com/mb/java/210108/210142/re-tones/#210142</link>
      <description>: is there a Java class for basic musical commands like qbasic has?&lt;br /&gt;
: &lt;br /&gt;
&lt;br /&gt;
&lt;a href="http://innix.com/jfugue/"&gt;http://innix.com/jfugue/&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
Iceman&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Unix is user friendly. It's just very particular about who its friends are.&lt;br /&gt;
&lt;br /&gt;</description>
      <guid isPermaLink="true">http://www.programmersheaven.com/mb/java/210108/210142/re-tones/#210142</guid>
      <pubDate>Mon, 01 Sep 2003 08:07:11 -0700</pubDate>
      <category>Java</category>
    </item>
    <item>
      <title>Re: tones</title>
      <link>http://www.programmersheaven.com/mb/java/210108/210267/re-tones/#210267</link>
      <description>thanks for the link Iceperson.&lt;br /&gt;
I need a little more help I'm afraid.&lt;br /&gt;
I've begun with the first programming example, and I'm trying to compile it from the command line as it says.:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1 error:&lt;br /&gt;
C:\&amp;gt;javac -classpath c:\jfugue MyMusicApp.java&lt;br /&gt;
MyMusicApp.java:9: cannot resolve symbol&lt;br /&gt;
symbol : method play ()&lt;br /&gt;
location: class org.jfugue.Pattern&lt;br /&gt;
                                pattern.play();&lt;br /&gt;
1 error&lt;br /&gt;
&lt;br /&gt;
and then there's a circumflex-thingy pointing at the dot of .play (which I can't find on my keyb)&lt;br /&gt;
&lt;br /&gt;
I believe my java is uptodate- I got the latest one from Sun a month or so ago....&lt;br /&gt;
&lt;br /&gt;
And I'm assuming I've done the classpath thing right as I had even more errors before (eg if I tried to javac without the jfugue classpath)..&lt;br /&gt;
&lt;br /&gt;
thanks for your patience&lt;br /&gt;
&lt;br /&gt;
Osella&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
                                       &lt;br /&gt;
 : is there a Java class for basic musical commands like qbasic has?&lt;br /&gt;
: : &lt;br /&gt;
: &lt;br /&gt;
: &lt;a href="http://innix.com/jfugue/"&gt;http://innix.com/jfugue/&lt;/a&gt;&lt;br /&gt;
: &lt;br /&gt;
: Iceman&lt;br /&gt;
: &lt;br /&gt;
: &lt;br /&gt;
: &lt;br /&gt;
: Unix is user friendly. It's just very particular about who its friends are.&lt;br /&gt;
: &lt;br /&gt;
: &lt;br /&gt;
&lt;br /&gt;</description>
      <guid isPermaLink="true">http://www.programmersheaven.com/mb/java/210108/210267/re-tones/#210267</guid>
      <pubDate>Tue, 02 Sep 2003 06:28:49 -0700</pubDate>
      <category>Java</category>
    </item>
    <item>
      <title>Re: tones</title>
      <link>http://www.programmersheaven.com/mb/java/210108/210315/re-tones/#210315</link>
      <description>For a quick solution, try using java.applet.AudioClip class.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
// there is a folder named waves in the same folder that has the html&lt;br /&gt;
String path= "waves/tone.wav" ; &lt;br /&gt;
AudioClip clip;&lt;br /&gt;
&lt;br /&gt;
// For an applet&lt;br /&gt;
clip= myapplet.getAudioClip(getDocumentBase(), path ); &lt;br /&gt;
&lt;br /&gt;
// For anything else - I think it even works with consol screen no gui &lt;br /&gt;
clip =  Applet.newAudioClip(URL url) ; &lt;br /&gt;
&lt;br /&gt;
the Applet.newAudioClip(URL url)  is a static method in Applet.  so you could use it without creating an applet instance.&lt;br /&gt;
The url might be &lt;br /&gt;
URL url =new File(path).toURL();&lt;br /&gt;
URL url= this.getClass().getResource (path);&lt;br /&gt;
where path is either the fully qualified pathname of the tone file(.wav  .au and midi only) or relative to the classes classloader.&lt;br /&gt;
&lt;br /&gt;
If you need more media types look at the JMF (Java Media Foundation) packages from sun (java.sun.com search JMF )&lt;br /&gt;
&lt;br /&gt;
Look up Roedy Green's example of tone generation by byte manipulation.&lt;br /&gt;
&lt;a href="http://mindprod.com/zips/java/sound12.zip"&gt;http://mindprod.com/zips/java/sound12.zip&lt;/a&gt;&lt;br /&gt;
&lt;a href="http://mindprod.com/zips/java/sound.txt"&gt;http://mindprod.com/zips/java/sound.txt&lt;/a&gt; // info &lt;br /&gt;
very nice, but may not be portable as-is (as it uses com.sun classes -I think)&lt;br /&gt;
but is extensible to JMF Player with some work. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
~S~&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
: thanks for the link Iceperson.&lt;br /&gt;
: I need a little more help I'm afraid.&lt;br /&gt;
: I've begun with the first programming example, and I'm trying to compile it from the command line as it says.:&lt;br /&gt;
: &lt;br /&gt;
: &lt;br /&gt;
: 1 error:&lt;br /&gt;
: C:\&amp;gt;javac -classpath c:\jfugue MyMusicApp.java&lt;br /&gt;
: MyMusicApp.java:9: cannot resolve symbol&lt;br /&gt;
: symbol : method play ()&lt;br /&gt;
: location: class org.jfugue.Pattern&lt;br /&gt;
:                                 pattern.play();&lt;br /&gt;
: 1 error&lt;br /&gt;
: &lt;br /&gt;
: and then there's a circumflex-thingy pointing at the dot of .play (which I can't find on my keyb)&lt;br /&gt;
: &lt;br /&gt;
: I believe my java is uptodate- I got the latest one from Sun a month or so ago....&lt;br /&gt;
: &lt;br /&gt;
: And I'm assuming I've done the classpath thing right as I had even more errors before (eg if I tried to javac without the jfugue classpath)..&lt;br /&gt;
: &lt;br /&gt;
: thanks for your patience&lt;br /&gt;
: &lt;br /&gt;
: Osella&lt;br /&gt;
: &lt;br /&gt;
: &lt;br /&gt;
:                                        &lt;br /&gt;
:  : is there a Java class for basic musical commands like qbasic has?&lt;br /&gt;
: : : &lt;br /&gt;
: : &lt;br /&gt;
: : &lt;a href="http://innix.com/jfugue/"&gt;http://innix.com/jfugue/&lt;/a&gt;&lt;br /&gt;
: : &lt;br /&gt;
: : Iceman&lt;br /&gt;
: : &lt;br /&gt;
: : &lt;br /&gt;
: : &lt;br /&gt;
: : Unix is user friendly. It's just very particular about who its friends are.&lt;br /&gt;
: : &lt;br /&gt;
: : &lt;br /&gt;
: &lt;br /&gt;
: &lt;br /&gt;
&lt;br /&gt;</description>
      <guid isPermaLink="true">http://www.programmersheaven.com/mb/java/210108/210315/re-tones/#210315</guid>
      <pubDate>Tue, 02 Sep 2003 11:03:59 -0700</pubDate>
      <category>Java</category>
    </item>
  </channel>
</rss>