FreeWRL / FreeX3D 4.3.0
Pool Class Reference

Public Member Functions

 Pool (int, int, const char *)
 
void * new_buffer (void)
 
void free_buffer (void *)
 
void clear (void)
 

Protected Types

enum  Magic { is_allocated = 0xf3a1 , is_free = 0xf1a2 }
 

Protected Attributes

Bufferfreelist
 
char * blocklist [NBLOCKS]
 
int nextblock
 
char * curblock
 
int buffersize
 
int nextsize
 
int nextfree
 
int initsize
 
const char * name
 
Magic magic
 

Detailed Description

Definition at line 50 of file bufpool.h.

Member Enumeration Documentation

◆ Magic

enum Pool::Magic
protected

Definition at line 70 of file bufpool.h.

Constructor & Destructor Documentation

◆ Pool()

Pool::Pool ( int _buffersize,
int initpoolsize,
const char * n )

Definition at line 49 of file bufpool.cc.

◆ ~Pool()

Pool::~Pool ( void )

Definition at line 70 of file bufpool.cc.

Member Function Documentation

◆ clear()

void Pool::clear ( void )

Definition at line 97 of file bufpool.cc.

◆ free_buffer()

void Pool::free_buffer ( void * b)
inline

Definition at line 81 of file bufpool.h.

◆ new_buffer()

void * Pool::new_buffer ( void )
inline

Definition at line 98 of file bufpool.h.

Field Documentation

◆ blocklist

char* Pool::blocklist[NBLOCKS]
protected

Definition at line 63 of file bufpool.h.

◆ buffersize

int Pool::buffersize
protected

Definition at line 66 of file bufpool.h.

◆ curblock

char* Pool::curblock
protected

Definition at line 65 of file bufpool.h.

◆ freelist

Buffer* Pool::freelist
protected

Definition at line 62 of file bufpool.h.

◆ initsize

int Pool::initsize
protected

Definition at line 69 of file bufpool.h.

◆ magic

Magic Pool::magic
protected

Definition at line 72 of file bufpool.h.

◆ name

const char* Pool::name
protected

Definition at line 71 of file bufpool.h.

◆ nextblock

int Pool::nextblock
protected

Definition at line 64 of file bufpool.h.

◆ nextfree

int Pool::nextfree
protected

Definition at line 68 of file bufpool.h.

◆ nextsize

int Pool::nextsize
protected

Definition at line 67 of file bufpool.h.


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