ReactOS  0.4.11-dev-721-g95bc44e
Uarray Class Reference

#include <uarray.h>

Public Member Functions

 Uarray ()
 
 ~Uarray ()
 
long init (REAL, Arc_ptr, Arc_ptr)
 

Public Attributes

REALuarray
 

Private Attributes

long size
 
long ulines
 

Detailed Description

Definition at line 44 of file uarray.h.

Constructor & Destructor Documentation

Uarray::Uarray ( void  )

Definition at line 46 of file uarray.cc.

47 {
48  uarray = 0;
49  size = 0;
50  ulines = 0;
51 }
long ulines
Definition: uarray.h:47
GLsizeiptr size
Definition: glext.h:5919
REAL * uarray
Definition: uarray.h:52
Uarray::~Uarray ( void  )

Definition at line 53 of file uarray.cc.

54 {
55  if( uarray ) delete[] uarray;
56 }
REAL * uarray
Definition: uarray.h:52

Member Function Documentation

long Uarray::init ( REAL  delta,
Arc_ptr  lo,
Arc_ptr  hi 
)

Definition at line 59 of file uarray.cc.

Referenced by Slicer::slice_old().

60 {
61  ulines = (long) ((hi->tail()[0] - lo->tail()[0])/delta) + 3;
62  if( size < ulines ) {
63  size = ulines * 2;
64  if( uarray ) delete[] uarray;
65  uarray = new REAL[size];
66  assert( uarray != 0);
67  }
68  uarray[0] = lo->tail()[0] - delta/2.0;
69  for( long i = 1 ; i != ulines; i++ )
70  uarray[i] = uarray[0] + i*delta;
71  return ulines;
72 }
#define assert(x)
Definition: debug.h:53
long ulines
Definition: uarray.h:47
GLenum GLclampf GLint i
Definition: glfuncs.h:14
GLsizeiptr size
Definition: glext.h:5919
REAL * uarray
Definition: uarray.h:52
unsigned long
Definition: typeof.h:99
float REAL
Definition: types.h:41
long size
Definition: uarray.h:46

Member Data Documentation

long Uarray::size
private

Definition at line 46 of file uarray.h.

Referenced by init().

long Uarray::ulines
private

Definition at line 47 of file uarray.h.

Referenced by init(), and Uarray().


The documentation for this class was generated from the following files: