BRL-CAD
bn_list.c File Reference
#include "common.h"
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include "bn.h"
#include "bu.h"
#include "plot3.h"
Include dependency graph for bn_list.c:

Go to the source code of this file.

Macros

#define BUFFER_SIZE   2000
 
#define MAX_POINTS   30
 

Functions

FILE * initialise_buffers (char *expected_buf)
 
int compare_result (char *expected_buf, FILE *result_fd)
 
int check_result_len (FILE *result_fd)
 
void convert_points (double *d_values, int *i_values, int count)
 
void make_tp_i2list_expected (char *buf, int buflen, int *x, int *y, int npoints)
 
int test_tp_i2list (int *x, int *y, int npoints)
 
void make_tp_2list_expected (char *buf, int buflen, double *x, double *y, int npoints)
 
int test_tp_2list (double *x, double *y, int npoints)
 
int test_tp_2mlist (double *x, double *y, int npoints)
 
void make_tp_3list_expected (char *buf, int buflen, double *x, double *y, double *z, int npoints)
 
int test_tp_3list (double *x, double *y, double *z, int npoints)
 
int automatic_2d_test (double *double_x, double *double_y, int npoints)
 
int automatic_3d_test (double *double_x, double *double_y, double *double_z, int npoints)
 
int main (int argc, char *argv[])
 

Macro Definition Documentation

#define BUFFER_SIZE   2000
#define MAX_POINTS   30

Definition at line 32 of file bn_list.c.

Referenced by automatic_2d_test(), and main().

Function Documentation

FILE* initialise_buffers ( char *  expected_buf)

Definition at line 40 of file bn_list.c.

References bu_temp_file(), BUFFER_SIZE, and memset().

Referenced by test_tp_2list(), test_tp_2mlist(), test_tp_3list(), and test_tp_i2list().

Here is the call graph for this function:

int compare_result ( char *  expected_buf,
FILE *  result_fd 
)

Definition at line 59 of file bn_list.c.

References bu_strncmp(), BUFFER_SIZE, and memset().

Referenced by test_tp_2list(), test_tp_3list(), and test_tp_i2list().

Here is the call graph for this function:

int check_result_len ( FILE *  result_fd)

Definition at line 77 of file bn_list.c.

References BUFFER_SIZE, and memset().

Referenced by test_tp_2mlist().

Here is the call graph for this function:

void convert_points ( double *  d_values,
int *  i_values,
int  count 
)

Definition at line 94 of file bn_list.c.

Referenced by automatic_2d_test().

void make_tp_i2list_expected ( char *  buf,
int  buflen,
int *  x,
int *  y,
int  npoints 
)

Definition at line 108 of file bn_list.c.

Referenced by test_tp_i2list().

int test_tp_i2list ( int *  x,
int *  y,
int  npoints 
)

Definition at line 128 of file bn_list.c.

References BUFFER_SIZE, compare_result(), initialise_buffers(), make_tp_i2list_expected(), pl_setOutputMode(), and tp_i2list().

Referenced by automatic_2d_test().

Here is the call graph for this function:

void make_tp_2list_expected ( char *  buf,
int  buflen,
double *  x,
double *  y,
int  npoints 
)

Definition at line 152 of file bn_list.c.

Referenced by test_tp_2list().

int test_tp_2list ( double *  x,
double *  y,
int  npoints 
)

Definition at line 172 of file bn_list.c.

References BUFFER_SIZE, compare_result(), initialise_buffers(), make_tp_2list_expected(), pl_setOutputMode(), and tp_2list().

Referenced by automatic_2d_test().

Here is the call graph for this function:

int test_tp_2mlist ( double *  x,
double *  y,
int  npoints 
)

Definition at line 197 of file bn_list.c.

References check_result_len(), initialise_buffers(), pl_setOutputMode(), and tp_2mlist().

Referenced by automatic_2d_test().

Here is the call graph for this function:

void make_tp_3list_expected ( char *  buf,
int  buflen,
double *  x,
double *  y,
double *  z,
int  npoints 
)

Definition at line 290 of file bn_list.c.

Referenced by test_tp_3list().

int test_tp_3list ( double *  x,
double *  y,
double *  z,
int  npoints 
)

Definition at line 310 of file bn_list.c.

References BUFFER_SIZE, compare_result(), initialise_buffers(), make_tp_3list_expected(), pl_setOutputMode(), and tp_3list().

Referenced by automatic_3d_test().

Here is the call graph for this function:

int automatic_2d_test ( double *  double_x,
double *  double_y,
int  npoints 
)

Definition at line 336 of file bn_list.c.

References convert_points(), MAX_POINTS, test_tp_2list(), test_tp_2mlist(), and test_tp_i2list().

Referenced by main().

Here is the call graph for this function:

int automatic_3d_test ( double *  double_x,
double *  double_y,
double *  double_z,
int  npoints 
)

Definition at line 361 of file bn_list.c.

References test_tp_3list().

Referenced by main().

Here is the call graph for this function:

int main ( int  argc,
char *  argv[] 
)

Definition at line 373 of file bn_list.c.

References automatic_2d_test(), automatic_3d_test(), and MAX_POINTS.

Here is the call graph for this function: