(PanGesture)Added environment variable to change pan gesture prediction mode 62/19962/1
authorJulien Heanley <j.heanley@partner.samsung.com>
Thu, 10 Apr 2014 12:51:34 +0000 (13:51 +0100)
committerAndrew Cox <andrew.cox@partner.samsung.com>
Wed, 23 Apr 2014 19:02:20 +0000 (20:02 +0100)
[Issue#]   N/A
[Problem]
[Cause]
[Solution]

Change-Id: I8bc69e6efe6564cb3b4dd00b84a1c5b9892f1d14
Signed-off-by: Andrew Cox <andrew.cox@partner.samsung.com>
18 files changed:
adaptors/base/environment-options.cpp [moved from adaptors/base/log-options.cpp with 69% similarity]
adaptors/base/environment-options.h [moved from adaptors/base/log-options.h with 68% similarity]
adaptors/base/environment-variables.h
adaptors/base/file.list
adaptors/base/performance-logging/performance-interface-factory.cpp
adaptors/base/performance-logging/performance-interface-factory.h
adaptors/base/performance-logging/performance-server.cpp
adaptors/base/performance-logging/performance-server.h
adaptors/base/render-thread.cpp
adaptors/base/render-thread.h
adaptors/base/update-render-controller.cpp
adaptors/base/update-render-controller.h
adaptors/base/update-thread.cpp
adaptors/base/update-thread.h
adaptors/base/vsync-notifier.cpp
adaptors/base/vsync-notifier.h
adaptors/tizen/internal/common/adaptor-impl.cpp
adaptors/tizen/internal/common/adaptor-impl.h

similarity index 69%
rename from adaptors/base/log-options.cpp
rename to adaptors/base/environment-options.cpp
index 9efea66..819b77b 100644 (file)
@@ -15,7 +15,7 @@
 //
 
 // CLASS HEADER
-#include "log-options.h"
+#include "environment-options.h"
 
 namespace Dali
 {
@@ -26,7 +26,7 @@ namespace Internal
 namespace Adaptor
 {
 
-LogOptions::LogOptions()
+EnvironmentOptions::EnvironmentOptions()
 : mFpsFrequency(0),
   mUpdateStatusFrequency(0),
   mPerformanceLoggingLevel(0),
@@ -35,11 +35,11 @@ LogOptions::LogOptions()
 {
 }
 
-LogOptions::~LogOptions()
+EnvironmentOptions::~EnvironmentOptions()
 {
 }
 
-void LogOptions::SetOptions( const Dali::Integration::Log::LogFunction& logFunction,
+void EnvironmentOptions::SetLogOptions( const Dali::Integration::Log::LogFunction& logFunction,
                              unsigned int logFrameRateFrequency,
                              unsigned int logupdateStatusFrequency,
                              unsigned int logPerformanceLevel,
@@ -52,36 +52,41 @@ void LogOptions::SetOptions( const Dali::Integration::Log::LogFunction& logFunct
   mPanGestureLoggingLevel = logPanGestureLevel;
 }
 
-void LogOptions::InstallLogFunction() const
+void EnvironmentOptions::InstallLogFunction() const
 {
   Dali::Integration::Log::InstallLogFunction( mLogFunction );
 }
 
-void LogOptions::UnInstallLogFunction() const
+void EnvironmentOptions::UnInstallLogFunction() const
 {
   Dali::Integration::Log::UninstallLogFunction();
 }
 
-unsigned int LogOptions::GetFrameRateLoggingFrequency() const
+unsigned int EnvironmentOptions::GetFrameRateLoggingFrequency() const
 {
   return mFpsFrequency;
 }
 
-unsigned int LogOptions::GetUpdateStatusLoggingFrequency() const
+unsigned int EnvironmentOptions::GetUpdateStatusLoggingFrequency() const
 {
   return mUpdateStatusFrequency;
 }
 
-unsigned int LogOptions::GetPerformanceLoggingLevel() const
+unsigned int EnvironmentOptions::GetPerformanceLoggingLevel() const
 {
   return mPerformanceLoggingLevel;
 }
 
-unsigned int LogOptions::GetPanGestureLoggingLevel() const
+unsigned int EnvironmentOptions::GetPanGestureLoggingLevel() const
 {
   return mPanGestureLoggingLevel;
 }
 
+unsigned int EnvironmentOptions::GetPanGestureSmoothingMode() const
+{
+  return mPanGesturePredictionMode;
+}
+
 } // Adaptor
 
 } // Internal
similarity index 68%
rename from adaptors/base/log-options.h
rename to adaptors/base/environment-options.h
index 038a437..63c2f34 100644 (file)
@@ -1,5 +1,5 @@
-#ifndef __DALI_INTERNAL_ADAPTOR_LOG_OPTIONS_H__
-#define __DALI_INTERNAL_ADAPTOR_LOG_OPTIONS_H__
+#ifndef __DALI_INTERNAL_ADAPTOR_ENVIRONMENT_OPTIONS_H__
+#define __DALI_INTERNAL_ADAPTOR_ENVIRONMENT_OPTIONS_H__
 
 //
 // Copyright (c) 2014 Samsung Electronics Co., Ltd.
@@ -27,9 +27,9 @@ namespace Adaptor
 {
 
 /**
- * Contains log settings and the ability to install a log function.
+ * Contains environment options which define settings and the ability to install a log function.
  */
-class LogOptions
+class EnvironmentOptions
 {
 
 public:
@@ -37,12 +37,12 @@ public:
   /**
    * Constructor
    */
-  LogOptions();
+  EnvironmentOptions();
 
   /**
    * non-virtual destructor, not intended as a base class
    */
-  ~LogOptions();
+  ~EnvironmentOptions();
 
   /**
    * @param logFunction logging function
@@ -52,11 +52,11 @@ public:
    * @param logPerformanceLevel performance logging, 0 = disabled,  1+ =  enabled
    * @param logPanGestureLevel pan-gesture logging, 0 = disabled,  1 = enabled
    */
-  void SetOptions( const Dali::Integration::Log::LogFunction& logFunction,
-                   unsigned int logFrameRateFrequency,
-                   unsigned int logupdateStatusFrequency,
-                   unsigned int logPerformanceLevel,
-                   unsigned int logPanGestureLevel );
+  void SetLogOptions( const Dali::Integration::Log::LogFunction& logFunction,
+                       unsigned int logFrameRateFrequency,
+                       unsigned int logupdateStatusFrequency,
+                       unsigned int logPerformanceLevel,
+                       unsigned int logPanGestureLevel );
 
   /**
    * Install the log function for the current thread.
@@ -88,20 +88,33 @@ public:
    */
   unsigned int GetPanGestureLoggingLevel() const;
 
+  /**
+   * @return pan-gesture smoothing mode ( 0 == no smoothing )
+   */
+  unsigned int GetPanGestureSmoothingMode() const;
+
+  /**
+   * @brief Sets the mode used to smooth pan gesture movement properties calculated on the Update thread
+   *
+   * @param[in] mode The smoothing mode to use
+   */
+  void SetPanGesturePredictionMode(unsigned int mode) { mPanGesturePredictionMode = mode; }
+
 private:
 
   unsigned int mFpsFrequency;                     ///< how often fps is logged out in seconds
   unsigned int mUpdateStatusFrequency;            ///< how often update status is logged out in frames
   unsigned int mPerformanceLoggingLevel;          ///< performance log level
   unsigned int mPanGestureLoggingLevel;           ///< pan-gesture log level
+  unsigned int mPanGesturePredictionMode;         ///< prediction mode for pan gestures
 
   Dali::Integration::Log::LogFunction mLogFunction;
 
   // Undefined copy constructor.
-  LogOptions( const LogOptions& );
+  EnvironmentOptions( const EnvironmentOptions& );
 
   // Undefined assignment operator.
-  LogOptions& operator=( const LogOptions& );
+  EnvironmentOptions& operator=( const EnvironmentOptions& );
 
 };
 
@@ -109,4 +122,4 @@ private:
 } // Internal
 } // Dali
 
-#endif // __DALI_INTERNAL_ADAPTOR_LOG_OPTIONS_H__
+#endif // __DALI_INTERNAL_ADAPTOR_ENVIRONMENT_OPTIONS_H__
index 13f86b9..f7c80c7 100644 (file)
@@ -30,6 +30,8 @@ namespace Adaptor
 
 #define DALI_ENV_LOG_PAN_GESTURE "DALI_LOG_PAN_GESTURE"
 
+#define DALI_ENV_PAN_PREDICTION_MODE "DALI_PAN_PREDICTION_MODE"
+
 } // namespace Adaptor
 
 } // namespace Internal
