psdpng.c File Reference

#include <stdlib.h>
#include <math.h>
#include <stdio.h>
#include <string.h>
#include <unistd.h>
#include <png.h>
#include "kiss_fft.h"
#include "kiss_fftr.h"

Classes

struct  rgb_t

Defines

#define CHECKNULL(p)   if ( (p)==NULL ) do { fprintf(stderr,"CHECKNULL failed @ %s(%d): %s\n",__FILE__,__LINE__,#p );exit(1);} while(0)

Functions

static void config (int argc, char **argv)
static void val2rgb (float x, rgb_t *p)
static void cpx2pixels (rgb_t *res, const float *fbuf, size_t n)
static void transform_signal (void)
static void make_png (void)
int main (int argc, char **argv)

Variables

int nfft = 1024
FILE * fin = NULL
FILE * fout = NULL
int navg = 20
int remove_dc = 0
int nrows = 0
float * vals = NULL
int stereo = 0

Define Documentation

#define CHECKNULL (  )     if ( (p)==NULL ) do { fprintf(stderr,"CHECKNULL failed @ %s(%d): %s\n",__FILE__,__LINE__,#p );exit(1);} while(0)

Referenced by make_png(), and transform_signal().


Function Documentation

static void config ( int  argc,
char **  argv 
) [static]

References fin, fout, navg, nfft, remove_dc, and stereo.

Referenced by main().

static void val2rgb ( float  x,
rgb_t p 
) [static]

References rgb_t::b, rgb_t::g, testkiss::pi, and rgb_t::r.

Referenced by cpx2pixels().

static void cpx2pixels ( rgb_t res,
const float *  fbuf,
size_t  n 
) [static]

References val2rgb().

Referenced by make_png().

static void transform_signal ( void   )  [static]

static void make_png ( void   )  [static]

References CHECKNULL, cpx2pixels(), fout, nfft, nrows, and vals.

Referenced by main().

int main ( int  argc,
char **  argv 
)


Variable Documentation

int nfft = 1024

FILE* fin = NULL

Referenced by config(), main(), and transform_signal().

FILE* fout = NULL

Referenced by config(), main(), and make_png().

int navg = 20

Referenced by config(), and transform_signal().

int remove_dc = 0

Referenced by config(), and transform_signal().

int nrows = 0

Referenced by make_png(), and transform_signal().

float* vals = NULL

Referenced by make_png(), and transform_signal().

int stereo = 0

Referenced by config(), and transform_signal().


Generated on Thu Sep 17 23:14:16 2009 for CSL by  doxygen 1.5.8