~ubuntu-branches/debian/jessie/acfax/jessie

« back to all changes in this revision

Viewing changes to mod_demod.c

  • Committer: Bazaar Package Importer
  • Author(s): Hamish Moffatt
  • Date: 2001-12-27 12:07:46 UTC
  • Revision ID: james.westby@ubuntu.com-20011227120746-l72xpm5hcde2sa2s
Tags: 981011-7
Changed Imakefile to use ComplexProgramTargetNoMan rather
than ComplexProgramTarget (closes: #123696)

Show diffs side-by-side

added added

removed removed

Lines of Context:
99
99
  }
100
100
  fmphsinc = (int *)malloc(258*sizeof(int));
101
101
  for (i=0; i<1024; i++)
102
 
    sintab[i] = 127.5 + 127*sin(i*PI/512.0); 
 
102
    sintab[i] = 127.5 + 127*sin(i*M_PI/512.0); 
103
103
 
104
104
  inited = -1;
105
105
}
120
120
  if (devi > 1200) devi = 1200;
121
121
  if (maxval < 1) maxval = 1;
122
122
  if (maxval > 255) maxval = 255;
123
 
  phmax = 255.9 * sin(devi * PI / 4000.0) + 0.5;
 
123
  phmax = 255.9 * sin(devi * M_PI / 4000.0) + 0.5;
124
124
  for (i=0; i<512; i++) {
125
125
    if (i <= 256-phmax)
126
126
      asntab[i] = 0;
127
127
    else if (i >= 256+phmax)
128
128
      asntab[i] = maxval;
129
129
    else
130
 
      asntab[i] = maxval * 2000 / devi * asin((i-256.0)/256.5) / PI
 
130
      asntab[i] = maxval * 2000 / devi * asin((i-256.0)/256.5) / M_PI
131
131
                + maxval/ 2;
132
132
  }
133
133
  for (i=0; i<2048; i++) {