index dc84d61..5f29336 100644 (file)
@@ -7,7 +7,7 @@ base_adaptor_src_files = \
   $(base_adaptor_src_dir)/update-render-controller.cpp \
   $(base_adaptor_src_dir)/vsync-notifier.cpp \
   $(base_adaptor_src_dir)/performance-logging/frame-time-stamp.cpp \
-  $(base_adaptor_src_dir)/log-options.cpp \
+  $(base_adaptor_src_dir)/environment-options.cpp \
   $(base_adaptor_src_dir)/performance-logging/frame-time-stats.cpp \
   $(base_adaptor_src_dir)/performance-logging/performance-marker.cpp \
   $(base_adaptor_src_dir)/performance-logging/performance-server.cpp \
index eae83b9..748a2f3 100644 (file)
@@ -29,9 +29,9 @@ namespace Adaptor
 
 PerformanceInterface* PerformanceInterfaceFactory::CreateInterface(
                                  AdaptorInternalServices& adaptorServices,
-                                 const LogOptions& logOptions  )
+                                 const EnvironmentOptions& environmentOptions  )
 {
-  return new PerformanceServer( adaptorServices, logOptions );
+  return new PerformanceServer( adaptorServices, environmentOptions );
 }
 
 
index f32ac80..4531955 100644 (file)
@@ -20,7 +20,7 @@
 // INTERNAL INCLUDES
 #include <base/interfaces/adaptor-internal-services.h>
 #include <dali/integration-api/debug.h>
