[Search for users] [Overall Top Noters] [List of all Conferences] [Download this site]

Conference 7.286::atarist

Title:Atari ST, TT, & Falcon
Notice:Please read note 1.0 and its replies before posting!
Moderator:FUNYET::ANDERSON
Created:Mon Apr 04 1988
Last Modified:Tue May 06 1997
Last Successful Update:Fri Jun 06 1997
Number of topics:1433
Total number of notes:10312

337.0. "Wave in GFA Basic" by DISCVR::FISTER () Mon Dec 12 1988 12:03

    
    	I was doing some programming this weekend, and I found out that
    my GFA Basic manual is missing a page. Of course, it's the page
    for the command I need.
    	Anyone out there know the commands for WAVE? I have no idea
    what they are, 'tho I think they are the old ADSR.
    
    				Thankz,
    				  Les
    
T.RTitleUserPersonal
Name
DateLines
337.1Here's the documentationTEA::PETERSDon Peters, CTS1-2/H6, 287-3742Wed Dec 14 1988 17:5861
Command WAVE

How: WAVE voc,env,form,len,dur

Abbr.: WA

Example:   SOUND 1,15,1,4,20
           SOUND 2,15,4,4,20
           SOUND 3,15,8,4,20
           WAVE 7,7,0,65535,300
           WAVE 0,0

Purpose: Produces noises from the three sound channels.

Explanation: "voc","end","form","len", and "dur" are integer expressions

"voc" determines which of the sound channels will be
active.  It is treated "bit-wise" with the bit-values for the
three channels added as follows:

      1 = Channel 1
      2 = Channel 2
      4 = Channel 3
      8 = Noise on channel 1
     16 = Noise on channel 2
     32 = Noise on channel 3

256 times the period of the noise generator (0 to 31) can also be
added to this.

"env" defines the channels for which the envelope is to be
active.  It is also treated bit-wise, with the values of the
three channels added as follows:

      1 = channel 1
      2 = channel 2
      4 = channel 3

"form" specifies the shape of the envelope:

  \__  0-3 = linear falling
  /|__ 4-7 = linear rising terminating
  \|\|\ 8 = sawtooth falling
  \___  9 = linear falling (as in 0-3)
  \/\/  10 = peaked begin falling
  \|--- 11 = linear falling var.loudness
  /|/|  12 = sawtooth rising
  /---- 13 = linear rising continuous
  /\/\  14 = peaked begin rising
  /|__  15 = linear rising (as in 4-7)

"len" specifies the period of the envolope (length of time
over which the envelope is played).

"dur" is the time, measured in 1/50ths of a second, before
execution of the next command.

Parameters which are located at the end of the command
and are to remain unchanged can be omitted.

WAVE 0,0 switches off all sound channels.