Пример #1
0
void LSHReservoirSampler::restart(LSH *hashFamIn, unsigned int numHashPerFamily, unsigned int numHashFamilies,
	unsigned int reservoirSize, unsigned int dimension, unsigned int numSecHash, unsigned int maxSamples,
	unsigned int queryProbes, unsigned int hashingProbes, float tableAllocFraction) {
	unInit();
	initVariables(numHashPerFamily, numHashFamilies, reservoirSize, dimension, numSecHash, maxSamples, queryProbes,
		hashingProbes, tableAllocFraction);
	_hashFamily = hashFamIn;
	initHelper(_numTables, _rangePow, _reservoirSize);
}
Пример #2
0
void SPxSolver::loadBasis(const SPxBasis::Desc& p_desc)
{
   METHOD( "SPxSolver::loadBasis()" );
   unInit();
   if (SPxBasis::status() == SPxBasis::NO_PROBLEM)
      SPxBasis::load(this);
   SPxBasis::loadDesc(p_desc);
   setBasisStatus(SPxBasis::REGULAR);
}
Пример #3
0
Character& Character::operator=(const Character& other)
{
	if(this != &other)
	{
		unInit();
		initFromOtherCharacter(other);
	}

	return *this;
}
Пример #4
0
void SPxSolver::reLoad()
{
   METHOD( "SPxSolver::reLoad()" );
   unInit();
   unLoad();
   theLP = this;
   if (thepricer)
      thepricer->clear();
   if (theratiotester)
      theratiotester->clear();
}
Пример #5
0
/*! The scene init is called whenever the scene is new loaded.
*/
void SLScene::init()
{  
   current = this;
   
   unInit();
   
   _backColor.set(0.1f,0.4f,0.8f,1.0f);
   _globalAmbiLight.set(0.2f,0.2f,0.2f,0.0f);
   _selectedShape = 0;

   _timer.start();
}
Пример #6
0
void SPxSolver::setType(Type tp)
{
   METHOD( "SPxSolver::setType()" );

   if (theType != tp)
   {
      theType = tp;

      unInit();
#if 0
      else
      {
      if (!matrixIsSetup)
Пример #7
0
void SPxSolver::loadLP(const SPxLP& lp)
{
   METHOD( "SPxSolver::loadLP()" );
   clear();
   unInit();
   unLoad();
   if (thepricer)
      thepricer->clear();
   if (theratiotester)
      theratiotester->clear();
   SPxLP::operator=(lp);
   reDim();
   SPxBasis::load(this);
}
Пример #8
0
/*! The destructor does the final total deallocation of all global resources.
*/
SLScene::~SLScene()
{
   unInit();
   
   // delete global SLGLState instance
   SLGLState::deleteInstance();

   // clear light pointers
   _lights.clear();
   
   // delete materials 
   for (SLuint i=0; i<_materials.size(); ++i) delete _materials[i];
   _materials.clear();
   
   // delete textures
   for (SLuint i=0; i<_textures.size(); ++i) delete _textures[i];
   _textures.clear();
   
   // delete shader programs
   for (SLuint i=0; i<_shaderProgs.size(); ++i) delete _shaderProgs[i];
   _shaderProgs.clear();
   
   // delete fonts   
   SLTexFont::deleteFonts();
   
   // delete menus & statistic texts
   delete _menuGL;      _menuGL     = 0;
   delete _menuRT;      _menuRT     = 0;
   delete _menuPT;      _menuPT     = 0;
   delete _info;        _info       = 0;
   delete _infoGL;      _infoGL     = 0;
   delete _infoRT;      _infoRT     = 0;
   delete _btnAbout;    _btnAbout   = 0;
   delete _btnHelp;     _btnHelp    = 0;
   delete _btnCredits;  _btnCredits = 0;
   
   current = 0;

   SL_LOG("~SLScene\n");
   SL_LOG("------------------------------------------------------------------\n");
}
Пример #9
0
LSHReservoirSampler::~LSHReservoirSampler() {
	clFlush(command_queue_gpu);
	clFinish(command_queue_gpu);
	clReleaseProgram(program_gpu);
	clReleaseCommandQueue(command_queue_gpu);
	clReleaseContext(context_gpu);
	free(devices_gpu);

	//clFlush(command_queue_cpu);
	//clFinish(command_queue_cpu);
	//clReleaseProgram(program_cpu);
	//clReleaseCommandQueue(command_queue_cpu);
	//clReleaseContext(context_cpu);
	//free(devices_cpu);

	free(platforms);
	
	clReleaseKernel(kernel_reservoir);
	clReleaseKernel(kernel_addtable);
	clReleaseKernel(kernel_extract_rows);
	clReleaseKernel(kernel_taketopk);
	clReleaseKernel(kernel_bsort_preprocess);
	clReleaseKernel(kernel_bsort_postprocess);
	clReleaseKernel(kernel_bsort_init_manning);
	clReleaseKernel(kernel_bsort_stage_0_manning);
	clReleaseKernel(kernel_bsort_stage_n_manning);
	clReleaseKernel(kernel_bsort_stage_0_manning_kv);
	clReleaseKernel(kernel_bsort_stage_n_manning_kv);
	clReleaseKernel(kernel_bsort_init_manning_kv);

	clReleaseKernel(kernel_markdiff);
	clReleaseKernel(kernel_aggdiff);
	clReleaseKernel(kernel_subtractdiff);
	clReleaseKernel(kernel_tally_naive);

	unInit();
}
Пример #10
0
SpecialPush::~SpecialPush()
{
    unInit();
}
Пример #11
0
KComboEdit::~KComboEdit(void)
{
    unInit();
}
Пример #12
0
WorkerPool::~WorkerPool()
{
    unInit();
}
Пример #13
0
//////////////////////////////////////////////////////////////////////////////
//
// DESTRUCTOR
//
//////////////////////////////////////////////////////////////////////////////
CSparkles::~CSparkles()
{
	unInit();
}
Пример #14
0
//////////////////////////////////////////////////////////////////////////////
//
// DESTRUCTOR
//
//////////////////////////////////////////////////////////////////////////////
CComaLogo::~CComaLogo()
{
	unInit();
}
Пример #15
0
Character::~Character()
{
	unInit();
}
Пример #16
0
	~Log()
	{
		unInit();
	}