From d7fdfdf1ee3902a67292338089dad1a7083d0f37 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=91=D1=8B=D1=87=D0=BA=D0=BE=D0=B2=20=D0=90=D0=BD=D0=B4?= =?UTF-8?q?=D1=80=D0=B5=D0=B9?= Date: Mon, 27 Apr 2015 10:46:18 +0000 Subject: [PATCH] correct PIBinaryLog play_speed 0 git-svn-id: svn://db.shs.com.ru/pip@122 12ceb7fc-bf1f-11e4-8940-5bc7170c53b5 --- src/io/pibinarylog.cpp | 10 ++++++---- src/io/pibinarylog.h | 2 +- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/src/io/pibinarylog.cpp b/src/io/pibinarylog.cpp index 17fc5fc5..04c37ba3 100644 --- a/src/io/pibinarylog.cpp +++ b/src/io/pibinarylog.cpp @@ -148,12 +148,14 @@ bool PIBinaryLog::threadedRead(uchar *readed, int size) { if (delay > 0) { cdelay = delay * play_speed; dtc = int(cdelay) /100; - if (play_speed <= 0.) dtc = 1; + if (play_speed <= 0.) dtc = 2; + //piCout << play_speed << dtc; for (int j=0; j 0 ? 1. / ps : 0; + play_speed = ps > 0. ? 1. / ps : 0.; play_delay = property("playDelay").toSystemTime(); split_mode = (SplitMode)property("splitMode").toInt(); split_time = property("splitTime").toSystemTime(); diff --git a/src/io/pibinarylog.h b/src/io/pibinarylog.h index 243a8c61..3eced154 100644 --- a/src/io/pibinarylog.h +++ b/src/io/pibinarylog.h @@ -103,7 +103,7 @@ public: int defaultID() const {return default_id;} //! Returns current play speed - double playSpeed() const {return play_speed > 0 ? 1. / play_speed : 0;} + double playSpeed() const {return play_speed > 0 ? 1. / play_speed : 0.;} //! Returns current play delay PISystemTime playDelay() const {return play_delay;}