Beispiel #1
0
 void Aligner::deserialize(boss::ObjectData &data, boss::IdContext &context) {
   boss::Identifiable::deserialize(data, context);
   setOuterIterations(data.getInt("outerIterations"));
   setInnerIterations(data.getInt("innerIterations"));
   Vector6f v;
   v.fromBOSS(data, "referenceSensorOffset");
   _referenceSensorOffset = v2t(v);
   v.fromBOSS(data, "currentSensorOffset");
   _currentSensorOffset = v2t(v);
   data.getReference("projector").bind(_projector);
   data.getReference("linearizer").bind(_linearizer);
   data.getReference("correspondenceFinder").bind(_correspondenceFinder);
 }
Beispiel #2
0
 void Aligner::serialize(boss::ObjectData &data, boss::IdContext &context) {
   boss::Identifiable::serialize(data, context);
   data.setInt("outerIterations", outerIterations());
   data.setInt("innerIterations", innerIterations());
   t2v(_referenceSensorOffset).toBOSS(data, "referenceSensorOffset");
   t2v(_currentSensorOffset).toBOSS(data, "currentSensorOffset");
   PointProjector *projector = dynamic_cast<PointProjector*>(_projector);
   if(!projector) {
     throw std::runtime_error("Impossible to convert pwn::PointProjector to pwn_boss::PointProjector");
   }
   data.setPointer("projector", projector);
   Linearizer *linearizer = dynamic_cast<Linearizer*>(_linearizer);
   if(!linearizer) {
     throw std::runtime_error("Impossible to convert pwn::Linearizer to pwn_boss::Linearizer");
   }
   data.setPointer("linearizer", linearizer);
   CorrespondenceFinder *correspondenceFinder = dynamic_cast<CorrespondenceFinder*>(_correspondenceFinder);
   if(!correspondenceFinder) {
     throw std::runtime_error("Impossible to convert pwn::CorrespondenceFinder to pwn_boss::CorrespondenceFinder");
   }
   data.setPointer("correspondenceFinder", correspondenceFinder);
 }
 void OptimizerProcessor::deserialize(boss::ObjectData& data, boss::IdContext& context){
   StreamProcessor::deserialize(data,context);
   data.getReference("manager").bind(_manager);
   data.getReference("optimizer").bind(_optimizer);
 }
 void OptimizerProcessor::serialize(boss::ObjectData& data, boss::IdContext& context){
   StreamProcessor::serialize(data,context);
   data.setPointer("manager", _manager);
   data.setPointer("optimizer", _optimizer);
 }
Beispiel #5
0
	void MapMerger::deserialize(boss::ObjectData& data, boss::IdContext& context){
		StreamProcessor::deserialize(data,context);
		data.getReference("manager").bind(_manager);
		 _listSize = data.getInt("listSize");
	}
Beispiel #6
0
	void MapMerger::serialize(boss::ObjectData& data, boss::IdContext& context){
		StreamProcessor::serialize(data, context);
		data.setPointer("manager", _manager);
		data.setInt("listSize", _listSize);
	}