eLynx SDK
v3.3.0 C++ image processing API reference |
Base namespace for all eLynx components. More...
Namespaces | |
namespace | Image |
Deals with pixels, images interfaces and tools classes. | |
namespace | Math |
Deals with all basic math helpers and vectorial tools classes. | |
Classes | |
struct | elxException |
Base exception class. More... | |
class | AbstractParameter |
struct | ParameterEnumItem |
class | ParameterEnum |
class | ParameterInteger |
class | ParameterDouble |
class | IterationRangeTask |
Base iteration range task. More... | |
struct | ResolutionTypeTraits |
Resolution type traits definition. More... | |
struct | ResolutionTypeTraits< uint8 > |
uint8 specialization for resolution type traits. More... | |
struct | ResolutionTypeTraits< uint16 > |
uint16 specialization for resolution type traits. More... | |
struct | ResolutionTypeTraits< int32 > |
int32 specialization for resolution type traits. More... | |
struct | ResolutionTypeTraits< uint32 > |
uint32 specialization for resolution type traits. More... | |
struct | ResolutionTypeTraits< int64 > |
int64 specialization for resolution type traits. More... | |
struct | ResolutionTypeTraits< float > |
float specialization for resolution type traits. More... | |
struct | ResolutionTypeTraits< double > |
double specialization for resolution type traits. More... | |
class | IPlugin |
Interface defining a plugin. More... | |
class | IPluginPackage |
Interface defining a plugin package. More... | |
class | IterationRange |
IterationRange represents half-open range [i,j) that can be recursively split. More... | |
class | PluginFile |
PluginFile is a handle to a IPluginPackage. More... | |
class | PluginManager |
Base tool class for plugin management. More... | |
struct | ProgramOption |
Program Option. More... | |
class | ProgressNotifier |
Abstract progress notifier class. More... | |
class | TaskScheduler |
class | Timer |
Class to get elapsed time in platform independent way. More... | |
class | UUID |
Tool class for Universal Unique IDentifier. More... | |
Typedefs | |
typedef std::vector < AbstractParameter * > | ParameterList |
typedef std::vector < ParameterEnumItem > | ParameterEnumItemList |
typedef const IPluginPackage *(* | elxGetPluginPackage )() |
Service definition that must be implemented by every plugin package file to retrieve his list of implemented plugins. | |
Enumerations | |
enum | EParameterType { PT_Boolean, PT_Enum, PT_Integer, PT_Double, PT_String, PT_StringList } |
enum | EResolution { RT_INT8, RT_UINT8, RT_INT16, RT_UINT16, RT_INT32, RT_UINT32, RT_INT64, RT_UINT64, RT_Float, RT_Double, RT_Undefined } |
Resolution types. More... | |
enum | { PDI_Name = 0, PDI_Copyright, PDI_LongDescription, PDI_VersionAndDate } |
Plugin description index. More... | |
enum | ESubRangePosition { SRP_NONE, SRP_ALL, SRP_FIRST, SRP_MIDDLE, SRP_LAST } |
Enum to specify SubRange position inside the original Iteration range. More... | |
enum | EOptionArgFlag { OA_NO_ARG = 0, OA_HAS_ARG = 1, OAF_Unset = 0, OAF_Optional = 1, OAF_Mandatory = 2 } |
Enum to specify optional and mandarory command options. | |
Functions | |
template<typename T > | |
int8 | elxToINT8 (T) |
template<typename T > | |
uint8 | elxToUINT8 (T) |
template<typename T > | |
int16 | elxToINT16 (T) |
template<typename T > | |
uint16 | elxToUINT16 (T) |
template<typename T > | |
int32 | elxToINT32 (T) |
template<typename T > | |
uint32 | elxToUINT32 (T) |
template<typename T > | |
int64 | elxToINT64 (T) |
template<typename T > | |
uint64 | elxToUINT64 (T) |
template<typename T > | |
float | elxToFloat (T) |
template<typename T > | |
double | elxToDouble (T) |
template<typename T > | |
int8 | elxToINT8Scaled (T) |
template<typename T > | |
uint8 | elxToUINT8Scaled (T) |
template<typename T > | |
int16 | elxToINT16Scaled (T) |
template<typename T > | |
uint16 | elxToUINT16Scaled (T) |
template<typename T > | |
int32 | elxToINT32Scaled (T) |
template<typename T > | |
uint32 | elxToUINT32Scaled (T) |
template<typename T > | |
int64 | elxToINT64Scaled (T) |
template<typename T > | |
uint64 | elxToUINT64Scaled (T) |
template<typename T > | |
float | elxToFloatNormalized (T) |
template<typename T > | |
double | elxToDoubleNormalized (T) |
template<typename T > | |
void | elxToDoubleNormalized (const T *, uint32 count, double *) |
template<typename T > | |
void | elxFromDouble (double iValue, T &oValue) |
template<typename T > | |
void | elxFromDoubleNormalized (double iValue, T &oValue) |
template<typename T , typename U > | |
bool | elxConvertBuffer (T *iprDst, const U *iprSrc, size_t iSize, bool ibScaled=true) |
Buffer conversion between primary types. | |
template<typename T > | |
bool | elxStringToType (const char *iprString, T &oValue) |
Conversion from a string to a number of template numerical type. | |
ExportedByCore void | elxZeroMemory (void *iprBuffer, uint32 iSize) |
Fill memory at iprBuffer with (iSize) bytes of 0x00. | |
ExportedByCore char | elxToLower (char iChar) |
Convert a char to lower case. | |
ExportedByCore char | elxToUpper (char iChar) |
Convert a char to upper case. | |
ExportedByCore void | elxToLower (char *ioprString) |
Convert a 'c' string to lower case in place. | |
ExportedByCore void | elxToUpper (char *ioprString) |
Convert a 'c' string to upper case in place. | |
ExportedByCore void | elxThrowException (uint32 iId, const char *iFile, int32 iLine, const char *iMsg) |
Creates and throws the exception given id, file name, number of line and error message. | |
ExportedByCore const char * | elxMsgFormat (const char *iFormatStr,...) |
Formats the error message in the style of printf functions. | |
ExportedByCore void | elxMakePath (const std::string &iPath) |
Make a directory. | |
ExportedByCore bool | elxIsPath (const std::string &iPath) |
Check if a path exists. | |
ExportedByCore void | elxGetFileList (const std::string &iTarget, std::vector< std::string > &oFileList) |
size_t ExportedByCore | elxGetParameterIndex (const ParameterList &iList, const std::string &iName) |
template<class T , size_t N> | |
void | elxInsertionSort (T(&ioArray)[N]) |
Insertion Sort for array of N. | |
template<class T > | |
void | elxShellSort (T *ioprArray, uint32 iSize, uint32 iMaxIncrement) |
Shell Sort for array of iSize. | |
template<class T > | |
void | elxQuickSort (T *ioprArray, uint32 iSize, int32(*iComp)(const T *, const T *)) |
On a multicore machine performs parallel Quick sort. | |
ExportedByCore const char * | elxToString (EResolution iResolution) |
Return the resolution as a string. | |
ExportedByCore EResolution | elxGetFloatingType (EResolution iResolution) |
Return the floating resolution of a resolution. | |
ExportedByCore EResolution | elxToEResolution (const char *iprType) |
Returns resolution type for a given string. | |
ExportedByCore uint32 | elxGetBits (EResolution iResolution) |
Return the number of bits for the resolution. | |
template<typename Range , typename Task > | |
uint32 | elxParallelFor (Range iRange, const Task &iTask) |
Template function to performs parallel execution of the specified task over a given range by subdividing it into subranges and applying the task to each subrange in a separate thread. | |
template<typename Range , typename Task > | |
uint32 | elxParallelReduce (Range iRange, Task &ioTask) |
Template function to perform reduction over a range (summation, for example) by subdividing it into subranges and applying the task to each subrange in a separate thread and join the results. | |
ExportedByCore uint32 | elxGetOptions (int32 iArgc, char **iArgv, ProgramOption *ioOptions, uint32 iSize) |
Function to parse input arguments. | |
File module methods. | |
ExportedByCore bool | elxLoadModule (const char *iprFilename, ModuleId &oModule) |
Load a module file (.dll, .so). | |
ExportedByCore void | elxUnloadModule (ModuleId &ioModule) |
Unload the module file from memory. | |
ExportedByCore void * | elxResolveSymbol (const ModuleId &iModule, const char *iprSymbolName) |
Resolve the symbol in a module file. | |
Path methods. | |
ExportedByCore bool | elxIsPath (const char *iprPath) |
Check if a path exists. | |
ExportedByCore bool | elxMakePath (const char *iprPath) |
Make a directory. | |
ExportedByCore bool | elxDeletePath (const char *iprPath) |
Delete a directory. | |
Filename methods. | |
ExportedByCore bool | elxSplitFilename (const char *iprFilename, char *oprPath, char *oprName, char *oprExt) |
Split filename into path, name and extension. | |
ExportedByCore void | elxSplitFilename (const std::string &iFilename, std::string &oPath, std::string &oName, std::string &oExt) |
Split filename into path, name and extension. | |
ExportedByCore bool | elxGetFilePath (const char *iprFilename, char *oprPath) |
Get the path of a filename ending with /. | |
ExportedByCore const char * | elxGetFileNameExt (const char *iprFilename) |
Get the name of a filename ie removing path and extension. | |
ExportedByCore bool | elxGetFileName (const char *iprFilename, char *oprName) |
Get the name and extension of a filename removing path. | |
ExportedByCore const char * | elxGetFileExt (const char *iprFilename) |
Get the extension of a filename. | |
ExportedByCore char * | elxGetFileExt (char *iprFilename) |
Get the extension of a filename. | |
ExportedByCore bool | elxCheckFileExt (const char *iprFilename, const char *iprExt, bool ibCase=true) |
Check if the given file extension is at the end of the filename. | |
ExportedByCore void | elxForceFilename (char *ioprFilename) |
Force full filename with OS specific separator. | |
ExportedByCore void | elxForceFilename (std::string &ioFilename) |
Force full filename with OS specific separator. | |
Variables | |
ExportedByCore ProgressNotifier | ProgressNotifier_NULL |
File methods. | |
typedef bool(* | elxFileEnumCB )(const char *iprFilename, void *iprUserData) |
Define the callback use with elxEnumerateFile. | |
ExportedByCore bool | elxIsFileExist (const char *iprFilename) |
Check if a file exist. | |
ExportedByCore bool | elxDeleteFile (const char *iprFilename) |
Delete a file. | |
ExportedByCore void | elxEnumerateFile (const char *iprTarget, elxFileEnumCB ifnCallback, void *iprUserData) |
Enumerate files that match the target. |
Base namespace for all eLynx components.
Also called 'Core'.
typedef const IPluginPackage*(* eLynx::elxGetPluginPackage)() |
Service definition that must be implemented by every plugin package file to retrieve his list of implemented plugins.
anonymous enum |
Plugin description index.
Meaning, example:
enum eLynx::EResolution |
Resolution types.
Enum to specify SubRange position inside the original Iteration range.
ExportedByCore bool eLynx::elxCheckFileExt | ( | const char * | iprFilename, |
const char * | iprExt, | ||
bool | ibCase = true |
||
) |
Check if the given file extension is at the end of the filename.
iprFilename | Reference pointer on filename. |
iprExt | Reference pointer on extension to check. |
ibCase | Set true if you want test case (default), false if case don't mind. |
bool eLynx::elxConvertBuffer | ( | T * | iprDst, |
const U * | iprSrc, | ||
size_t | iSize, | ||
bool | ibScaled = true |
||
) |
Buffer conversion between primary types.
iprDst | typed destination buffer. |
iprSrc | typed read-only source buffer. |
iSize | number of primary type to convert form source. |
ibScaled | true if conversion conserve max or Normalized, false for simple cast. |
ExportedByCore bool eLynx::elxDeleteFile | ( | const char * | iprFilename ) |
Delete a file.
iprFilename | The filename to delete. |
ExportedByCore bool eLynx::elxDeletePath | ( | const char * | iprPath ) |
Delete a directory.
iprPath | The path name to delete. |
ExportedByCore void eLynx::elxEnumerateFile | ( | const char * | iprTarget, |
elxFileEnumCB | ifnCallback, | ||
void * | iprUserData | ||
) |
Enumerate files that match the target.
Callback must return true to continue enumeration, false to stop enumeration.
iprTarget | The target file to enumerate. Ex "doc\*.htm". |
ifnCallback | The callback to call when a file is found. |
iprUserData | Datas to transmit to the callback. |
ExportedByCore void eLynx::elxForceFilename | ( | char * | ioprFilename ) |
Force full filename with OS specific separator.
ioprFilename | The filename to force. |
ExportedByCore void eLynx::elxForceFilename | ( | std::string & | ioFilename ) |
Force full filename with OS specific separator.
ioFilename | The filename to force. |
ExportedByCore uint32 eLynx::elxGetBits | ( | EResolution | iResolution ) |
Return the number of bits for the resolution.
iResolution | The requested resolution. |
ExportedByCore const char* eLynx::elxGetFileExt | ( | const char * | iprFilename ) |
Get the extension of a filename.
iprFilename | Reference pointer on filename. |
ExportedByCore char* eLynx::elxGetFileExt | ( | char * | iprFilename ) |
Get the extension of a filename.
iprFilename | Reference pointer on filename. |
ExportedByCore bool eLynx::elxGetFileName | ( | const char * | iprFilename, |
char * | oprName | ||
) |
Get the name and extension of a filename removing path.
iprFilename | Reference pointer on filename. |
oprName | Reference pointer on output name, must be allocated with elxPATH_MAX size. |
ExportedByCore const char* eLynx::elxGetFileNameExt | ( | const char * | iprFilename ) |
Get the name of a filename ie removing path and extension.
iprFilename | Reference pointer on filename. |
ExportedByCore bool eLynx::elxGetFilePath | ( | const char * | iprFilename, |
char * | oprPath | ||
) |
Get the path of a filename ending with /.
iprFilename | Reference pointer on filename. |
oprPath | Reference pointer on output path, must be allocated with elxPATH_MAX size. |
ExportedByCore EResolution eLynx::elxGetFloatingType | ( | EResolution | iResolution ) |
Return the floating resolution of a resolution.
iResolution | The requested resolution. |
ExportedByCore uint32 eLynx::elxGetOptions | ( | int32 | iArgc, |
char ** | iArgv, | ||
ProgramOption * | ioOptions, | ||
uint32 | iSize | ||
) |
Function to parse input arguments.
iArgc | number of the input arguments |
iArgv | array of input arguments |
ioOptions | array of the allowed options |
iSize | number of the allowed options |
void eLynx::elxInsertionSort | ( | T(&) | ioArray[N] ) |
Insertion Sort for array of N.
the value of N should not be very int64 <100 since the implementation uses recurcive templates technique
ExportedByCore bool eLynx::elxIsFileExist | ( | const char * | iprFilename ) |
Check if a file exist.
iprFilename | The filename to check. |
ExportedByCore bool eLynx::elxIsPath | ( | const char * | iprPath ) |
Check if a path exists.
iprPath | The path name to check. |
ExportedByCore bool eLynx::elxIsPath | ( | const std::string & | iPath ) |
Check if a path exists.
iPath | The path name to check. |
ExportedByCore bool eLynx::elxLoadModule | ( | const char * | iprFilename, |
ModuleId & | oModule | ||
) |
Load a module file (.dll, .so).
iprFilename | The module filename. |
oModule | The module id. |
ExportedByCore bool eLynx::elxMakePath | ( | const char * | iprPath ) |
Make a directory.
iprPath | The path name to make. |
ExportedByCore void eLynx::elxMakePath | ( | const std::string & | iPath ) |
Make a directory.
iPath | The path name to make. |
ExportedByCore const char* eLynx::elxMsgFormat | ( | const char * | iFormatStr, |
... | |||
) |
Formats the error message in the style of printf functions.
The length of resulting message is restricted to elxExWhatLength. Returns the formatted message. Method is not thread-safe.
iFormatStr | the format string in the printf style. |
uint32 eLynx::elxParallelFor | ( | Range | iRange, |
const Task & | iTask | ||
) |
Template function to performs parallel execution of the specified task over a given range by subdividing it into subranges and applying the task to each subrange in a separate thread.
iRange | initial range of values. |
iTask | task to execute. |
uint32 eLynx::elxParallelReduce | ( | Range | iRange, |
Task & | ioTask | ||
) |
Template function to perform reduction over a range (summation, for example) by subdividing it into subranges and applying the task to each subrange in a separate thread and join the results.
In addition to the operator()(Range) method Type Task must implement Join(Const Task& iOther) to merge the results into the original ioTask
iRange | - initial range of values. |
ioTask | - task to execute and join the results. |
void eLynx::elxQuickSort | ( | T * | ioprArray, |
uint32 | iSize, | ||
int32(*)(const T *, const T *) | iComp | ||
) |
On a multicore machine performs parallel Quick sort.
ioprArray | pointer on an array of T type. |
iSize | the array's size. |
iComp | comparison function that return an integer less than, equal to, or greater than zero if the first argument is considered to be respectively less than, equal to, or greater than the second. |
ExportedByCore void* eLynx::elxResolveSymbol | ( | const ModuleId & | iModule, |
const char * | iprSymbolName | ||
) |
Resolve the symbol in a module file.
iModule | The module file id to look for symbol. |
iprSymbolName | The symbol name to resolve. |
void eLynx::elxShellSort | ( | T * | ioprArray, |
uint32 | iSize, | ||
uint32 | iMaxIncrement | ||
) |
Shell Sort for array of iSize.
The increment sequence is h=3*h+1(1,4,13,...)
ioprArray | pointer on an array of T type. |
iSize | Number of items to sort in array. |
iMaxIncrement | The increment max. |
ExportedByCore bool eLynx::elxSplitFilename | ( | const char * | iprFilename, |
char * | oprPath, | ||
char * | oprName, | ||
char * | oprExt | ||
) |
Split filename into path, name and extension.
iprFilename | Reference pointer on filename to split. |
oprPath | Reference pointer on output path, must be allocated with elxPATH_MAX size. |
oprName | Reference pointer on output name, must be allocated with elxPATH_MAX size. |
oprExt | Reference pointer on output extension, must be allocated with elxPATH_MAX size. |
ExportedByCore void eLynx::elxSplitFilename | ( | const std::string & | iFilename, |
std::string & | oPath, | ||
std::string & | oName, | ||
std::string & | oExt | ||
) |
Split filename into path, name and extension.
iFilename | filename to split. |
oPath | output path. |
oName | output name. |
oExt | output extension. |
bool eLynx::elxStringToType | ( | const char * | iprString, |
T & | oValue | ||
) |
Conversion from a string to a number of template numerical type.
iprString | the string to convert to number. |
oValue | the ouput value decoded from the string. |
ExportedByCore void eLynx::elxThrowException | ( | uint32 | iId, |
const char * | iFile, | ||
int32 | iLine, | ||
const char * | iMsg | ||
) |
Creates and throws the exception given id, file name, number of line and error message.
iId | the id of the error. |
iFile | the name of the file (module) where the error appeared. |
iLine | the number of the line where the error appeared. |
iMsg | the error message. If longer than elxExWhatLength, the message. will be truncated. |
ExportedByCore EResolution eLynx::elxToEResolution | ( | const char * | iprType ) |
Returns resolution type for a given string.
iprType | The requested resolution as a string. |
ExportedByCore char eLynx::elxToLower | ( | char | iChar ) |
Convert a char to lower case.
iChar | char to convert. |
ExportedByCore void eLynx::elxToLower | ( | char * | ioprString ) |
Convert a 'c' string to lower case in place.
ioprString | The string to convert. |
ExportedByCore const char* eLynx::elxToString | ( | EResolution | iResolution ) |
Return the resolution as a string.
iResolution | The requested resolution. |
ExportedByCore void eLynx::elxToUpper | ( | char * | ioprString ) |
Convert a 'c' string to upper case in place.
ioprString | The string to convert. |
ExportedByCore char eLynx::elxToUpper | ( | char | iChar ) |
Convert a char to upper case.
iChar | char to convert. |
ExportedByCore void eLynx::elxUnloadModule | ( | ModuleId & | ioModule ) |
Unload the module file from memory.
ioModule | The module file id to unload, set to 0 if when succeeded. |
ExportedByCore void eLynx::elxZeroMemory | ( | void * | iprBuffer, |
uint32 | iSize | ||
) |
Fill memory at iprBuffer with (iSize) bytes of 0x00.
iprBuffer | Pointer on start memory adress to reset. |
iSize | Size in bytes to be set to 0x00. |