-#include <base/log-options.h>
+#include <base/environment-options.h>
 
 namespace Dali
 {
@@ -42,11 +42,11 @@ public:
   /**
    * Create a new concrete implementation of the performance interface.
    * @param adaptorServices adaptor internal services
-   * @param logOptions log options
+   * @param environmentOptions environment options
    * @return pointer to a new performance interface
    */
   static PerformanceInterface* CreateInterface( AdaptorInternalServices& adaptorServices,
-                                                const LogOptions& logOptions );
+                                                const EnvironmentOptions& environmentOptions );
 
 };
 
index b15cb2d..473eb1b 100644 (file)
@@ -18,7 +18,7 @@
 #include "performance-server.h"
 
 // INTERNAL INCLUDES
-#include <base/log-options.h>
+#include <base/environment-options.h>
 
 namespace Dali
 {
@@ -42,22 +42,22 @@ const unsigned int MICROSECONDS_PER_SECOND = 1000000; ///< 1000000 microseconds
 
 
 PerformanceServer::PerformanceServer( AdaptorInternalServices& adaptorServices,
-                                      const LogOptions& logOptions)
+                                      const EnvironmentOptions& environmentOptions)
 :mLoggingEnabled( false),
  mLogFunctionInstalled( false ),
  mLogFrequencyMicroseconds( 0),
  mPlatformAbstraction( adaptorServices.GetPlatformAbstractionInterface() ),
- mLogOptions(logOptions),
+ mEnvironmentOptions(environmentOptions),
  mKernelTrace( adaptorServices.GetKernelTraceInterface() )
 {
-  SetLogging( mLogOptions.GetPerformanceLoggingLevel(), mLogOptions.GetFrameRateLoggingFrequency());
+  SetLogging( mEnvironmentOptions.GetPerformanceLoggingLevel(), mEnvironmentOptions.GetFrameRateLoggingFrequency());
 }
 
 PerformanceServer::~PerformanceServer()
 {
   if( mLogFunctionInstalled )
   {
-    mLogOptions.UnInstallLogFunction();
+    mEnvironmentOptions.UnInstallLogFunction();
   }
 }
 void PerformanceServer::SetLogging( unsigned int level, unsigned int interval)
