pkgsrc/audio/xanalyser/patches/patch-aa
schmonz 883c1cbfb0 Import xanalyser-1.21. Patches and approval by garbled.
The frequency analyser showes the frequency spectrum of the source,
either separately for both channels or together.   Roughly speaking
the XY scope draws a plots where the left channel is used for the
x axis and the right channel for the y axis. Thus a audio signal
only present on the left channel produces a horizontal line, whereas
a audio signal only present on the right channel produces a vertical
line.  Can be used as a PC-Based RTA.
2002-04-23 03:33:26 +00:00

22 lines
557 B
Text

$NetBSD: patch-aa,v 1.1.1.1 2002/04/23 03:33:26 schmonz Exp $
--- src/Analyser.cc.orig Wed Dec 12 16:41:57 2001
+++ src/Analyser.cc
@@ -8,7 +8,7 @@
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
-#include <values.h>
+#include <limits.h>
#include <assert.h>
#include <X11/Xlib.h>
@@ -559,7 +559,7 @@
void
Analyser::snd2u (const int32_t* buffer, int channel)
{
- const double norm = (channel == MONO ? 0.5 : 1.0) / (double) MAXINT;
+ const double norm = (channel == MONO ? 0.5 : 1.0) / (double) INT_MAX;
switch (channel) {