aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common')
-rw-r--r--src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/.prev_CMakeLists.txt65
-rw-r--r--src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/CMakeLists.txt65
-rw-r--r--src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/LTKCaptureDevice.cpp556
-rw-r--r--src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/LTKChannel.cpp362
-rw-r--r--src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/LTKException.cpp154
-rw-r--r--src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/LTKScreenContext.cpp441
-rw-r--r--src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/LTKTrace.cpp730
-rw-r--r--src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/LTKTraceFormat.cpp418
-rw-r--r--src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/LTKTraceGroup.cpp1134
-rw-r--r--src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/common.pro16
10 files changed, 0 insertions, 3941 deletions
diff --git a/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/.prev_CMakeLists.txt b/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/.prev_CMakeLists.txt
deleted file mode 100644
index d27cc166..00000000
--- a/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/.prev_CMakeLists.txt
+++ /dev/null
@@ -1,65 +0,0 @@
-# Generated from common.pro.
-
-#####################################################################
-## common Generic Library:
-#####################################################################
-
-qt_add_cmake_library(common
- STATIC
- EXCEPTIONS
- OUTPUT_DIRECTORY "${QT_BUILD_DIR}/lib"
- SOURCES
- ../include/LTKCaptureDevice.h
- ../include/LTKChannel.h
- ../include/LTKClassifierDefaults.h
- ../include/LTKErrorsList.h
- ../include/LTKException.h
- ../include/LTKInc.h
- ../include/LTKLipiEngineInterface.h
- ../include/LTKLogger.h
- ../include/LTKLoggerInterface.h
- ../include/LTKMacros.h
- ../include/LTKOSUtil.h
- ../include/LTKOSUtilFactory.h
- ../include/LTKPreprocDefaults.h
- ../include/LTKPreprocessor.h
- ../include/LTKPreprocessorInterface.h
- ../include/LTKRecognitionContext.h
- ../include/LTKRefCountedPtr.h
- ../include/LTKScreenContext.h
- ../include/LTKShapeFeatureMacros.h
- ../include/LTKShapeRecoConfig.h
- ../include/LTKShapeRecoEngine.h
- ../include/LTKShapeRecoResult.h
- ../include/LTKShapeRecoUtil.h
- ../include/LTKShapeRecognizer.h
- ../include/LTKTrace.h
- ../include/LTKTraceFormat.h
- ../include/LTKTraceGroup.h
- ../include/LTKTypes.h
- ../include/LTKWordRecoConfig.h
- ../include/LTKWordRecoResult.h
- ../include/LTKWordRecognizer.h
- LTKCaptureDevice.cpp
- LTKChannel.cpp
- LTKException.cpp
- LTKScreenContext.cpp
- LTKTrace.cpp
- LTKTraceFormat.cpp
- LTKTraceGroup.cpp
- INCLUDE_DIRECTORIES
- ../include
- ../util/lib
- PUBLIC_LIBRARIES
- Qt::Core
- Qt::Gui
-)
-qt_disable_warnings(common)
-
-## Scopes:
-#####################################################################
-
-qt_extend_target(common CONDITION NOT LIPILIBS_ISEMPTY
- PUBLIC_LIBRARIES
- # Remove: L/lib
-)
diff --git a/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/CMakeLists.txt b/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/CMakeLists.txt
deleted file mode 100644
index 1042e056..00000000
--- a/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/CMakeLists.txt
+++ /dev/null
@@ -1,65 +0,0 @@
-# Generated from common.pro.
-
-#####################################################################
-## ltkcommon Generic Library:
-#####################################################################
-
-qt_add_cmake_library(ltkcommon
- STATIC
- EXCEPTIONS
- OUTPUT_DIRECTORY "${QT_BUILD_DIR}/lib"
- SOURCES
- ../include/LTKCaptureDevice.h
- ../include/LTKChannel.h
- ../include/LTKClassifierDefaults.h
- ../include/LTKErrorsList.h
- ../include/LTKException.h
- ../include/LTKInc.h
- ../include/LTKLipiEngineInterface.h
- ../include/LTKLogger.h
- ../include/LTKLoggerInterface.h
- ../include/LTKMacros.h
- ../include/LTKOSUtil.h
- ../include/LTKOSUtilFactory.h
- ../include/LTKPreprocDefaults.h
- ../include/LTKPreprocessor.h
- ../include/LTKPreprocessorInterface.h
- ../include/LTKRecognitionContext.h
- ../include/LTKRefCountedPtr.h
- ../include/LTKScreenContext.h
- ../include/LTKShapeFeatureMacros.h
- ../include/LTKShapeRecoConfig.h
- ../include/LTKShapeRecoEngine.h
- ../include/LTKShapeRecoResult.h
- ../include/LTKShapeRecoUtil.h
- ../include/LTKShapeRecognizer.h
- ../include/LTKTrace.h
- ../include/LTKTraceFormat.h
- ../include/LTKTraceGroup.h
- ../include/LTKTypes.h
- ../include/LTKWordRecoConfig.h
- ../include/LTKWordRecoResult.h
- ../include/LTKWordRecognizer.h
- LTKCaptureDevice.cpp
- LTKChannel.cpp
- LTKException.cpp
- LTKScreenContext.cpp
- LTKTrace.cpp
- LTKTraceFormat.cpp
- LTKTraceGroup.cpp
- INCLUDE_DIRECTORIES
- ../include
- ../util/lib
- PUBLIC_LIBRARIES
- Qt::Core
- Qt::Gui
-)
-qt_disable_warnings(ltkcommon)
-
-## Scopes:
-#####################################################################
-
-qt_extend_target(ltkcommon CONDITION NOT LIPILIBS_ISEMPTY
- PUBLIC_LIBRARIES
- # Remove: L/lib
-)
diff --git a/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/LTKCaptureDevice.cpp b/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/LTKCaptureDevice.cpp
deleted file mode 100644
index 0b2b2a26..00000000
--- a/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/LTKCaptureDevice.cpp
+++ /dev/null
@@ -1,556 +0,0 @@
-/******************************************************************************
-* Copyright (c) 2007 Hewlett-Packard Development Company, L.P.
-* Permission is hereby granted, free of charge, to any person obtaining a copy
-* of this software and associated documentation files (the "Software"), to deal
-* in the Software without restriction, including without limitation the rights
-* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-* copies of the Software, and to permit persons to whom the Software is
-* furnished to do so, subject to the following conditions:
-*
-* The above copyright notice and this permission notice shall be included in all copies or
-* substantial portions of the Software.
-*
-* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
-* SOFTWARE
-********************************************************************************/
-
-/*******************************************************************************
- * SVN MACROS
- *
- * $LastChangedDate: 2008-07-18 15:00:39 +0530 (Fri, 18 Jul 2008) $
- * $Revision: 561 $
- * $Author: sharmnid $
- *
- *****************************************************************************/
-/*****************************************************************************
- * FILE DESCR: Implementation of LTKCaptureDevice which holds the information
- * about the digitizer.
- *
- * CONTENTS:
- * getSampleRate
- * getLatency
- * getXDPI
- * getYDPI
- * isUniformSamplingRate
- * setXDPI
- * setYDPI
- *
- * AUTHOR: Balaji R.
- *
- * DATE: December 23, 2004
- * CHANGE HISTORY:
- * Author Date Description of change
- *****************************************************************************/
-
-#include "LTKCaptureDevice.h"
-#include "LTKErrorsList.h"
-#include "LTKLoggerUtil.h"
-#include "LTKMacros.h"
-#include "LTKException.h"
-#include "LTKErrors.h"
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : LTKCaptureDevice
-* DESCRIPTION : Default Constructor
-* ARGUMENTS :
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-LTKCaptureDevice::LTKCaptureDevice():
- m_samplingRate(DEFAULT_SAMPLING_RATE),
- m_xDpi(DEFAULT_X_DPI),
- m_yDpi(DEFAULT_Y_DPI),
- m_latency(DEFAULT_LATENCY),
- m_isUniformSamplingRate(true)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKCaptureDevice::LTKCaptureDevice()" << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKCaptureDevice::LTKCaptureDevice()" << endl;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : LTKCaptureDevice
-* DESCRIPTION : Initializes the members of the class
-* ARGUMENTS : sRate - sampling rate of the digitizer
-* uniform - type of the sampling
-* lValue - latency of the digitizer
-* xDpiVal - resolution in the x direction of the digitizer
-* (in dots per inch)
-* yDpiVal - resolution in the y direction of the digitizer
- (in dots per inch)
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-LTKCaptureDevice::LTKCaptureDevice(int sRate, bool uniform, float lValue,
- int xDpiVal, int yDpiVal) :
- m_samplingRate(sRate),
- m_xDpi(xDpiVal),
- m_yDpi(yDpiVal),
- m_latency(lValue),
- m_isUniformSamplingRate(uniform)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKCaptureDevice::LTKCaptureDevice(int, bool, float, int, int)"
- << endl;
-
- if (m_samplingRate <= 0)
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<EINVALID_SAMPLING_RATE <<": "<<
- getErrorMessage(EINVALID_SAMPLING_RATE) <<
- "LTKCaptureDevice::LTKCaptureDevice(int, bool, float, int, int)"<<endl;
-
- throw LTKException(EINVALID_SAMPLING_RATE);
- }
-
- if (m_xDpi <= 0)
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<EINVALID_X_RESOLUTION <<": "
- <<getErrorMessage(EINVALID_X_RESOLUTION) <<
- "LTKCaptureDevice::LTKCaptureDevice(int, bool, float, int, int)"<<endl;
-
- throw LTKException(EINVALID_X_RESOLUTION);
- }
-
- if (m_yDpi <= 0)
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<EINVALID_Y_RESOLUTION <<": "
- <<getErrorMessage(EINVALID_Y_RESOLUTION) <<
- "LTKCaptureDevice::LTKCaptureDevice(int, bool, float, int, int)"<<endl;
-
- throw LTKException(EINVALID_Y_RESOLUTION);
- }
-
- if (m_latency < 0)
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<EINVALID_LATENCY <<": "
- <<getErrorMessage(EINVALID_LATENCY) <<
- "LTKCaptureDevice::LTKCaptureDevice(int, bool, float, int, int)"<<endl;
-
- throw LTKException(EINVALID_LATENCY);
- }
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- " m_samplingRate = " << m_samplingRate <<
- " m_xDpi = " << m_xDpi <<
- " m_yDpi = " << m_yDpi <<
- " m_latency = " << m_latency <<
- " m_isUniformSamplingRate = " << m_isUniformSamplingRate << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKCaptureDevice::LTKCaptureDevice(int, bool, float, int, int)"
- << endl;
-
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : LTKCaptureDevice
-* DESCRIPTION : Copy Constructor
-* ARGUMENTS : captureDevice - LTKCaptureDevice to be copied
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-LTKCaptureDevice::LTKCaptureDevice(const LTKCaptureDevice& captureDevice)
-{
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- " Enter: LTKCaptureDevice:LTKCaptureDevice(const LTKCaptureDevice&)"
- << endl;
-
- m_samplingRate = captureDevice.m_samplingRate;
-
- m_isUniformSamplingRate = captureDevice.m_isUniformSamplingRate;
-
- m_latency = captureDevice.m_latency;
-
- m_xDpi = captureDevice.m_xDpi;
-
- m_yDpi = captureDevice.m_yDpi;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- " m_samplingRate = " << m_samplingRate <<
- " m_xDpi = " << m_xDpi <<
- " m_yDpi = " << m_yDpi <<
- " m_latency = " << m_latency <<
- " m_isUniformSamplingRate = " << m_isUniformSamplingRate << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKCaptureDevice::LTKCaptureDevice(const LTKCaptureDevice&)"<<endl;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : operator=
-* DESCRIPTION : Overloaded assignment operator
-* ARGUMENTS : captureDevice - LTKCaptureDevice to be assigned to
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-LTKCaptureDevice& LTKCaptureDevice::operator =
- (const LTKCaptureDevice& captureDevice)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKCaptureDevice:: operator =()" << endl;
-
- if(this != &captureDevice)
- {
- m_samplingRate = captureDevice.m_samplingRate;
-
- m_isUniformSamplingRate = captureDevice.m_isUniformSamplingRate;
-
- m_latency = captureDevice.m_latency;
-
- m_xDpi = captureDevice.m_xDpi;
-
- m_yDpi = captureDevice.m_yDpi;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- " m_samplingRate = " << m_samplingRate <<
- " m_xDpi = " << m_xDpi <<
- " m_yDpi = " << m_yDpi <<
- " m_latency = " << m_latency <<
- " m_isUniformSamplingRate = " << m_isUniformSamplingRate << endl;
- }
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKCaptureDevice:: operator =()" << endl;
-
- return *this;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : getSampleRate
-* DESCRIPTION : returns back the sampling rate of the digitizer
-* ARGUMENTS :
-* RETURNS : sampling rate of the digitizer
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-int LTKCaptureDevice::getSamplingRate() const
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKCaptureDevice::getSampleRate()" << endl;
-
-
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKCaptureDevice::getSampleRate()" << endl;
-
- return m_samplingRate;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : getLatency
-* DESCRIPTION : gets the latency of the digitizer
-* ARGUMENTS :
-* RETURNS : latency of the digitizer
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-float LTKCaptureDevice::getLatency() const
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKCaptureDevice::getLatency()" << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKCaptureDevice::getLatency()" << endl;
-
- return m_latency;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : getXDPI
-* DESCRIPTION : gets the x resolution of the digitizer (in dots per inch)
-* ARGUMENTS :
-* RETURNS : x resolution of the digitizer (in dots per inch)
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-int LTKCaptureDevice::getXDPI() const
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKCaptureDevice::getXDPI()" << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKCaptureDevice::getXDPI()" << endl;
-
- return m_xDpi;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : getYDPI
-* DESCRIPTION : gets the y resolution of the digitizer (in dots per inch)
-* ARGUMENTS :
-* RETURNS : y resolution of the digitizer (in dots per inch)
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-int LTKCaptureDevice::getYDPI() const
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKCaptureDevice::getYDPI()" << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKCaptureDevice::getYDPI()" << endl;
-
- return m_yDpi;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : isUniformSamplingRate
-* DESCRIPTION : gets the type of sampling
-* ARGUMENTS :
-* RETURNS : type of sampling : true if uniform, false if not
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-bool LTKCaptureDevice::isUniformSampling() const
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKCaptureDevice::isUniformSamplingRate()" << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKCaptureDevice::isUniformSamplingRate()" << endl;
-
- return m_isUniformSamplingRate;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : setSamplingRate
-* DESCRIPTION : sets the sampling rate of the device
-* ARGUMENTS : samplingRate - sampling rate of the device
-* RETURNS : SUCCESS on successful set operation
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-int LTKCaptureDevice::setSamplingRate(int samplingRate)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKCaptureDevice::setSamplingRate()" << endl;
-
- if (samplingRate <= 0 )
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<EINVALID_SAMPLING_RATE <<": "<<
- getErrorMessage(EINVALID_SAMPLING_RATE) <<
- "LTKCaptureDevice::setSamplingRate()"<<endl;
-
- LTKReturnError(EINVALID_SAMPLING_RATE);
- }
-
- m_samplingRate = samplingRate;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "m_samplingRate = " << m_samplingRate << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKCaptureDevice::setSamplingRate()" << endl;
-
- return SUCCESS;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : setLatency
-* DESCRIPTION : sets the latency of the device
-* ARGUMENTS : latency - latency of the device
-* RETURNS : SUCCESS on successful set operation
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-int LTKCaptureDevice::setLatency(float latency)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKCaptureDevice::setLatency()" << endl;
-
- if (m_latency < 0)
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<EINVALID_LATENCY <<": "<<
- getErrorMessage(EINVALID_LATENCY) <<
- "LTKCaptureDevice::setLatency()"<<endl;
-
- LTKReturnError(EINVALID_LATENCY);
- }
-
- m_latency = latency;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "m_latency = " << m_latency << endl;
-
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKCaptureDevice::setLatency()" << endl;
-
- return SUCCESS;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : setUniformSampling
-* DESCRIPTION : sets the type of sampling
-* ARGUMENTS : uniform - type of sampling
-* RETURNS : SUCCESS on successful set operation
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-void LTKCaptureDevice::setUniformSampling(bool uniform)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKCaptureDevice::setUniformSampling()" << endl;
-
- m_isUniformSamplingRate = uniform;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKCaptureDevice::setUniformSampling()" << endl;
-
-
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : setXDPI
-* DESCRIPTION : sets the x resolution of the digitizer (in dots per inch)
-* ARGUMENTS : xDpiVal - x resolution of the digitizer (in dots per inch)
-* RETURNS : SUCCESS on successful set operation
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-int LTKCaptureDevice::setXDPI(int xDpiVal)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKCaptureDevice::setXDPI()" << endl;
-
- if (xDpiVal <= 0)
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<EINVALID_X_RESOLUTION <<": "<<
- getErrorMessage(EINVALID_X_RESOLUTION) <<
- "LTKCaptureDevice::setXDPI()"<<endl;
-
- LTKReturnError(EINVALID_X_RESOLUTION);
- }
-
- m_xDpi = xDpiVal;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG)<<"m_xDpi = " << m_xDpi << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG)<<
- "Exit: LTKCaptureDevice::setXDPI()" << endl;
-
- return SUCCESS;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : setYDPI
-* DESCRIPTION : sets the y resolution of the digitizer (in dots per inch)
-* ARGUMENTS : yDpiVal - y resolution of the digitizer (in dots per inch)
-* RETURNS : SUCCESS on successful set operation
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-int LTKCaptureDevice::setYDPI (int yDpiVal)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKCaptureDevice::setYDPI()" << endl;
-
- if ( yDpiVal <= 0 )
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<EINVALID_Y_RESOLUTION <<": "<<
- getErrorMessage(EINVALID_Y_RESOLUTION) <<
- "LTKCaptureDevice::setYDPI()"<<endl;
-
- LTKReturnError(EINVALID_Y_RESOLUTION);
- }
- m_yDpi = yDpiVal;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG)<<"m_yDpi = " << m_yDpi << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKCaptureDevice::setYDPI()" << endl;
-
- return SUCCESS;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : ~LTKCaptureDevice
-* DESCRIPTION : destructor
-* ARGUMENTS :
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-LTKCaptureDevice::~LTKCaptureDevice ()
-{
-}
-
diff --git a/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/LTKChannel.cpp b/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/LTKChannel.cpp
deleted file mode 100644
index 918419c9..00000000
--- a/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/LTKChannel.cpp
+++ /dev/null
@@ -1,362 +0,0 @@
-/******************************************************************************
-* Copyright (c) 2007 Hewlett-Packard Development Company, L.P.
-* Permission is hereby granted, free of charge, to any person obtaining a copy
-* of this software and associated documentation files (the "Software"), to deal
-* in the Software without restriction, including without limitation the rights
-* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-* copies of the Software, and to permit persons to whom the Software is
-* furnished to do so, subject to the following conditions:
-*
-* The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
-*
-* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
-* SOFTWARE
-********************************************************************************/
-
-/******************************************************************************
- * SVN MACROS
- *
- * $LastChangedDate: 2008-07-18 15:33:34 +0530 (Fri, 18 Jul 2008) $
- * $Revision: 564 $
- * $Author: sharmnid $
- *
- ************************************************************************/
-
-/************************************************************************
- * FILE DESCR: Implementation of LTKChannel which has the description of a
- * particular input stream like x-coordinate stream,
- * y-coordinate stream, time, pressure etc.
- *
- * CONTENTS:
- * getChannelType
- * getChannelName
- * isRegularChannel
- * setChannelType
- * setChannelName
- * setRegularChannel
- *
- * AUTHOR: Balaji R.
- *
- * DATE: December 23, 2004
- * CHANGE HISTORY:
- * Author Date Description of change
- *****************************************************************************/
-
-#include "LTKErrors.h"
-#include "LTKErrorsList.h"
-#include "LTKChannel.h"
-#include "LTKMacros.h"
-#include "LTKLoggerUtil.h"
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : LTKChannel
-* DESCRIPTION : Default Constructor
-* ARGUMENTS :
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-LTKChannel::LTKChannel():
- m_channelName(DEFAULT_CHANNEL_NAME),
- m_channelType(DEFAULT_DATA_TYPE),
- m_isRegularChannel(true)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKChannel::LTKChannel()" << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKChannel::LTKChannel()" << endl;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : LTKChannel
-* DESCRIPTION : Parameterized Constructor
-* ARGUMENTS :
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-LTKChannel::LTKChannel(const string& channelName):
- m_channelName(channelName),
- m_channelType(DEFAULT_DATA_TYPE),
- m_isRegularChannel(true)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKChannel::LTKChannel(const string&)" << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKChannel::LTKChannel(const string&)" << endl;
-
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : LTKChannel
-* DESCRIPTION : Initializes the members of the class
-* ARGUMENTS : channelName - logical name of the input stream
-* channelType - data type of the values from this input stream
-* isRegular - type of channel : true for regular, false for
- intermittent
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-LTKChannel::LTKChannel(const string& channelName, ELTKDataType channelType,
- bool isRegular) :
- m_channelName(channelName),
- m_channelType(channelType),
- m_isRegularChannel(isRegular)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKChannel::LTKChannel(const string&,ELTKDataType,bool)" << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKChannel::LTKChannel(const string&,ELTKDataType,bool)" << endl;
-
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : LTKChannel
-* DESCRIPTION : Copy Constructor
-* ARGUMENTS : channel - LTKChannel to be copied
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-LTKChannel::LTKChannel(const LTKChannel& channel)
-{
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKChannel::LTKChannel(const LTKChannel&)" << endl;
-
- m_channelName = channel.m_channelName;
-
- m_channelType = channel.m_channelType;
-
- m_isRegularChannel = channel.m_isRegularChannel;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKChannel::LTKChannel(const LTKChannel&)" << endl;
-
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : operator=
-* DESCRIPTION : Overloaded assignment operator
-* ARGUMENTS : channel - LTKChannel to be assigned to
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-LTKChannel& LTKChannel::operator=(const LTKChannel& channel)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKChannel::operator=()" << endl;
-
- if ( this != &channel )
- {
- m_channelName = channel.m_channelName;
-
- m_channelType = channel.m_channelType;
-
- m_isRegularChannel = channel.m_isRegularChannel;
- }
-/* LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKChannel::operator=()" << endl;*/
-
- return *this;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : ~LTKChannel
-* DESCRIPTION : destructor
-* ARGUMENTS :
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-LTKChannel::~LTKChannel()
-{
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : getChannelType
-* DESCRIPTION : returns data type of the values from the channel
-* ARGUMENTS :
-* RETURNS : data type of the values from the channel
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-ELTKDataType LTKChannel::getChannelType() const
-{
- /*LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKChannel::getChannelType()" << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKChannel::getChannelType()" << endl;*/
-
- return m_channelType;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : getChannelName
-* DESCRIPTION : returns the logical name of the channel
-* ARGUMENTS :
-* RETURNS : logical name of the channel
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-string LTKChannel::getChannelName() const
-{
-/* LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKChannel::getChannelName()" << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKChannel::getChannelName()" << endl;*/
-
- return m_channelName;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : isRegularChannel
-* DESCRIPTION : returns the type of the channel
-* ARGUMENTS :
-* RETURNS : type ofthe channel : true for regular, false for intermittent
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-bool LTKChannel::isRegularChannel() const
-{
- /*LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKChannel::isRegularChannel()" << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKChannel::isRegularChannel()" << endl;*/
-
- return m_isRegularChannel;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : setChannelType
-* DESCRIPTION : sets the data type of the values from the channel
-* ARGUMENTS : channelType - data type of the values from the channel
-* RETURNS : SUCCESS on successful set operation
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* *****************************************************************************/
-
-void LTKChannel::setChannelType(ELTKDataType channelType)
-{
-/* LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKChannel::setChannelType()" << endl;*/
-
- m_channelType = channelType;
-
- /*LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "m_channelType = " << m_channelType << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKChannel::setChannelType()" << endl;*/
-
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : setChannelName
-* DESCRIPTION : sets the name of the channel
-* ARGUMENTS : channelName - name of the channel
-* RETURNS : SUCCESS on successful set operation
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-int LTKChannel::setChannelName(const string& channelName)
-{
- /*LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKChannel::setChannelName()" << endl;*/
-
- if( channelName.length() == 0)
- {
- LTKReturnError(EEMPTY_STRING);
- }
-
- m_channelName = channelName;
-
- /*LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "m_channelName = " << m_channelName << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKChannel::setChannelName()" << endl;*/
-
- return SUCCESS;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : setRegularChannel
-* DESCRIPTION : sets the type of the channel
-* ARGUMENTS : isRegular - type of the channel : true for regular,
- false for intermittent
-* RETURNS : SUCCESS on successful set operation
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-void LTKChannel::setRegularChannel(bool isRegular)
-{
- /*LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKChannel::setRegularChannel()" << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKChannel::setRegularChannel()" << endl;*/
-
- m_isRegularChannel = isRegular;
-
-}
diff --git a/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/LTKException.cpp b/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/LTKException.cpp
deleted file mode 100644
index 48a0c834..00000000
--- a/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/LTKException.cpp
+++ /dev/null
@@ -1,154 +0,0 @@
-/******************************************************************************
-* Copyright (c) 2007 Hewlett-Packard Development Company, L.P.
-* Permission is hereby granted, free of charge, to any person obtaining a copy
-* of this software and associated documentation files (the "Software"), to deal
-* in the Software without restriction, including without limitation the rights
-* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-* copies of the Software, and to permit persons to whom the Software is
-* furnished to do so, subject to the following conditions:
-*
-* The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
-*
-* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
-* SOFTWARE
-********************************************************************************/
-
-/******************************************************************************
- * SVN MACROS
- *
- * $LastChangedDate: 2008-07-18 15:00:39 +0530 (Fri, 18 Jul 2008) $
- * $Revision: 561 $
- * $Author: sharmnid $
- *
- ************************************************************************/
-
-/************************************************************************
- * FILE DESCR: Implementation of LTKException class. The error messages are
- * thrown embedded in objects of this class
- *
- * CONTENTS:
- * getExceptionMessage
- *
- * AUTHOR: Balaji R.
- *
- * DATE: December 23, 2004
- * CHANGE HISTORY:
- * Author Date Description of change
- ************************************************************************/
-
-#include "LTKException.h"
-#include "LTKErrors.h"
-#include "LTKMacros.h"
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : LTKException
-* DESCRIPTION : Default Constructor
-* ARGUMENTS :
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-LTKException::LTKException():
- m_errorCode(DEFAULT_ERROR_CODE)
-{
- /*LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKException::LTKException()" << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKException::LTKException()" << endl;*/
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : LTKException
-* DESCRIPTION : Initialization Constructor
-* ARGUMENTS : exceptionMsg - error message
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* *****************************************************************************/
-
-LTKException::LTKException(int errorCode) :
- m_errorCode(errorCode)
-{
- /*LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKException::LTKException(int)" << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKException::LTKException(int)" << endl;*/
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : getExceptionMessage
-* DESCRIPTION : returns the error message
-* ARGUMENTS :
-* RETURNS : error message string
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-string LTKException::getExceptionMessage() const
-{
- /*LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKException::getExceptionMessage()" << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKException::getExceptionMessage()" << endl;*/
-
- return string(getErrorMessage(m_errorCode));
-}
-
-/*****************************************************************************
-* AUTHOR : Saravanan R.
-* DATE : 22-Feb-2007
-* NAME : getErrorCode
-* DESCRIPTION : returns the error code
-* ARGUMENTS :
-* RETURNS : error code
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-int LTKException::getErrorCode() const
-{
- /*LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKException::getErrorCode()" << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKException::getErrorCode()" << endl;*/
-
- return m_errorCode;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : ~LTKException
-* DESCRIPTION : Destructor
-* ARGUMENTS :
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-* ****************************************************************************/
-
-LTKException::~LTKException()
-{
-}
-
-
diff --git a/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/LTKScreenContext.cpp b/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/LTKScreenContext.cpp
deleted file mode 100644
index 735e7437..00000000
--- a/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/LTKScreenContext.cpp
+++ /dev/null
@@ -1,441 +0,0 @@
-/******************************************************************************
-* Copyright (c) 2007 Hewlett-Packard Development Company, L.P.
-* Permission is hereby granted, free of charge, to any person obtaining a copy
-* of this software and associated documentation files (the "Software"), to deal
-* in the Software without restriction, including without limitation the rights
-* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-* copies of the Software, and to permit persons to whom the Software is
-* furnished to do so, subject to the following conditions:
-*
-* The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
-*
-* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
-* SOFTWARE
-*******************************************************************************/
-
-/******************************************************************************
- * SVN MACROS
- *
- * $LastChangedDate: 2011-01-11 13:48:17 +0530 (Tue, 11 Jan 2011) $
- * $Revision: 827 $
- * $Author: mnab $
- *
- ************************************************************************/
-/************************************************************************
- * FILE DESCR: Implementation of LTKScreenContext which holds the co-ordinates
- of the writing area provided for the set of traces being sent
- for recognition
- *
- * CONTENTS:
- * getBboxLeft
- * getBboxBottom
- * getBboxRight
- * getBboxTop
- * setBboxLeft
- * setBboxBottom
- * setBboxRight
- * setBboxTop
- *
- * AUTHOR: Mudit Agrawal.
- *
- * DATE: February 23, 2005
- * CHANGE HISTORY:
- * Author Date Description of change
- ************************************************************************/
-
-#include "LTKScreenContext.h"
-#include "LTKMacros.h"
-
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : LTKScreenContext
-* DESCRIPTION : Default Constructor
-* ARGUMENTS :
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-LTKScreenContext::LTKScreenContext() :
- m_bboxBottom(0.0),
- m_bboxLeft(0.0),
- m_bboxRight(0.0),
- m_bboxTop(0.0)
-{
- /*LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKScreenContext::LTKScreenContext()" << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKScreenContext::LTKScreenContext()" << endl;*/
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : LTKScreenContext
-* DESCRIPTION : Initialization Constructor
-* ARGUMENTS : bboxLeft - left x co-ordinate of the writing area
-* bboxBottom - bottom y co-ordinate of the writing area
-* bboxRight - right x co-ordinate of the writing area
-* bboxTop - top y co-ordinate of the writing area
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-LTKScreenContext::LTKScreenContext(float bboxLeft, float bboxBottom,
- float bboxRight,float bboxTop) :
- m_bboxLeft(bboxLeft),
- m_bboxBottom(bboxBottom),
- m_bboxRight(bboxRight),
- m_bboxTop(bboxTop)
-{
-/* LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKScreenContext::LTKScreenContext(float,float,float,float)" << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKScreenContext::LTKScreenContext(float,float,float,float)" << endl;*/
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : getBboxLeft
-* DESCRIPTION : gets the left x co-ordinate of the writing area
-* ARGUMENTS :
-* RETURNS : left x co-ordinate of the writing area
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-float LTKScreenContext::getBboxLeft() const
-{
-/* LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKScreenContext::getBboxLeft()" << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKScreenContext::getBboxLeft()" << endl;*/
-
- return m_bboxLeft;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : getBboxBottom
-* DESCRIPTION : gets the bottom y co-ordinate of the writing area
-* ARGUMENTS :
-* RETURNS : bottom y co-ordinate of the writing area
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-float LTKScreenContext::getBboxBottom() const
-{
-/* LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKScreenContext::getBboxBottom()" << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKScreenContext::getBboxBottom()" << endl;*/
-
- return m_bboxBottom;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : getBboxRight
-* DESCRIPTION : gets the right x co-ordinate of the writing area
-* ARGUMENTS :
-* RETURNS : right x co-ordinate of the writing area
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-float LTKScreenContext::getBboxRight() const
-{
-/* LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKScreenContext::getBboxRight()" << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKScreenContext::getBboxRight()" << endl;*/
-
- return m_bboxRight;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : getBboxTop
-* DESCRIPTION : gets the top y co-ordinate of the writing area
-* ARGUMENTS :
-* RETURNS : top y co-ordinate of the writing area
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-float LTKScreenContext::getBboxTop() const
-{
- /*LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKScreenContext::getBboxTop()" << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKScreenContext::getBboxTop()" << endl;*/
-
- return m_bboxTop;
-}
-
-/******************************************************************************
-* AUTHOR : Deepu V.
-* DATE : 01-MAR-2005
-* NAME : getAllHLines
-* DESCRIPTION : gets the horizontal lines in the screen context
-* ARGUMENTS : none
-* RETURNS : const reference to vector of ordinates of horizontal lines
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-const floatVector& LTKScreenContext::getAllHLines() const
-{
- /*LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKScreenContext::getAllHLines()" << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKScreenContext::getAllHLines()" << endl;*/
-
- return m_hLines;
-}
-
-/******************************************************************************
-* AUTHOR : Deepu V.
-* DATE : 01-MAR-2005
-* NAME : getAllVLines
-* DESCRIPTION : gets the horizontal lines in the screen context
-* ARGUMENTS : none
-* RETURNS : const reference to vector of ordinates of horizontal lines
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-const floatVector& LTKScreenContext::getAllVLines() const
-{
- /*LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKScreenContext::getAllVLines()" << endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKScreenContext::getAllVLines()" << endl;*/
-
- return m_vLines;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : setBboxLeft
-* DESCRIPTION : sets the left x co-ordinate of the writing area
-* ARGUMENTS : bboxLeft - left x co-ordinate of the writing area
-* RETURNS : SUCCESS on successful set operation
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-int LTKScreenContext::setBboxLeft(float bboxLeft)
-{
- /*LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKScreenContext::setBboxLeft()" << endl;*/
-
- if(bboxLeft <0)
- {
- return FAILURE;
- }
-
- m_bboxLeft = bboxLeft;
-
- /*LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKScreenContext::setBboxLeft()" << endl;*/
-
- return SUCCESS;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : setBboxBottom
-* DESCRIPTION : sets the bottom y co-ordinate of the writing area
-* ARGUMENTS : bboxBottom - bottom y co-ordinate of the writing area
-* RETURNS : SUCCESS on successful set operation
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-int LTKScreenContext::setBboxBottom(float bboxBottom)
-{
- /*LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKScreenContext::setBboxBottom()" << endl;*/
-
- if(bboxBottom<0)
- {
- return FAILURE;
- }
-
- m_bboxBottom = bboxBottom;
-
- /*LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKScreenContext::setBboxBottom()" << endl;*/
-
- return SUCCESS;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : setBboxRight
-* DESCRIPTION : sets the right x co-ordinate of the writing area
-* ARGUMENTS : bboxRight - right x co-ordinate of the writing area
-* RETURNS : SUCCESS on successful set operation
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-int LTKScreenContext::setBboxRight(float bboxRight)
-{
- /*LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKScreenContext::setBboxRight()" << endl;*/
-
- if(bboxRight<0)
- {
- return FAILURE;
- }
-
- m_bboxRight = bboxRight;
-
- /*LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKScreenContext::setBboxRight()" << endl;*/
-
- return SUCCESS;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : setBboxTop
-* DESCRIPTION : sets the top y co-ordinate of the writing area
-* ARGUMENTS : bboxTop - top y co-ordinate of the writing area
-* RETURNS : SUCCESS on successful set operation
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-int LTKScreenContext::setBboxTop(float bboxTop)
-{
- /*LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKScreenContext::setBboxTop()" << endl;*/
-
- if(bboxTop<0)
- {
- return FAILURE;
- }
-
- m_bboxTop = bboxTop;
-
- /*LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKScreenContext::setBboxTop()" << endl;*/
-
- return SUCCESS;
-}
-/******************************************************************************
-* AUTHOR : Deepu V.
-* DATE : 01-MAR-2005
-* NAME : addHLine
-* DESCRIPTION : This function adds a horizontal line in the screen context
-* ARGUMENTS : ordinate - position of the horizontal line
-* RETURNS : SUCCESS on successful add operation
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-*******************************************************************************/
-int LTKScreenContext::addHLine(float ordinate)
-{
- /*LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKScreenContext::addHLine()" << endl;*/
-
- if(ordinate<0)
- {
- return FAILURE;
- }
-
- m_hLines.push_back(ordinate);
-
- /*LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKScreenContext::addHLine()" << endl;*/
-
-
- return SUCCESS;
-}
-
-/******************************************************************************
-* AUTHOR : Deepu V.
-* DATE : 01-MAR-2005
-* NAME : addVLine
-* DESCRIPTION : This function adds a vertical line in the screen context
-* ARGUMENTS : ordinate - position of the vertical line
-* RETURNS : SUCCESS on successful add operation
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-int LTKScreenContext::addVLine(float abscissa)
-{
- /*LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKScreenContext::addVLine()" << endl;*/
-
- if(abscissa <0)
- {
- return FAILURE;
- }
-
- m_vLines.push_back(abscissa);
-
- /*LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKScreenContext::addVLine()" << endl;*/
-
- return SUCCESS;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : ~LTKScreenContext
-* DESCRIPTION : destructor
-* ARGUMENTS :
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-LTKScreenContext::~LTKScreenContext ()
-{
-}
-
-
diff --git a/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/LTKTrace.cpp b/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/LTKTrace.cpp
deleted file mode 100644
index 3625ce50..00000000
--- a/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/LTKTrace.cpp
+++ /dev/null
@@ -1,730 +0,0 @@
-/******************************************************************************
-* Copyright (c) 2006 Hewlett-Packard Development Company, L.P.
-* Permission is hereby granted, free of charge, to any person obtaining a copy
-* of this software and associated documentation files (the "Software"), to deal
-* in the Software without restriction, including without limitation the rights
-* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-* copies of the Software, and to permit persons to whom the Software is
-* furnished to do so, subject to the following conditions:
-*
-* The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
-*
-* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
-* SOFTWARE
-********************************************************************************/
-
-/******************************************************************************
- * SVN MACROS
- *
- * $LastChangedDate: 2011-01-11 13:48:17 +0530 (Tue, 11 Jan 2011) $
- * $Revision: 827 $
- * $Author: mnab $
- *
- ************************************************************************/
-/************************************************************************
- * FILE DESCR: implementation of LTKTrace which holds series of points
- * from a pen down event to the next immediate pen up event
- *
- * CONTENTS:
- * getNumberOfPoints
- * getPointAt
- * getChannelValues
- * getChannelValues (overloaded)
- * getChannelValueAt
- * setChannelValues
- * addPoint
- * getChannelNames
- * addChannel
- * getChannelIndex
- *
- * AUTHOR: Balaji R.
- *
- * DATE: December 23, 2004
- * CHANGE HISTORY:
- * Author Date Description of change
- ************************************************************************/
-
-#include "LTKTrace.h"
-#include "LTKMacros.h"
-#include "LTKTraceFormat.h"
-#include "LTKErrors.h"
-#include "LTKErrorsList.h"
-#include "LTKChannel.h"
-#include "LTKException.h"
-#include "LTKLoggerUtil.h"
-
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : LTKTrace
-* DESCRIPTION : Default Constructor
-* ARGUMENTS :
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-LTKTrace::LTKTrace()
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Entering: LTKTrace::LTKTrace()"<<endl;
-
- floatVector emptyChannel;
-
- m_traceChannels.assign(2,emptyChannel);
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exiting: LTKTrace::LTKTrace()"<<endl;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : LTKTrace
-* DESCRIPTION : Initialization constructor
-* ARGUMENTS : inputStream - incoming data
-* traceFormat - format of the incoming data
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-LTKTrace::LTKTrace(const floatVector& inputStream,
- const LTKTraceFormat& traceFormat)
-{
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Entering: LTKTrace::LTKTrace(const floatVector&,const LTKTraceFormat& )"<<endl;
-
- int inputStreamSize = inputStream.size();
- int numChannels = traceFormat.getNumChannels();
-
- floatVector tempChannel;
-
- if(numChannels == 0)
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<EZERO_CHANNELS <<": "<<
- getErrorMessage(EZERO_CHANNELS) <<
- "LTKTrace::LTKTrace(const floatVector&,const LTKTraceFormat&() "<<endl;
-
- throw LTKException(EZERO_CHANNELS);
- }
-
- if(inputStreamSize==0 || ((inputStreamSize % numChannels) != 0))
- {
-
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<EINVALID_INPUT_STREAM <<": "<<
- getErrorMessage(EINVALID_INPUT_STREAM) <<
- "LTKTrace::LTKTrace(const floatVector&,const LTKTraceFormat&() "<<endl;
-
- throw LTKException(EINVALID_INPUT_STREAM);
- }
-
- m_traceFormat = traceFormat;
-
- /*
- * values of individual channels are separated from contiguous channel values.
- * vector<float> of these individual channels is computed, and such vectors
- * for all channels are collected into another vector.
- */
-
- for(int channelIndex = 0; channelIndex < numChannels; ++channelIndex)
- {
- for(int inputIndex = channelIndex; inputIndex < inputStreamSize;
- inputIndex += numChannels)
- {
- tempChannel.push_back(inputStream[inputIndex]);
- }
-
- m_traceChannels.push_back(tempChannel);
-
- tempChannel.clear();
- }
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exiting: LTKTrace::LTKTrace(const floatVector&,const LTKTraceFormat& )"<<endl;
-
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : LTKTrace
-* DESCRIPTION : Trace format initialization constructor
-* ARGUMENTS : traceFormat - format of the incoming data
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-LTKTrace::LTKTrace(const LTKTraceFormat& traceFormat)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Entering: LTKTrace::LTKTrace(const LTKTraceFormat&)"<<endl;
-
- floatVector tempChannel;
-
- int numChannels = traceFormat.getNumChannels();
-
- m_traceFormat = traceFormat;
-
- m_traceChannels.assign(numChannels, tempChannel);
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exiting: LTKTrace::LTKTrace(const LTKTraceFormat&)"<<endl;
-
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : LTKTrace
-* DESCRIPTION : copy constructor
-* ARGUMENTS : trace - trace to be copied
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-LTKTrace::LTKTrace(const LTKTrace& trace)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Entering: LTKTrace::LTKTrace(const LTKTrace&)"<<endl;
-
- m_traceChannels = trace.m_traceChannels;
- m_traceFormat = trace.m_traceFormat;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exiting: LTKTrace::LTKTrace(const LTKTrace&)"<<endl;
-
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : operator=
-* DESCRIPTION : assignment operator
-* ARGUMENTS : trace - trace to be assigned
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-LTKTrace& LTKTrace::operator=(const LTKTrace& trace)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Entering: LTKTrace::operator=()"<<endl;
-
- if ( this != &trace )
- {
- m_traceChannels = trace.m_traceChannels;
- m_traceFormat = trace.m_traceFormat;
- }
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exiting: LTKTrace::operator=()"<<endl;
-
- return *this;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : getNumberOfPoints
-* DESCRIPTION : get number of points in the trace
-* ARGUMENTS :
-* RETURNS : number of points in the trace
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-int LTKTrace::getNumberOfPoints() const
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Entering: LTKTrace::getNumberOfPoints()"<<endl;
-
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exiting: LTKTrace::getNumberOfPoints()"<<endl;
-
- return m_traceChannels[0].size();
-
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : getPointAt
-* DESCRIPTION : returns the point at a specified index
-* ARGUMENTS : pointIndex - index of the point whose values are required
-* RETURNS : point at the specified index
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-int LTKTrace::getPointAt(int pointIndex, floatVector& outPointCoordinates) const
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Entering: LTKTrace::getPointAt()"<<endl;
-
- if ( pointIndex < 0 || pointIndex >= m_traceChannels[0].size() )
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<EPOINT_INDEX_OUT_OF_BOUND <<": "<<
- getErrorMessage(EPOINT_INDEX_OUT_OF_BOUND) <<
- "LTKTrace::getPointAt() "<<endl;
-
- LTKReturnError(EPOINT_INDEX_OUT_OF_BOUND);
- }
-
- vector<floatVector>::const_iterator channelIterator = m_traceChannels.begin();
-
- vector<floatVector>::const_iterator traceChannelsEnd = m_traceChannels.end();
-
- for(; channelIterator != traceChannelsEnd; ++channelIterator)
- {
- outPointCoordinates.push_back((*channelIterator)[pointIndex]);
- }
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exiting: LTKTrace::getPointAt()"<<endl;
-
- return SUCCESS;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : getChannelValues
-* DESCRIPTION : get the values of the channel given its name
-* ARGUMENTS : channelName - name of the channel whose values are required
-* RETURNS : values of the channel with the specified name
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-int LTKTrace::getChannelValues(const string& channelName,
- floatVector& outChannelValues) const
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Entering: LTKTrace::getChannelValues(const string&, floatVector&)"<<endl;
-
- int channelIndex = -1;
-
- int errorCode = 0;
-
- if ((errorCode=m_traceFormat.getChannelIndex(channelName, channelIndex)) != SUCCESS )
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: LTKTrace::getChannelValues(string&, floatVector&) "<<endl;
-
- LTKReturnError(errorCode);
- }
-
- outChannelValues = m_traceChannels[channelIndex];
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exiting: LTKTrace::getChannelValues(string&, floatVector&)"<<endl;
-
- return SUCCESS;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : getChannelValues
-* DESCRIPTION : get the values of the channel given its index
-* ARGUMENTS : channelIndex - index of the channel whose values are required
-* RETURNS : values of the channel at the specified index
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-int LTKTrace::getChannelValues(int channelIndex,
- floatVector& outChannelValues) const
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Entering: LTKTrace::getChannelValues(int, floatVector&)"<<endl;
-
- if(channelIndex < 0 || channelIndex >= m_traceFormat.getNumChannels())
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<ECHANNEL_INDEX_OUT_OF_BOUND <<": "<<
- getErrorMessage(ECHANNEL_INDEX_OUT_OF_BOUND) <<
- "LTKTrace::getChannelValues() "<<endl;
-
- LTKReturnError(ECHANNEL_INDEX_OUT_OF_BOUND);
- }
-
- outChannelValues = m_traceChannels[channelIndex];
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exiting: LTKTrace::getChannelValues(int, floatVector&)"<<endl;
-
- return SUCCESS;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : getChannelValueAt
-* DESCRIPTION : gets the value of a particular channel at a particular point
-* ARGUMENTS : channelName - name of the channel to get the value from
-* pointIndex - index of the point at which the channel value
-* is required
-* RETURNS : value of the specified channel at the specified point
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-int LTKTrace::getChannelValueAt(const string& channelName, int pointIndex,
- float& outValue) const
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Entering: LTKTrace::getChannelValueAt(const string&, floatVector&)"<<endl;
-
- if (pointIndex < 0 || pointIndex >= m_traceChannels[0].size() )
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<ECHANNEL_INDEX_OUT_OF_BOUND <<": "<<
- getErrorMessage(ECHANNEL_INDEX_OUT_OF_BOUND) <<
- "LTKTrace::getChannelValueAt() "<<endl;
-
- LTKReturnError(EPOINT_INDEX_OUT_OF_BOUND);
- }
-
- int channelIndex = -1;
-
- if (m_traceFormat.getChannelIndex(channelName, channelIndex) != SUCCESS )
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<ECHANNEL_NOT_FOUND <<": "<<
- getErrorMessage(ECHANNEL_NOT_FOUND) <<
- "LTKTrace::getChannelValueAt() "<<endl;
-
- LTKReturnError(ECHANNEL_NOT_FOUND);
- }
-
- outValue = m_traceChannels[channelIndex][pointIndex];
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exiting: LTKTrace::getChannelValueAt()"<<endl;
-
- return SUCCESS;
-
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : setChannelValues
-* DESCRIPTION : resets the data of the given channel
-* ARGUMENTS : channelName - name of the channel whose data is to be reset
-* channelData - new data for the channel reset
-* RETURNS : SUCCESS on successful reset
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-int LTKTrace::reassignChannelValues(const string &channelName,
- const floatVector &channelData)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Entering: LTKTrace::reassignChannelValues(const string&, floatVector&)"<<endl;
-
- if(channelData.size() != m_traceChannels[0].size())
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<ECHANNEL_SIZE_MISMATCH <<": "<<
- getErrorMessage(ECHANNEL_SIZE_MISMATCH) <<
- "LTKTrace::reassignChannelValues() "<<endl;
-
- LTKReturnError(ECHANNEL_SIZE_MISMATCH);
- }
-
- int channelIndex = -1;
-
- if (m_traceFormat.getChannelIndex(channelName, channelIndex) != SUCCESS )
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<ECHANNEL_NOT_FOUND <<": "<<
- getErrorMessage(ECHANNEL_NOT_FOUND) <<
- "LTKTrace::reassignChannelValues() "<<endl;
-
- LTKReturnError(ECHANNEL_NOT_FOUND);
- }
-
- // updating the changed values of a channel in m_traceChannels vector.
- m_traceChannels[channelIndex] = channelData;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exiting: LTKTrace::reassignChannelValues()"<<endl;
-
- return SUCCESS;
-}
-
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : setAllChannelValues
-* DESCRIPTION : This method reassigns the values of all the channels. The number
-* of rows in the input 2D vector must be equal to the current number
-* of channels with each row having the same length. And this assumes
-* one-to-one correspondence with the channel vector.
-* ARGUMENTS : allChannelValues - new values of all the channels
-* channelData - new data for the channel reset
-* RETURNS : SUCCESS on successful reset
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-int LTKTrace::setAllChannelValues(const float2DVector& allChannelValues)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Entering: LTKTrace::setAllChannelValues()"<<endl;
-
- if(allChannelValues.size() != m_traceFormat.getNumChannels())
- {
-
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<ENUM_CHANNELS_MISMATCH <<": "<<
- getErrorMessage(ENUM_CHANNELS_MISMATCH) <<
- "LTKTrace::setAllChannelValues() "<<endl;
-
- LTKReturnError(ENUM_CHANNELS_MISMATCH);
- }
-
- if(allChannelValues[0].size()==0)
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<EEMPTY_VECTOR <<": "<<
- getErrorMessage(EEMPTY_VECTOR) <<
- "LTKTrace::setAllChannelValues() "<<endl;
-
- LTKReturnError(EEMPTY_VECTOR);
- }
-
- int prevRowSize=allChannelValues[0].size();
- int currRowSize=0;
-
- for(int i=1; i<allChannelValues.size(); ++i)
- {
- currRowSize = allChannelValues[i].size();
-
- if(currRowSize != prevRowSize)
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<EUNEQUAL_LENGTH_VECTORS <<": "<<
- getErrorMessage(EUNEQUAL_LENGTH_VECTORS) <<
- "LTKTrace::setAllChannelValues() "<<endl;
-
- LTKReturnError(EUNEQUAL_LENGTH_VECTORS);
- }
-
- prevRowSize = currRowSize;
- }
-
- m_traceChannels = allChannelValues;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exiting: LTKTrace::setAllChannelValues()"<<endl;
-
-
- return SUCCESS;
-}
-
-
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : addPoint
-* DESCRIPTION : adds a point to the trace
-* ARGUMENTS : pointVec - point to be added to the trace
-* RETURNS : SUCCESS on successful addition
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-int LTKTrace::addPoint(const floatVector& pointVec)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Entering: LTKTrace::setAllChannelValues()"<<endl;
-
- int numChannels = m_traceFormat.getNumChannels();
-
- if ( pointVec.size() != numChannels )
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<EUNEQUAL_LENGTH_VECTORS <<": "<<
- getErrorMessage(EUNEQUAL_LENGTH_VECTORS) <<
- "LTKTrace::setAllChannelValues() "<<endl;
-
- LTKReturnError(ENUM_CHANNELS_MISMATCH);
- }
-
- // Adding the new point in m_traceChannels vector.
- for(int index=0; index < numChannels; ++index)
- {
- (m_traceChannels[index]).push_back(pointVec[index]);
- }
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exiting: LTKTrace::setAllChannelValues()"<<endl;
-
- return SUCCESS;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : addChannel
-* DESCRIPTION : adds a new channel to the trace
-* ARGUMENTS : channelValuesVec - values of the new channel
-* channelName - new channel name
-* RETURNS : SUCCESS on successful addition
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-*******************************************************************************/
-
-int LTKTrace::addChannel(const floatVector &channelValuesVec,
- const LTKChannel& channel)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Entering: LTKTrace::addChannel()"<<endl;
-
- if ( m_traceChannels[0].size() !=0 &&
- channelValuesVec.size() != m_traceChannels[0].size() )
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<ECHANNEL_SIZE_MISMATCH <<": "<<
- m_traceChannels[0].size() <<
- "LTKTrace::addChannel() "<<endl;
-
- LTKReturnError(ECHANNEL_SIZE_MISMATCH);
- }
-
- int errorCode = m_traceFormat.addChannel(channel);
-
- if (errorCode != SUCCESS)
- {
- LTKReturnError(errorCode);
- }
-
- m_traceChannels.push_back(channelValuesVec);
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exiting: LTKTrace::addChannel()"<<endl;
-
- return SUCCESS;
-}
-
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : ~LTKTrace
-* DESCRIPTION : destructor
-* ARGUMENTS :
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-LTKTrace::~LTKTrace()
-{
-}
-
-/******************************************************************************
-* AUTHOR : Bharath A
-* DATE : 17-DEC-2007
-* NAME : emptyTrace
-* DESCRIPTION : To empty the channel values but retain the trace format
-* ARGUMENTS :
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-*******************************************************************************/
-void LTKTrace::emptyTrace()
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Entering: LTKTrace::emptyTrace()"<<endl;
-
- for(int i=0;i<m_traceChannels.size();++i)
- {
- m_traceChannels[i].clear();
- }
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exiting: LTKTrace::emptyTrace()"<<endl;
-
-}
-
-
-/******************************************************************************
-* AUTHOR : Dinesh M
-* DATE : 17-Dec-2007
-* NAME : isEmpty
-* DESCRIPTION : Checks if the data vector is empty
-* ARGUMENTS :
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-bool LTKTrace::isEmpty() const
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Entering: LTKTrace::isEmpty()"<<endl;
-
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exiting: LTKTrace::isEmpty()"<<endl;
-
- return (m_traceChannels[0].size()==0);
-}
-
-
-/******************************************************************************
-* AUTHOR : Dinesh M
-* DATE : 17-Dec-2007
-* NAME : getTraceFormat
-* DESCRIPTION : Getter on the current trace format
-* ARGUMENTS :
-* RETURNS : const LTKTraceFormat&
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-const LTKTraceFormat& LTKTrace::getTraceFormat() const
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Entering: LTKTrace::getTraceFormat()"<<endl;
-
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exiting: LTKTrace::getTraceFormat()"<<endl;
-
- return m_traceFormat;
-}
-
diff --git a/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/LTKTraceFormat.cpp b/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/LTKTraceFormat.cpp
deleted file mode 100644
index 65706dea..00000000
--- a/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/LTKTraceFormat.cpp
+++ /dev/null
@@ -1,418 +0,0 @@
-/******************************************************************************
-* Copyright (c) 2006 Hewlett-Packard Development Company, L.P.
-* Permission is hereby granted, free of charge, to any person obtaining a copy
-* of this software and associated documentation files (the "Software"), to deal
-* in the Software without restriction, including without limitation the rights
-* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-* copies of the Software, and to permit persons to whom the Software is
-* furnished to do so, subject to the following conditions:
-*
-* The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
-*
-* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
-* SOFTWARE
-********************************************************************************/
-
-/******************************************************************************
- * SVN MACROS
- *
- * $LastChangedDate: 2008-07-18 15:33:34 +0530 (Fri, 18 Jul 2008) $
- * $Revision: 564 $
- * $Author: sharmnid $
- *
- ************************************************************************/
-/************************************************************************
- * FILE DESCR: Implementation of LTKTraceFormat which holds the information
- * about type and number of channel data available at each pen point
- *
- * CONTENTS:
- * getChannelIndex
- * getChannelName
- * getNumChannels
- * getRegularChannelNames
- * getAllChannelNames
- * setChannelFormat
- * addChannel
- *
- * AUTHOR: Balaji R.
- *
- * DATE: December 23, 2004
- * CHANGE HISTORY:
- * Author Date Description of change
- ************************************************************************/
-
-#include "LTKTraceFormat.h"
-#include "LTKChannel.h"
-#include "LTKException.h"
-#include "LTKErrorsList.h"
-#include "LTKErrors.h"
-#include "LTKMacros.h"
-#include "LTKLoggerUtil.h"
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : LTKTraceFormat
-* DESCRIPTION : Default Constructor
-* ARGUMENTS :
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-LTKTraceFormat::LTKTraceFormat()
-{
- LTKChannel xChannel(X_CHANNEL_NAME);
- LTKChannel yChannel(Y_CHANNEL_NAME);
- m_channelVector.push_back(xChannel);
- m_channelVector.push_back(yChannel);
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : LTKTraceFormat
-* DESCRIPTION : Initialization Constructor
-* ARGUMENTS :
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-LTKTraceFormat::LTKTraceFormat(const LTKChannelVector& channelsVec)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Entering: LTKTraceFormat::LTKTraceFormat()"<<endl;
- if(channelsVec.size() == 0)
- {
- LOG(LTKLogger::LTK_LOGLEVEL_ERR)
- <<"Error : "<< EZERO_CHANNELS <<":"<< getErrorMessage(EZERO_CHANNELS)
- <<" LTKTraceFormat::LTKTraceFormat(LTKChannelVector&)" <<endl;
-
- throw LTKException(EZERO_CHANNELS);
- }
- else
- {
- m_channelVector = channelsVec;
- }
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Entering: LTKTraceFormat::LTKTraceFormat()"<<endl;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : LTKTraceGroup
-* DESCRIPTION : Copy Constructor
-* ARGUMENTS : traceFormat - object to be copied
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-LTKTraceFormat::LTKTraceFormat(const LTKTraceFormat& traceFormat)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Entering: LTKTraceFormat::LTKTraceFormat(const LTKTraceFormat&)"<<endl;
-
- m_channelVector = traceFormat.m_channelVector;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exiting: LTKTraceFormat::LTKTraceFormat(const LTKTraceFormat&)"<<endl;
-
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : operator=
-* DESCRIPTION : Assignment operator
-* ARGUMENTS : traceFormat - object to be assigned
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-LTKTraceFormat& LTKTraceFormat::operator=(const LTKTraceFormat& traceFormat)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Entering: LTKTraceFormat::operator=()"<<endl;
-
- if ( this != &traceFormat )
- {
- m_channelVector = traceFormat.m_channelVector;
- }
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exiting: LTKTraceFormat::operator=()"<<endl;
-
- return *this;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : getChannelIndex
-* DESCRIPTION : returns position of the channel given its name
-* ARGUMENTS : channelName - name of the channel whose position is required
-* RETURNS : position of the channel with the given name
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-int LTKTraceFormat::getChannelIndex(const string& channelName,
- int& outReturnIndex) const
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Entering: LTKTraceFormat::getChannelIndex()"<<endl;
-
- int numChannels = m_channelVector.size();
-
- for(int channelIndex = 0 ; channelIndex < numChannels; ++channelIndex)
- {
- if((m_channelVector[channelIndex]).getChannelName() == channelName)
- {
- outReturnIndex = channelIndex;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exiting: LTKTraceFormat::getChannelIndex()"<<endl;
- return SUCCESS;
- }
- }
-
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<ECHANNEL_NOT_FOUND <<": "<<
- getErrorMessage(ECHANNEL_NOT_FOUND) <<
- "LTKCaptureDevice::getChannelIndex()"<<endl;
-
- return ECHANNEL_NOT_FOUND;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : getChannelName
-* DESCRIPTION :
-* ARGUMENTS : channelIndex - given channel index
-* RETURNS : corresponding channel name
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-int LTKTraceFormat::getChannelName(int channelIndex,
- string& outChannelName) const
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Entering: LTKTraceFormat::getChannelName()"<<endl;
-
- if ( channelIndex < 0 || channelIndex >= m_channelVector.size() )
- {
-
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<ECHANNEL_INDEX_OUT_OF_BOUND <<": "<<
- getErrorMessage(ECHANNEL_INDEX_OUT_OF_BOUND) <<
- "LTKCaptureDevice::getChannelName()"<<endl;
-
- LTKReturnError(ECHANNEL_INDEX_OUT_OF_BOUND);
- }
-
- outChannelName = m_channelVector[channelIndex].getChannelName();
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exiting: LTKTraceFormat::getChannelName()"<<endl;
- return SUCCESS;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : getNumChannels
-* DESCRIPTION : returns the number of channels in the trace format
-* ARGUMENTS :
-* RETURNS : number of channels in the trace format
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-int LTKTraceFormat::getNumChannels() const
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Entering: LTKTraceFormat::getNumChannels()"<<endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exiting: LTKTraceFormat::getNumChannels()"<<endl;
-
- return m_channelVector.size();
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : getRegularChannelNames
-* DESCRIPTION : returns list of regular channel names
-* ARGUMENTS :
-* RETURNS : list of regular channel names
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-stringVector LTKTraceFormat::getRegularChannelNames() const
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Entering: LTKTraceFormat::getRegularChannelNames()"<<endl;
-
- stringVector regularChannelNamesVector;
-
- vector<LTKChannel>::const_iterator channelIterator = m_channelVector.begin();
-
- vector<LTKChannel>::const_iterator channelVectorEnd = m_channelVector.end();
-
- for(; channelIterator != channelVectorEnd; ++channelIterator)
- {
-
- if( (*channelIterator).isRegularChannel() )
- {
- regularChannelNamesVector.push_back((*channelIterator).getChannelName());
- }
- }
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exiting: LTKTraceFormat::getRegularChannelNames()"<<endl;
- return regularChannelNamesVector;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : getAllChannelNames
-* DESCRIPTION : returns list of all channel names
-* ARGUMENTS :
-* RETURNS : list of all channel names
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-stringVector LTKTraceFormat::getAllChannelNames() const
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Entering: LTKTraceFormat::getAllChannelNames()"<<endl;
-
- stringVector allChannelNamesVector;
-
- vector<LTKChannel>::const_iterator channelIterator = m_channelVector.begin();
-
- vector<LTKChannel>::const_iterator channelVectorEnd = m_channelVector.end();
-
- for(; channelIterator != channelVectorEnd; ++channelIterator)
- {
- allChannelNamesVector.push_back((*channelIterator).getChannelName());
- }
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exiting: LTKTraceFormat::getAllChannelNames()"<<endl;
-
- return allChannelNamesVector;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : setChannelFormat
-* DESCRIPTION : resets the channel format
-* ARGUMENTS : channelFormatVector - reference to the vector to be reset to
-* RETURNS : SUCCESS on successful reset operation
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-void LTKTraceFormat::setChannelFormat(const LTKChannelVector& channelFormatVector)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Entering: LTKTraceFormat::setChannelFormat()"<<endl;
-
- m_channelVector = channelFormatVector;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exiting: LTKTraceFormat::setChannelFormat()"<<endl;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : addChannel
-* DESCRIPTION : adds a new channel to the trace format
-* ARGUMENTS : channel - new channel to be added
-* RETURNS : SUCCESS on successful addition
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-int LTKTraceFormat::addChannel(const LTKChannel& channel)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Entering: LTKTraceFormat::addChannel()"<<endl;
-
- string inputChannelName = channel.getChannelName();
-
- // Check if the channel with the name already Exitings
- vector<LTKChannel>::const_iterator channelIterator = m_channelVector.begin();
-
- vector<LTKChannel>::const_iterator channelVectorEnd = m_channelVector.end();
-
- for(; channelIterator != channelVectorEnd; ++channelIterator)
- {
- if( (*channelIterator).getChannelName() == inputChannelName )
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<EDUPLICATE_CHANNEL <<": "<<
- getErrorMessage(EDUPLICATE_CHANNEL) <<
- "LTKCaptureDevice::addChannel()"<<endl;
-
- LTKReturnError(EDUPLICATE_CHANNEL);
- }
- }
-
- m_channelVector.push_back(channel);
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exiting: LTKTraceFormat::addChannel()"<<endl;
-
- return SUCCESS;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : ~LTKTraceFormat
-* DESCRIPTION : destructor
-* ARGUMENTS :
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-LTKTraceFormat::~LTKTraceFormat()
-{
-}
-
-
-
-
diff --git a/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/LTKTraceGroup.cpp b/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/LTKTraceGroup.cpp
deleted file mode 100644
index 282789d5..00000000
--- a/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/LTKTraceGroup.cpp
+++ /dev/null
@@ -1,1134 +0,0 @@
-/******************************************************************************
-* Copyright (c) 2006 Hewlett-Packard Development Company, L.P.
-* Permission is hereby granted, free of charge, to any person obtaining a copy
-* of this software and associated documentation files (the "Software"), to deal
-* in the Software without restriction, including without limitation the rights
-* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-* copies of the Software, and to permit persons to whom the Software is
-* furnished to do so, subject to the following conditions:
-*
-* The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
-*
-* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
-* SOFTWARE
-********************************************************************************/
-
-/******************************************************************************
- * SVN MACROS
- *
- * $LastChangedDate: 2008-07-18 15:00:39 +0530 (Fri, 18 Jul 2008) $
- * $Revision: 561 $
- * $Author: sharmnid $
- *
- ************************************************************************/
-/************************************************************************
- * FILE DESCR: Implementation of LTKTraceGroup which holds a sequence of LTKTrace type objects
- *
- * CONTENTS:
- * getAllTraces
- * getTraceAt
- * getNumTraces
- * addTrace
- * setAllTraces
- *
- * AUTHOR: Balaji R.
- *
- * DATE: December 23, 2004
- * CHANGE HISTORY:
- * Author Date Description of change
- * Deepu V. March 7, 2005 Added new assignment operator (from LTKTrace)
- * and copy constructor (from LTKTrace )
- * Thanigai 09-AUG-2005 Added a to empty the trace group
-************************************************************************/
-
-#include "LTKTraceGroup.h"
-#include "LTKTrace.h"
-#include "LTKErrors.h"
-#include "LTKErrorsList.h"
-#include "LTKLoggerUtil.h"
-#include "LTKException.h"
-#include "LTKMacros.h"
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : LTKTraceGroup
-* DESCRIPTION : Default Constructor
-* ARGUMENTS :
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-LTKTraceGroup::LTKTraceGroup() :
- m_xScaleFactor(1.0),
- m_yScaleFactor(1.0)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKTraceGroup::LTKTraceGroup()"<<endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKTraceGroup::LTKTraceGroup()"<<endl;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : LTKTraceGroup
-* DESCRIPTION : Initialization constructor
-* ARGUMENTS : inTraceVector - vector of traces to be set to class member
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-LTKTraceGroup::LTKTraceGroup(const LTKTraceVector& inTraceVector,
- float xScaleFactor, float yScaleFactor) :
- m_traceVector(inTraceVector)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKTraceGroup::LTKTraceGroup(LTKTraceVector&, float,float)"<<endl;
-
- if(xScaleFactor <= 0)
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<EINVALID_X_SCALE_FACTOR <<": "<<
- getErrorMessage(EINVALID_X_SCALE_FACTOR) <<
- "LTKTraceGroup::LTKTraceGroup(LTKTraceVector&, float,float)"<<endl;
-
- throw LTKException(EINVALID_X_SCALE_FACTOR);
- }
-
- if(yScaleFactor <= 0)
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<EINVALID_Y_SCALE_FACTOR <<": "<<
- getErrorMessage(EINVALID_Y_SCALE_FACTOR) <<
- "LTKTraceGroup::LTKTraceGroup(LTKTraceVector&, float,float)"<<endl;
-
- throw LTKException(EINVALID_Y_SCALE_FACTOR);
- }
-
- m_xScaleFactor = xScaleFactor;
- m_yScaleFactor = yScaleFactor;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKTraceGroup::LTKTraceGroup(LTKTraceVector&, float,float)"<<endl;
-
-
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : LTKTraceGroup
-* DESCRIPTION : Copy Constructor
-* ARGUMENTS : traceGroup - trace group to be copied
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-LTKTraceGroup::LTKTraceGroup(const LTKTraceGroup& traceGroup)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKTraceGroup::LTKTraceGroup(LTKTraceGroup&)"<<endl;
-
- m_traceVector = traceGroup.m_traceVector;
- m_xScaleFactor = traceGroup.m_xScaleFactor;
- m_yScaleFactor = traceGroup.m_yScaleFactor;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKTraceGroup::LTKTraceGroup(LTKTraceGroup&)"<<endl;
-
-}
-
-/******************************************************************************
-* AUTHOR : Deepu V.
-* DATE : 07-MAR-2005
-* NAME : LTKTraceGroup
-* DESCRIPTION : Constructor from LTKTrace
-* ARGUMENTS : trace - trace object to be copied
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-LTKTraceGroup::LTKTraceGroup(const LTKTrace& trace,
- float xScaleFactor, float yScaleFactor)
-{
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter:LTKTraceGroup::LTKTraceGroup(LTKTraceGroup&, float, float)"<<endl;
-
- if(xScaleFactor <= 0)
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<EINVALID_X_SCALE_FACTOR <<": "<<
- getErrorMessage(EINVALID_X_SCALE_FACTOR) <<
- "LTKTraceGroup::LTKTraceGroup(LTKTrace&, float,float)"<<endl;
-
- throw LTKException(EINVALID_X_SCALE_FACTOR);
- }
-
- if(yScaleFactor <= 0)
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<EINVALID_Y_SCALE_FACTOR <<": "<<
- getErrorMessage(EINVALID_Y_SCALE_FACTOR) <<
- "LTKTraceGroup::LTKTraceGroup(LTKTrace&, float,float)"<<endl;
-
- throw LTKException(EINVALID_Y_SCALE_FACTOR);
- }
-
- m_xScaleFactor = xScaleFactor;
- m_yScaleFactor = yScaleFactor;
-
- m_traceVector.push_back(trace);
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit:LTKTraceGroup::LTKTraceGroup(LTKTraceGroup&, float, float)"<<endl;
-
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : operator=
-* DESCRIPTION : Overloaded assignment operator
-* ARGUMENTS : traceGroup - trace group to be assigned to
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-LTKTraceGroup& LTKTraceGroup::operator=(const LTKTraceGroup& traceGroup)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKTraceGroup:: operator =(LTKTraceGroup&)"<<endl;
-
- if(this != &traceGroup)
- {
- m_traceVector = traceGroup.m_traceVector;
- m_xScaleFactor = traceGroup.m_xScaleFactor;
- m_yScaleFactor = traceGroup.m_yScaleFactor;
- }
-
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKTraceGroup:: operator =(LTKTraceGroup&)"<<endl;
-
- return *this;
-}
-
-/******************************************************************************
-* AUTHOR : Deepu V.
-* DATE : 07-MAR-2005
-* NAME : operator=
-* DESCRIPTION : Overloaded assignment operator (From LTKTrace)
-* ARGUMENTS : trace - trace to be assigned
-* RETURNS : LTKTraceGroup&
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-LTKTraceGroup& LTKTraceGroup::operator=(const LTKTrace& trace)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKTraceGroup:: operator =(LTKTrace&)"<<endl;
-
- emptyAllTraces();
- m_traceVector.push_back(trace);
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKTraceGroup:: operator =(LTKTrace&)"<<endl;
-
- return *this;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : getAllTraces
-* DESCRIPTION : gets traces composing the trace group as a vector
-* ARGUMENTS :
-* RETURNS : reference to traces composing the trace group as a vector
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-const LTKTraceVector& LTKTraceGroup::getAllTraces() const
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKTraceGroup::getAllTraces()"<<endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKTraceGroup:: getAllTraces()"<<endl;
-
- return m_traceVector;
-}
-
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : getTraceAt
-* DESCRIPTION : gets the trace at the specified index
-* ARGUMENTS : traceIndex - index of the trace to return
-* RETURNS : reference to trace at the specified index
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-int LTKTraceGroup::getTraceAt(int traceIndex, LTKTrace& outTrace) const
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKTraceGroup::getTraceAt()"<<endl;
-
- if ( traceIndex < 0 || traceIndex >= m_traceVector.size() )
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<ETRACE_INDEX_OUT_OF_BOUND <<": "<<
- getErrorMessage(ETRACE_INDEX_OUT_OF_BOUND) <<
- "LTKTraceGroup::getTraceAt()"<<endl;
-
-
- LTKReturnError(ETRACE_INDEX_OUT_OF_BOUND);
- }
-
- outTrace = m_traceVector[traceIndex];
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKTraceGroup::getTraceAt()"<<endl;
-
- return SUCCESS;
-
-}
-
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : getNumTraces
-* DESCRIPTION : gets the number of traces composing the trace group
-* ARGUMENTS :
-* RETURNS : number of traces composing the trace group
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-int LTKTraceGroup::getNumTraces () const
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKTraceGroup::getNumTraces()"<<endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "m_traceVector size = "<<m_traceVector.size()<<endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKTraceGroup::getNumTraces()"<<endl;
-
- return m_traceVector.size();
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : addTrace
-* DESCRIPTION : adds a trace to the trace group
-* ARGUMENTS : trace - trace to be added to the trace group
-* RETURNS : SUCCESS on successful addition of trace
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-*******************************************************************************/
-
-int LTKTraceGroup::addTrace(const LTKTrace& trace)
-{
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKTraceGroup::addTrace()"<<endl;
-
- m_traceVector.push_back(trace);
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKTraceGroup::addTrace()"<<endl;
-
- return SUCCESS;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : setAllTraces
-* DESCRIPTION : reassigns the trace vector member variable
-* ARGUMENTS : traceVector - vector of traces to be reassigned to
-* RETURNS : SUCCESS on successful reassignment
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-int LTKTraceGroup::setAllTraces(const LTKTraceVector& traceVector, float xScaleFactor,
- float yScaleFactor)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKTraceGroup::setAllTraces()"<<endl;
-
- if (xScaleFactor <= 0 )
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<EINVALID_X_SCALE_FACTOR <<": "<<
- getErrorMessage(EINVALID_X_SCALE_FACTOR) <<
- "LTKTraceGroup::setAllTraces()"<<endl;
-
- LTKReturnError(EINVALID_X_SCALE_FACTOR);
- }
-
- if (yScaleFactor <= 0 )
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<EINVALID_Y_SCALE_FACTOR <<": "<<
- getErrorMessage(EINVALID_Y_SCALE_FACTOR) <<
- "LTKTraceGroup::setAllTraces()"<<endl;
-
- LTKReturnError(EINVALID_Y_SCALE_FACTOR);
- }
-
-
- m_traceVector = traceVector;
- m_xScaleFactor = xScaleFactor;
- m_yScaleFactor = yScaleFactor;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKTraceGroup::setAllTraces()"<<endl;
-
- return SUCCESS;
-}
-
-
-/******************************************************************************
-* AUTHOR : Thanigai
-* DATE : 09-AUG-2005
-* NAME : emptyAllTraces
-* DESCRIPTION : To empty the trace vector
-* ARGUMENTS :
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-void LTKTraceGroup::emptyAllTraces()
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKTraceGroup::emptyAllTraces()"<<endl;
-
- m_traceVector.clear();
- m_xScaleFactor = 1.0;
- m_yScaleFactor = 1.0;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKTraceGroup::emptyAllTraces()"<<endl;
-
-}
-
-
-/******************************************************************************
-* AUTHOR : Dinesh M
-* DATE : 18-Apr-2007
-* NAME : getScale
-* DESCRIPTION :
-* ARGUMENTS :
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-float LTKTraceGroup::getXScaleFactor() const
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKTraceGroup::getXScaleFactor()"<<endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKTraceGroup::getXScaleFactor()"<<endl;
-
- return m_xScaleFactor;
-}
-
-
-/******************************************************************************
-* AUTHOR : Dinesh M
-* DATE : 18-Apr-2007
-* NAME : getScale
-* DESCRIPTION :
-* ARGUMENTS :
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-float LTKTraceGroup::getYScaleFactor() const
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKTraceGroup::getYScaleFactor()"<<endl;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKTraceGroup::getYScaleFactor()"<<endl;
-
- return m_yScaleFactor;
-}
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : getBoundingBox
-* DESCRIPTION : gets the bounding box of the incoming trace group
-* ARGUMENTS : inTraceGroup - incoming trace group
-* RETURNS : SUCCESS on successful get operation
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-*******************************************************************************/
-int LTKTraceGroup::getBoundingBox(float& outXMin,float& outYMin,
- float& outXMax,float& outYMax) const
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKTraceGroup::getBoundingBox()"<<endl;
-
- int numTraces = getNumTraces(); // number of traces in the trace group
-
- int numPoints = -1; // number of points in a trace
-
- int pointIndex = -1; // variable to loop over points of a trace
-
- int errorCode;
-
- if ( numTraces == 0 )
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<EEMPTY_TRACE_GROUP <<": "<<
- getErrorMessage(EEMPTY_TRACE_GROUP) <<
- "LTKTraceGroup::getBoundingBox()"<<endl;
-
- LTKReturnError(EEMPTY_TRACE_GROUP);
- }
-
-
- outXMin = outYMin = FLT_MAX;
- outXMax = outYMax = -FLT_MAX;
-
-
- for(int traceIndex = 0 ; traceIndex < numTraces; ++traceIndex)
- {
- const LTKTrace& tempTrace = m_traceVector[traceIndex];
-
- floatVector xVec;
-
- errorCode = tempTrace.getChannelValues(X_CHANNEL_NAME, xVec);
-
- if ( errorCode != SUCCESS )
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: LTKTraceGroup::getBoundingBox()"<<endl;
-
- LTKReturnError(errorCode);
- }
-
- floatVector yVec;
- errorCode= tempTrace.getChannelValues(Y_CHANNEL_NAME, yVec);
- if ( errorCode != SUCCESS )
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: LTKTraceGroup::getBoundingBox()"<<endl;
-
- LTKReturnError(errorCode);
- }
-
- numPoints = xVec.size();
-
- for(pointIndex =0 ; pointIndex < numPoints; pointIndex++)
- {
- float x,y;
-
- x = xVec[pointIndex];
- y = yVec[pointIndex];
-
-
- if ( x < outXMin )
- {
- outXMin = x;
- }
-
- if ( x > outXMax )
- {
- outXMax = x;
- }
-
- if ( y < outYMin )
- {
- outYMin = y;
- }
-
- if ( y > outYMax )
- {
- outYMax = y;
- }
- }
-
- }
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKTraceGroup::getBoundingBox()"<<endl;
-
-
- return SUCCESS;
-
-}
-
-
-/******************************************************************************
-* AUTHOR : Bharath A.
-* DATE : 03-SEP-2007
-* NAME : scale
-* DESCRIPTION : scales the tracegroup according to the x and y scale factors.
-* After scaling, the tracegroup is translated in order to
-* preserve the "cornerToPreserve".
-* ARGUMENTS : xScaleFactor - factor by which x dimension has to be scaled
-* yScaleFactor - factor by which y dimension has to be scaled
-* cornerToPreserve - corner to be retained after scaling
-* RETURNS : SUCCESS on successful scale operation
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-int LTKTraceGroup::scale(float xScaleFactor, float yScaleFactor,
- TGCORNER cornerToPreserve)
-{
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKTraceGroup::scale()"<<endl;
-
-
-
- LTKTrace trace;
- vector<LTKTrace> scaledTracesVec; // holds the scaled traces
-
- floatVector scaledXVec; // scaled x channel values of a trace
- floatVector scaledYVec; // scaled y channel values of a trace
-
- float x=0.0f;
- float y=0.0f;
- float xToPreserve=0.0f;
- float yToPreserve=0.0f;
- float xMin=0.0f;
- float yMin=0.0f;
- float xMax=0.0f;
- float yMax=0.0f;
-
- int numTraces=0;
- int traceIndex=0;
- int index=0;
- int numPoints=0;
- int errorCode=0;
-
- if(xScaleFactor <= 0)
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<EINVALID_X_SCALE_FACTOR <<": "<<
- getErrorMessage(EINVALID_X_SCALE_FACTOR) <<
- "LTKTraceGroup::scale()"<<endl;
-
- LTKReturnError(EINVALID_X_SCALE_FACTOR);
- }
-
- if(yScaleFactor <= 0)
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<EINVALID_Y_SCALE_FACTOR <<": "<<
- getErrorMessage(EINVALID_Y_SCALE_FACTOR) <<
- "LTKTraceGroup::scale()"<<endl;
-
- LTKReturnError(EINVALID_Y_SCALE_FACTOR);
- }
-
- errorCode = getBoundingBox(xMin, yMin, xMax, yMax);
-
- if( errorCode != SUCCESS )
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: LTKTraceGroup::scale()"<<endl;
-
- LTKReturnError(errorCode);
- }
-
- switch ( cornerToPreserve )
- {
-
- case XMIN_YMIN:
-
- xToPreserve = xMin;
- yToPreserve = yMin;
-
- break;
-
- case XMIN_YMAX:
-
- xToPreserve=xMin;
- yToPreserve=yMax;
-
- break;
-
-
- case XMAX_YMIN:
-
- xToPreserve=xMax;
- yToPreserve=yMin;
-
- break;
-
-
- case XMAX_YMAX:
- xToPreserve=xMax;
- yToPreserve=yMax;
-
- break;
-
-
- default: break;//define an exception enum input validation
-
- }
-
- numTraces = getNumTraces();
- for(traceIndex=0; traceIndex < numTraces; ++traceIndex)
- {
-
- getTraceAt(traceIndex, trace);
-
- floatVector xVec;
-
- //no error handling required as the bounding box is found
- trace.getChannelValues(X_CHANNEL_NAME, xVec);
-
-
- floatVector yVec;
-
- trace.getChannelValues(Y_CHANNEL_NAME, yVec);
-
-
- numPoints = xVec.size();
-
- for(index=0; index < numPoints; ++index)
- {
- //the additive term is to translate back the scaled tracegroup
- //so that the corner asked for is preserved
- x= ( (xVec.at(index)*xScaleFactor)/m_xScaleFactor) +
- (xToPreserve*(1-(xScaleFactor/m_xScaleFactor)) );
-
- scaledXVec.push_back(x);
-
- //the additive term is to translate back the scaled tracegroup
- //so that the corner asked for is preserved
- y= ( (yVec.at(index)*yScaleFactor)/m_yScaleFactor) +
- (yToPreserve*(1-(yScaleFactor/m_yScaleFactor)) );
-
- scaledYVec.push_back(y);
- }
-
-
- trace.reassignChannelValues(X_CHANNEL_NAME, scaledXVec);
-
- trace.reassignChannelValues(Y_CHANNEL_NAME, scaledYVec);
-
- scaledXVec.clear();
-
- scaledYVec.clear();
-
- scaledTracesVec.push_back(trace);
-
- }
-
- m_traceVector = scaledTracesVec;
-
- m_xScaleFactor = xScaleFactor;
- m_yScaleFactor = yScaleFactor;
-
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKTraceGroup::scale()"<<endl;
-
- return SUCCESS;
-}
-
-/******************************************************************************
-* AUTHOR : Bharath A.
-* DATE : 03-SEP-2007
-* NAME : translateTo
-* DESCRIPTION : translates the tracegroup so that the "referenceCorner" is
- moved to (x,y)
-* ARGUMENTS : x: x value of point to which referenceCorner has to be moved
-* y: y value of point to which referenceCorner has to be moved
-* referenceCorner - the reference corner in the tracegroup that
- has to be moved to (x,y)
-* RETURNS : SUCCESS on successful translation operation
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-*******************************************************************************/
-int LTKTraceGroup::translateTo(float x,float y,TGCORNER referenceCorner)
-{
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKTraceGroup::translateTo()"<<endl;
-
- LTKTrace trace;
-
- vector<LTKTrace> translatedTracesVec; // holds the translated traces
-
- floatVector translatedXVec; // translated x channel values of a trace
- floatVector translatedYVec; // translated y channel values of a trace
-
- float xValue, yValue;
- float xReference, yReference;
- float xMin=0.0f;
- float yMin=0.0f;
- float xMax=0.0f;
- float yMax=0.0f;
-
- int errorCode;
- int traceIndex, index;
- int numPoints;
-
-
- if((errorCode = getBoundingBox(xMin,yMin,xMax,yMax))!=SUCCESS)
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: LTKTraceGroup::translateTo()"<<endl;
-
- LTKReturnError(errorCode);
- }
-
- switch(referenceCorner)
- {
-
- case XMIN_YMIN:
-
- xReference=xMin;
- yReference=yMin;
- break;
-
- case XMIN_YMAX:
-
- xReference=xMin;
- yReference=yMax;
-
- break;
-
-
- case XMAX_YMIN:
-
- xReference=xMax;
- yReference=yMin;
-
- break;
-
-
- case XMAX_YMAX:
- xReference=xMax;
- yReference=yMax;
-
- break;
-
-
- default: break;//define an exception
-
- }
-
- int numTraces = getNumTraces();
- for(traceIndex=0; traceIndex < numTraces; ++traceIndex)
- {
- getTraceAt(traceIndex, trace);
-
- floatVector xVec;
-
- //no error handling required as the bounding box is found
- trace.getChannelValues(X_CHANNEL_NAME, xVec);
-
-
- floatVector yVec;
-
- trace.getChannelValues(Y_CHANNEL_NAME, yVec);
-
-
- numPoints = xVec.size();
-
- for(index=0; index < numPoints; index++)
- {
-
- xValue=xVec.at(index)+(x-xReference);
- translatedXVec.push_back(xValue);
-
- yValue=yVec.at(index)+(y-yReference);
- translatedYVec.push_back(yValue);
-
- }
-
- trace.reassignChannelValues(X_CHANNEL_NAME,translatedXVec);
-
- trace.reassignChannelValues(Y_CHANNEL_NAME,translatedYVec);
-
- translatedXVec.clear();
-
- translatedYVec.clear();
-
- translatedTracesVec.push_back(trace);
-
- }
-
- m_traceVector=translatedTracesVec;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Exit: LTKTraceGroup::translateTo()"<<endl;
-
- return SUCCESS;
-
-}
-
-/**********************************************************************************
-* AUTHOR : Bharath A.
-* DATE : 03-SEP-2007
-* NAME : affineTransform
-* DESCRIPTION : scales the tracegroup according to the x and y scale factors.
-* After scaling, the "referenceCorner" of the tracegroup is translated to
-* (translateToX,translateToY)
-* ARGUMENTS : xScaleFactor - factor by which x dimension has to be scaled
-* yScaleFactor - factor by which y dimension has to be scaled
-* referenceCorner - corner to be retained after scaling and moved to (translateToX,translateToY)
-* RETURNS : SUCCESS on successful scale operation
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-*************************************************************************************/
-int LTKTraceGroup::affineTransform(float xScaleFactor,float yScaleFactor,
- float translateToX,float translateToY,
- TGCORNER referenceCorner)
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKTraceGroup::translateTo()"<<endl;
-
- LTKTrace trace;
-
- vector<LTKTrace> scaledTracesVec; // holds the scaled traces
-
- floatVector scaledXVec; // scaled x channel values of a trace
- floatVector scaledYVec; // scaled y channel values of a trace
-
- float x, y;
- float xReference, yReference;
- float xMin=0.0f;
- float yMin=0.0f;
- float xMax=0.0f;
- float yMax=0.0f;
-
- int traceIndex, index;
- int errorCode;
- int numPoints;
-
- if(xScaleFactor <= 0)
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<EINVALID_X_SCALE_FACTOR <<": "<<
- getErrorMessage(EINVALID_X_SCALE_FACTOR) <<
- "LTKTraceGroup::scale()"<<endl;
-
- LTKReturnError(EINVALID_X_SCALE_FACTOR);
- }
-
- if(yScaleFactor <= 0)
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: "<<EINVALID_X_SCALE_FACTOR <<": "<<
- getErrorMessage(EINVALID_X_SCALE_FACTOR) <<
- "LTKTraceGroup::scale()"<<endl;
-
- LTKReturnError(EINVALID_Y_SCALE_FACTOR);
- }
-
- if((errorCode = getBoundingBox(xMin,yMin,xMax,yMax))!=SUCCESS)
- {
- LOG( LTKLogger::LTK_LOGLEVEL_ERR) <<
- "Error: LTKTraceGroup::affineTransform()"<<endl;
-
- LTKReturnError(errorCode);
- }
-
- switch(referenceCorner)
- {
-
- case XMIN_YMIN:
-
- xReference=xMin;
- yReference=yMin;
- break;
-
- case XMIN_YMAX:
-
- xReference=xMin;
- yReference=yMax;
-
- break;
-
- case XMAX_YMIN:
-
- xReference=xMax;
- yReference=yMin;
-
- break;
-
- case XMAX_YMAX:
- xReference=xMax;
- yReference=yMax;
-
- break;
-
- default: break;//define an exception
-
- }
-
- int numTraces = m_traceVector.size();
- for(traceIndex=0; traceIndex < numTraces; ++traceIndex)
- {
- getTraceAt(traceIndex, trace);
-
- floatVector xVec;
-
- //no error handling required as the bounding box is found
- trace.getChannelValues(X_CHANNEL_NAME, xVec);
-
-
- floatVector yVec;
-
-
- trace.getChannelValues(Y_CHANNEL_NAME, yVec);
-
-
- numPoints = xVec.size();
-
- for(index=0; index < numPoints; index++)
- {
- //the additive term is to translate back the scaled tracegroup
- //so that the corner asked for is preserved at the destination
- //(translateToX,translateToY)
- x = ( (xVec.at(index) * xScaleFactor)/m_xScaleFactor) +
- (translateToX - (xReference*(xScaleFactor/m_xScaleFactor)) );
-
- scaledXVec.push_back(x);
-
- //the additive term is to translate back the scaled tracegroup
- //so that the corner asked for is preserved at the destination
- //(translateToX,translateToY)
- y= ( (yVec.at(index) * yScaleFactor)/m_yScaleFactor) +
- (translateToY - (yReference*(yScaleFactor/m_yScaleFactor)));
-
- scaledYVec.push_back(y);
-
- }
-
- trace.reassignChannelValues(X_CHANNEL_NAME,scaledXVec);
-
- trace.reassignChannelValues(Y_CHANNEL_NAME,scaledYVec);
-
- scaledXVec.clear();
-
- scaledYVec.clear();
-
- scaledTracesVec.push_back(trace);
-
- }
-
-
- m_traceVector = scaledTracesVec;
-
- m_xScaleFactor = xScaleFactor;
- m_yScaleFactor = yScaleFactor;
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG) <<
- "Enter: LTKTraceGroup::affineTransform()"<<endl;
-
- return SUCCESS;
-}
-
-
-/******************************************************************************
-* AUTHOR : Balaji R.
-* DATE : 23-DEC-2004
-* NAME : ~LTKTraceGroup
-* DESCRIPTION : destructor
-* ARGUMENTS :
-* RETURNS :
-* NOTES :
-* CHANGE HISTROY
-* Author Date Description of change
-******************************************************************************/
-
-LTKTraceGroup::~LTKTraceGroup()
-{
-
-}
-/**********************************************************************************
- * AUTHOR : Saravanan. R
- * DATE : 30-01-2007
- * NAME : checkEmptyTraces
- * DESCRIPTION : This method checks for empty traces
- * ARGUMENTS : inTraceGroup : LTKTraceGroup :
- * RETURNS : 1 if it contains empty trace group, 0 otherwise
- * NOTES :
- * CHANGE HISTROY
- * Author Date Description
- *************************************************************************************/
-bool LTKTraceGroup::containsAnyEmptyTrace() const
-{
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG)<<
- "Entering LTKTraceGroup::containsAnyEmptyTrace()" <<endl;
-
-
- const vector<LTKTrace>& tracesVec = getAllTraces(); //traces in trace group
-
- int numTraces = tracesVec.size();
-
- if(numTraces == 0)
- {
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG)<<
- "Numer of traces in the tracegroup=0 "
- " LTKTraceGroup::containsAnyEmptyTrace()" <<endl;
- return true;
- }
-
- for(int traceIndex=0; traceIndex < numTraces; ++traceIndex)
- {
- const LTKTrace& trace = tracesVec.at(traceIndex);
-
- if(trace.isEmpty())
- {
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG)<<
- "Trace is Empty "
- " LTKTraceGroup::containsAnyEmptyTrace()" <<endl;
- return true;
- }
- }
-
- LOG( LTKLogger::LTK_LOGLEVEL_DEBUG)<<
- "Exiting LTKTraceGroup::containsAnyEmptyTrace()" <<endl;
- return false;
-}
diff --git a/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/common.pro b/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/common.pro
deleted file mode 100644
index 4c049058..00000000
--- a/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/common/common.pro
+++ /dev/null
@@ -1,16 +0,0 @@
-BASE_TARGET_NAME = ltkcommon
-include(../lipilib.pri)
-
-INCLUDEPATH += \
- ../util/lib
-
-SOURCES += \
- LTKCaptureDevice.cpp \
- LTKChannel.cpp \
- LTKException.cpp \
- LTKScreenContext.cpp \
- LTKTrace.cpp \
- LTKTraceFormat.cpp \
- LTKTraceGroup.cpp
-
-include(../include/headers.pri)