@@ -139,7 +139,7 @@ void PerformanceServer::LogMarker(const char* name, const FrameTimeStats& frameS
   // if the v-sync thread has already installed one, it won't make any difference.
   if(! mLogFunctionInstalled )
   {
-    mLogOptions.InstallLogFunction();
+    mEnvironmentOptions.InstallLogFunction();
     mLogFunctionInstalled = true;
   }
 
index 06b6ad5..d3193ff 100644 (file)
@@ -34,7 +34,7 @@ namespace Internal
 namespace Adaptor
 {
 
-class LogOptions;
+class EnvironmentOptions;
 /**
  * Concrete implementation of performance interface.
  * Adaptor classes should never include this file, they
@@ -48,10 +48,10 @@ public:
   /**
    * Constructor
    * @param adaptorServices adaptor internal services
-   * @param logOptions log options
+   * @param environmentOptions environment options
    */
   PerformanceServer( AdaptorInternalServices& adaptorServices,
-                     const LogOptions& logOptions );
+                     const EnvironmentOptions& environmentOptions );
 
   /**
    * Destructor
@@ -103,7 +103,7 @@ private:
   typedef Dali::Vector<PerformanceMarker > MarkerVector;
   MarkerVector mMarkers;              ///< vector of markers
   boost::mutex mDataMutex;            ///< mutex
-  const LogOptions& mLogOptions;      ///< log options
+  const EnvironmentOptions& mEnvironmentOptions;      ///< environment options
   KernelTraceInterface& mKernelTrace; ///< kernel trace interface
 
 };
index 387f4ad..d547950 100644 (file)
@@ -22,7 +22,7 @@
 #include <dali/integration-api/debug.h>
 #include <base/interfaces/adaptor-internal-services.h>
 #include <base/update-render-synchronization.h>
-#include <base/log-options.h>
+#include <base/environment-options.h>
 
 
 namespace Dali
@@ -43,7 +43,7 @@ const unsigned int TIME_PER_FRAME_IN_MICROSECONDS = 16667;
 
 RenderThread::RenderThread( UpdateRenderSynchronization& sync,
                             AdaptorInternalServices& adaptorInterfaces,
-                            const LogOptions& logOptions )
+                            const EnvironmentOptions& environmentOptions )
 : mUpdateRenderSync( sync ),
   mCore( adaptorInterfaces.GetCore() ),
   mGLES( adaptorInterfaces.GetGlesInterface() ),
@@ -53,7 +53,7 @@ RenderThread::RenderThread( UpdateRenderSynchronization& sync,
   mSurfaceReplacing( false ),
   mNewDataAvailable( false ),
   mSurfaceReplaceCompleted( false ),
-  mLogOptions( logOptions )
+  mEnvironmentOptions( environmentOptions )
 {
   // set the initial values before render thread starts
   mCurrent.surface = adaptorInterfaces.GetRenderSurfaceInterface();
@@ -155,7 +155,7 @@ void RenderThread::RenderSync()
 bool RenderThread::Run()
 {
   // install a function for logging
-  mLogOptions.InstallLogFunction();
+  mEnvironmentOptions.InstallLogFunction();
 
   InitializeEgl();
 
@@ -212,7 +212,7 @@ bool RenderThread::Run()
   ShutdownEgl();
 
   // install a function for logging
-  mLogOptions.UnInstallLogFunction();
+  mEnvironmentOptions.UnInstallLogFunction();
 
   return true;
 }
index 3330ffa..04eaa8b 100644 (file)
@@ -43,7 +43,7 @@ class AdaptorInternalServices;
 class RenderSurface;
 class UpdateRenderSynchronization;
 class EglFactoryInterface;
-class LogOptions;
+class EnvironmentOptions;
 
 /**
  * The render-thread is responsible for calling Core::Render() after each update.
@@ -55,12 +55,12 @@ public:
    * Create the render-thread; this will not do anything until Start() is called.
    * @param[in] sync update-render synchronization object
    * @param[in] adaptorInterfaces base adaptor interface
-   * @param[in] logOptions log options
+   * @param[in] environmentOptions environment options
 
    */
   RenderThread( UpdateRenderSynchronization& sync,
                 AdaptorInternalServices& adaptorInterfaces,
-                const LogOptions& logOptions );
+                const EnvironmentOptions& environmentOptions );
 
   /**
    * Virtual Destructor
@@ -232,7 +232,7 @@ private: // Data
   boost::mutex              mSurfaceChangedMutex;  ///< mutex to lock during surface replacing
   boost::condition_variable mSurfaceChangedNotify; ///< condition to notify main thread that surface has been changed
   bool                      mSurfaceReplaceCompleted;///< true, while render thread is running and needs to wait for pixmap syncs
-  const LogOptions&         mLogOptions;           ///< Log options
+  const EnvironmentOptions& mEnvironmentOptions;     ///< Environment options
 
 };
 
index a66a3ef..bdc8a0f 100644 (file)
@@ -23,7 +23,7 @@
 #include <base/update-render-synchronization.h>
 #include <base/vsync-notifier.h>
 #include <base/interfaces/adaptor-internal-services.h>
-#include <base/log-options.h>
+#include <base/environment-options.h>
 
 
 namespace Dali
@@ -36,7 +36,7 @@ namespace Adaptor
 {
 
 UpdateRenderController::UpdateRenderController( AdaptorInternalServices& adaptorInterfaces,
-                                                const LogOptions& logOptions ): mUpdateThread( NULL ),
+                                                const EnvironmentOptions& environmentOptions ): mUpdateThread( NULL ),
   mRenderThread( NULL ),
   mVSyncNotifier( NULL ),
   mUpdateRenderSync( NULL )
@@ -44,11 +44,11 @@ UpdateRenderController::UpdateRenderController( AdaptorInternalServices& adaptor
 
   mUpdateRenderSync = new UpdateRenderSynchronization( adaptorInterfaces );
 
-  mUpdateThread = new UpdateThread( *mUpdateRenderSync, adaptorInterfaces, logOptions );
+  mUpdateThread = new UpdateThread( *mUpdateRenderSync, adaptorInterfaces, environmentOptions );
 
-  mRenderThread = new RenderThread( *mUpdateRenderSync, adaptorInterfaces, logOptions );
+  mRenderThread = new RenderThread( *mUpdateRenderSync, adaptorInterfaces, environmentOptions );
 
-  mVSyncNotifier = new VSyncNotifier( *mUpdateRenderSync, adaptorInterfaces, logOptions );
+  mVSyncNotifier = new VSyncNotifier( *mUpdateRenderSync, adaptorInterfaces, environmentOptions );
 }
 
 UpdateRenderController::~UpdateRenderController()
index 88f1063..21d088c 100644 (file)
@@ -32,7 +32,7 @@ class VSyncNotifier;
 class UpdateRenderSynchronization;
 class RenderSurface;
 class AdaptorInternalServices;
-class LogOptions;
+class EnvironmentOptions;
 
 /**
  * Class to control the update and render threads.
@@ -44,7 +44,7 @@ public:
   /**
    * Constructor
    */
