Developer Documentation |
RAVL, Recognition And Vision Library |
USER | HOME PAGE | CLASS LIST | CONTENTS |
Ravl - Core - IO - Formats - TypeConverterBodyC |
PUBLIC |
TypeConverterBodyC::TypeConverterBodyC(void) TypeConverterBodyC::FindConversion(const type_info &,const type_info &,RealT &) TypeConverterBodyC::FindConversion(const type_info &,const type_info &) TypeConverterBodyC::CanConvert(const type_info &,const type_info &) TypeConverterBodyC::DoConvertion(const RCAbstractC &,const type_info &,const type_info &) TypeConverterBodyC::Insert(DPConverterBaseC &) TypeConverterBodyC::Remove(DPConverterBaseC &) TypeConverterBodyC::Graph(void) TypeConverterBodyC::EdgeEval(const DPConverterBaseC &) TypeConverterBodyC::ConvGraph(void) TypeConverterBodyC::NodeTab(void) TypeConverterBodyC::GetTypeNode(const type_info &) RCBodyVC::Save(ostream &) const RCBodyVC::Save(BinOStreamC &) const RCBodyVC::Copy(void) const RCBodyVC::DeepCopy(UIntT) const RCBodyC::References(void) const RCBodyC::Copy(void) const RCBodyC::DeepCopy(UIntT) const RCBodyC::IncRefCounter(void) RCBodyC::DecRefCounter(void) |
TypeConverterBodyC | |
Type converter body. | |
include | "Ravl/DP/TypeConverter.hh" |
Source file: | Ravl/Core/IO/TypeConverter.hh |
User Level: | Develop |
Library: | RavlIO |
In Scope: | RavlN |
It holds the set of available conversions as a graph, and searches for the least cost path between two nodes (c++ types) in the graph.
The cost function attempts to minimise the sum of the data data losses, the costs a represented as ratio of bits of information given to those sent out. e.g. The cost of converting a (32 bit) int into a char is 4 32/8. Strictly speaking the losses should be multiplied, but this gives no preference to shorter conversion paths, so I've chosen to simply add them. If someone comes up with a single example where this crude approximation causes problems I'll put together a more sophisticated scheme, until then it will do.
Parent Classes:
#include "Ravl/RCHandleV.hh" |
#include "Ravl/RefCounter.hh" |
Maintainer:Charles Galambos, Documentation by CxxDoc: Tue Aug 13 09:59:30 2002 |