Dev /

VectorTypes

CardioWave provides several vector types for byte, integer, and real values. They are all based on similar C structures:

  typedef struct {
	int   size;
	real* data;
	domain_t dtype;
  } vector;
  typedef struct {
	int  size;
	int* data;
	domain_t dtype;
  } ivector;
  typedef struct {
	int   size;
	byte* data;
	domain_t dtype;
  } bvector;

To initialize any vector type, you should use the _INIT_VECTOR macro:

  #define _INIT_VECTOR {0,NULL,-1}

and use it when you declare any vector type:

     vector Vm = _INIT_VECTOR;
Edit - History - Print - Recent Changes - Search
Page last modified on June 05, 2007, at 12:14 PM