-  UpdateRenderController( AdaptorInternalServices& adaptorInterfaces, const LogOptions& logOptions );
+  UpdateRenderController( AdaptorInternalServices& adaptorInterfaces, const EnvironmentOptions& environmentOptions );
 
   /**
    * Non virtual destructor. Not intended as base class.
index 6db13b0..1fda533 100644 (file)
@@ -27,7 +27,7 @@
 #include <dali/integration-api/debug.h>
 #include <base/interfaces/adaptor-internal-services.h>
 #include <base/update-render-synchronization.h>
-#include <base/log-options.h>
+#include <base/environment-options.h>
 
 namespace Dali
 {
@@ -47,17 +47,17 @@ const unsigned int MICROSECONDS_PER_MILLISECOND( 1000 );
 
 UpdateThread::UpdateThread( UpdateRenderSynchronization& sync,
                             AdaptorInternalServices& adaptorInterfaces,
-                            const LogOptions& logOptions )
+                            const EnvironmentOptions& environmentOptions )
 : mUpdateRenderSync( sync ),
   mCore( adaptorInterfaces.GetCore()),
-  mFpsTrackingSeconds( logOptions.GetFrameRateLoggingFrequency() ),
+  mFpsTrackingSeconds( environmentOptions.GetFrameRateLoggingFrequency() ),
   mElapsedTime( 0.0f ),
   mElapsedSeconds( 0u ),
-  mStatusLogInterval( logOptions.GetUpdateStatusLoggingFrequency() ),
+  mStatusLogInterval( environmentOptions.GetUpdateStatusLoggingFrequency() ),
   mStatusLogCount( 0u ),
   mNotificationTrigger( adaptorInterfaces.GetTriggerEventInterface() ),
   mThread( NULL ),
-  mLogOptions( logOptions )
+  mEnvironmentOptions( environmentOptions )
 {
   if( mFpsTrackingSeconds > 0 )
   {
@@ -100,7 +100,7 @@ bool UpdateThread::Run()
   Integration::UpdateStatus status;
 
   // install a function for logging
-  mLogOptions.InstallLogFunction();
+  mEnvironmentOptions.InstallLogFunction();
 
   bool running( true );
 
@@ -154,7 +154,7 @@ bool UpdateThread::Run()
   }
 
   // uninstall a function for logging
-  mLogOptions.UnInstallLogFunction();
+  mEnvironmentOptions.UnInstallLogFunction();
 
   return true;
 }
index ce02a19..4b58aac 100644 (file)
@@ -44,7 +44,7 @@ namespace Adaptor
 class UpdateRenderSynchronization;
 class AdaptorInternalServices;
 class TriggerEventInterface;
-class LogOptions;
+class EnvironmentOptions;
 
 /**
  * The update-thread is responsible for calling Core::Update(), and
@@ -58,11 +58,11 @@ public:
    * Create the update-thread; this will not do anything until Start() is called.
    * @param[in] sync An object used to synchronize update & render threads.
    * @param[in] adaptorInterfaces base adaptor interface
-   * @param[in] LogOptions log functions
+   * @param[in] environmentOptions environment options
    */
   UpdateThread(UpdateRenderSynchronization& sync,
                AdaptorInternalServices& adaptorInterfaces,
-               const LogOptions& logOptions );
+               const EnvironmentOptions& environmentOptions );
 
   /**
    * Non-virtual destructor; UpdateThread is not suitable as a base class.
@@ -123,7 +123,7 @@ private: // Data
   TriggerEventInterface&              mNotificationTrigger; ///< Reference to notification event trigger
 
   boost::thread*                      mThread;              ///< The actual update-thread.
-  const LogOptions&                   mLogOptions;          ///< Log options
+  const EnvironmentOptions&           mEnvironmentOptions;  ///< environment options
 }; // class UpdateThread
 
 } // namespace Adaptor
index 667e708..5dc5742 100644 (file)
@@ -28,7 +28,7 @@
 #include "vsync-notifier.h"
 #include <base/interfaces/adaptor-internal-services.h>
 #include <base/update-render-synchronization.h>
-#include <base/log-options.h>
+#include <base/environment-options.h>
 
 namespace Dali
 {
@@ -53,13 +53,13 @@ Integration::Log::Filter* gLogFilter = Integration::Log::Filter::New(Debug::Conc
 
 VSyncNotifier::VSyncNotifier( UpdateRenderSynchronization& sync,
                               AdaptorInternalServices& adaptorInterfaces,
-                              const LogOptions& logOptions )
+                              const EnvironmentOptions& environmentOptions )
 : mUpdateRenderSync( sync ),
   mCore( adaptorInterfaces.GetCore() ),
   mPlatformAbstraction( adaptorInterfaces.GetPlatformAbstractionInterface() ),
   mVSyncMonitor( adaptorInterfaces.GetVSyncMonitorInterface() ),
   mThread( NULL ),
-  mLogOptions( logOptions )
+  mEnvironmentOptions( environmentOptions )
 {
 }
 
@@ -107,7 +107,7 @@ void VSyncNotifier::Stop()
 void VSyncNotifier::Run()
 {
   // install a function for logging
-  mLogOptions.InstallLogFunction();
+  mEnvironmentOptions.InstallLogFunction();
 
   unsigned int frameNumber( 0u );             // frameCount, updated when the thread is paused
   unsigned int currentSequenceNumber( 0u );   // platform specific vsync sequence number (increments with each vsync)
@@ -162,7 +162,7 @@ void VSyncNotifier::Run()
   }
 
   // uninstall a function for logging
-  mLogOptions.UnInstallLogFunction();
+  mEnvironmentOptions.UnInstallLogFunction();
 
 }
 
index 7d2edbc..051f2ac 100644 (file)
@@ -43,7 +43,7 @@ namespace Adaptor
 
 class VSyncMonitorInterface;
 class UpdateRenderSynchronization;
-class LogOptions;
+class EnvironmentOptions;
 class AdaptorInternalServices;
 
 /**
@@ -59,11 +59,11 @@ public:
    * send notifications until Start() is called.
    * @param[in] sync         An object used to synchronize update, render and vsync threads.
    * @param[in] adaptorInterfaces base adaptor interface
-   * @param[in] logOption    Log options
+   * @param[in] environmentOptions environment options
    */
   VSyncNotifier( UpdateRenderSynchronization& sync,
                  AdaptorInternalServices& adaptorInterfaces,
-                 const LogOptions& logOptions);
+                 const EnvironmentOptions& environmentOptions);
 
   /**
    * Non-virtual destructor; VSyncNotifier is not suitable as a base class.
@@ -95,7 +95,7 @@ private:
   Integration::PlatformAbstraction&   mPlatformAbstraction; ///< The platform abstraction for retrieving the current time etc.
   VSyncMonitorInterface*              mVSyncMonitor;        ///< VSyncMonitor interface
   boost::thread*                      mThread;              ///< The actual thread.
-  const LogOptions&                   mLogOptions;          ///< Log options
+  const EnvironmentOptions&           mEnvironmentOptions;  ///< Environment options
 
 }; // class VSyncNotifier
 
index 53bc239..95cc208 100644 (file)
@@ -90,7 +90,7 @@ Dali::Adaptor* Adaptor::New( RenderSurface *surface, const DeviceLayout& baseLay
   return adaptor;
 }
 
-void Adaptor::ParseLogOptions()
+void Adaptor::ParseEnvironmentOptions()
 {
   // get logging options
   unsigned int logFrameRateFrequency = GetIntegerEnvironmentVariable( DALI_ENV_FPS_TRACKING, 0 );
@@ -98,25 +98,24 @@ void Adaptor::ParseLogOptions()
   unsigned int logPerformanceLevel = GetIntegerEnvironmentVariable( DALI_ENV_LOG_PERFORMANCE, 0 );
   unsigned int logPanGesture = GetIntegerEnvironmentVariable( DALI_ENV_LOG_PAN_GESTURE, 0 );
 
+  // all threads here (event, update, and render) will send their logs to SLP Platform's LogMessage handler.
   Dali::Integration::Log::LogFunction  logFunction(Dali::SlpPlatform::LogMessage);
 
-  mLogOptions.SetOptions( logFunction, logFrameRateFrequency, logupdateStatusFrequency, logPerformanceLevel, logPanGesture );
-
-  // all threads here (event, update, and render) will send their logs to SLP Platform's LogMessage handler.
-  // Dali::Integration::Log::LogFunction logFunction(Dali::SlpPlatform::LogMessage);
+  mEnvironmentOptions.SetLogOptions( logFunction, logFrameRateFrequency, logupdateStatusFrequency, logPerformanceLevel, logPanGesture );
+  mEnvironmentOptions.SetPanGesturePredictionMode(GetIntegerEnvironmentVariable( DALI_ENV_PAN_PREDICTION_MODE, 1));
 
-  mLogOptions.InstallLogFunction();
+  mEnvironmentOptions.InstallLogFunction();
 }
 
 void Adaptor::Initialize()
 {
-  ParseLogOptions();
+  ParseEnvironmentOptions();
 
   mPlatformAbstraction = new SlpPlatform::SlpPlatformAbstraction;
 
-  if( mLogOptions.GetPerformanceLoggingLevel() > 0 )
+  if( mEnvironmentOptions.GetPerformanceLoggingLevel() > 0 )
   {
-    mPerformanceInterface = PerformanceInterfaceFactory::CreateInterface( *this, mLogOptions );
+    mPerformanceInterface = PerformanceInterfaceFactory::CreateInterface( *this, mEnvironmentOptions );
   }
 
   mCallbackManager = CallbackManager::New();
@@ -137,15 +136,16 @@ void Adaptor::Initialize()
 
   mVSyncMonitor = new VSyncMonitor;
 
-  mUpdateRenderController = new UpdateRenderController( *this, mLogOptions );
+  mUpdateRenderController = new UpdateRenderController( *this, mEnvironmentOptions );
 
   mDaliFeedbackPlugin = new FeedbackPluginProxy( FeedbackPluginProxy::DEFAULT_OBJECT_NAME );
 
   // Should be called after Core creation
-  if( mLogOptions.GetPanGestureLoggingLevel() )
+  if( mEnvironmentOptions.GetPanGestureLoggingLevel() )
   {
     Integration::EnableProfiling( Dali::Integration::PROFILING_TYPE_PAN_GESTURE );
   }
+  Integration::SetPanGesturePredictionMode(mEnvironmentOptions.GetPanGestureSmoothingMode());
 }
 
 Adaptor::~Adaptor()
@@ -794,7 +794,7 @@ Adaptor::Adaptor(Dali::Adaptor& adaptor, RenderSurface* surface, const DeviceLay
   mDragAndDropDetector(),
   mDeferredRotationObserver(NULL),
   mBaseLayout(baseLayout),
-  mLogOptions(),
+  mEnvironmentOptions(),
   mPerformanceInterface(NULL)
 {
   DALI_ASSERT_ALWAYS( gThreadLocalAdaptor.get() == NULL && "Cannot create more than one Adaptor per thread" );
index 4ec0b02..46f1762 100644 (file)
@@ -37,7 +37,7 @@
 
 #include <slp-platform-abstraction.h>
 #include <base/interfaces/adaptor-internal-services.h>
-#include <base/log-options.h>
+#include <base/environment-options.h>
 #include <base/core-event-interface.h>
 #include <internal/common/drag-and-drop-detector-impl.h>
 #include <internal/common/damage-observer.h>
@@ -437,7 +437,7 @@ private:
   /**
    * Helper to parse log options
    */
-  void ParseLogOptions();
+  void ParseEnvironmentOptions();
 
   /**
    * Informs core the surface size has changed
@@ -513,7 +513,7 @@ private: // Data
   DragAndDropDetectorPtr                mDragAndDropDetector;         ///< The Drag & Drop detector
   RotationObserver*                     mDeferredRotationObserver;    ///< deferred Rotation observer needs event handler
   DeviceLayout                          mBaseLayout;                  ///< The base layout of the application
-  LogOptions                            mLogOptions;                  ///< log options
+  EnvironmentOptions                    mEnvironmentOptions;          ///< environment options
   PerformanceInterface*                 mPerformanceInterface;        ///< Performance interface
   KernelTrace                           mKernelTracer;                ///< Kernel tracer
   TriggerEventFactory                   mTriggerEventFactory;         ///< Trigger event factory