xyz_iv.C File Reference

Create OpenInventor models to display XYZ points. More...

#include <cassert>
#include <cstdlib>
#include <cstdio>
#include <iostream>
#include <iomanip>
#include <fstream>
#include <string>
#include <vector>
#include "xyz_iv_cmd.h"
#include "debug.H"

Functions

bool LoadData (const string filename, vector< float > &x, vector< float > &y, vector< float > &z)
 load ascii whitespace delimited text xyz into vectors.
bool Color (ofstream &o, const string &color_str)
bool Boxes (ofstream &o, const vector< float > &x, const vector< float > &y, const vector< float > &z, const float w)
 Write out a small box at each point.
bool Spheres (ofstream &o, const vector< float > &x, const vector< float > &y, const vector< float > &z, const float r)
 Write out a small sphere at each point.
bool Linked (ofstream &o, const vector< float > &x, const vector< float > &y, const vector< float > &z)
 Use SoLineSet to connect the dots.
bool PolarLines (ofstream &o, const vector< float > &x, const vector< float > &y, const vector< float > &z)
 Use SoLineSet to connect the dots.
int main (int argc, char *argv[])

Variables

int debug_level = 0
 The main program needs to define this as a non-extern.
static const UNUSED char * RCSid = "$Id: xyz_iv.C,v 1.7 2004/11/03 00:42:36 schwehr Exp $"
 Let the debugger find out which version is being used.


Detailed Description

Create OpenInventor models to display XYZ points.


Function Documentation

bool Boxes ofstream &  o,
const vector< float > &  x,
const vector< float > &  y,
const vector< float > &  z,
const float  w
 

Write out a small box at each point.

Parameters:
o Write the Inventor model info to this stream
x,y,z Float vectors with the point data
w Width, Height and Depth for the cube
Returns:
false if there was trouble

bool Color ofstream &  o,
const string &  color_str
 

bool Linked ofstream &  o,
const vector< float > &  x,
const vector< float > &  y,
const vector< float > &  z
 

Use SoLineSet to connect the dots.

bool LoadData const string  filename,
vector< float > &  x,
vector< float > &  y,
vector< float > &  z
 

load ascii whitespace delimited text xyz into vectors.

Returns:
true if all went well. false if trouble of any kind
Parameters:
filename File to open and read data from
x,y,z Return the xyz coordinates of each point
Unlike Lisa's code, this one does NOT alter the sigmas on loading which is what the adread subroutine did.` You must call SiteSigma if doing a Site based Parametric Bootstrap

int main int  argc,
char *  argv[]
 

bool PolarLines ofstream &  o,
const vector< float > &  x,
const vector< float > &  y,
const vector< float > &  z
 

Use SoLineSet to connect the dots.

bool Spheres ofstream &  o,
const vector< float > &  x,
const vector< float > &  y,
const vector< float > &  z,
const float  r
 

Write out a small sphere at each point.

Parameters:
o Write the Inventor model info to this stream
x,y,z Float vectors with the point data
r Radius of the spheres
Returns:
false if there was trouble
You may want to add an SoComplexity node in front of the spheres. If rendering is too slow.

Complexity { value .10 }


Variable Documentation

int debug_level = 0
 

The main program needs to define this as a non-extern.

const UNUSED char* RCSid = "$Id: xyz_iv.C,v 1.7 2004/11/03 00:42:36 schwehr Exp $" [static]
 

Let the debugger find out which version is being used.


Generated on Thu Mar 2 17:55:25 2006 for density by  doxygen 1.4.6