diff --git a/CMakeLists.txt b/CMakeLists.txt index d42367b0..c64ba959 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,6 +1,6 @@ project(pip) cmake_minimum_required(VERSION 2.6) -set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g3") +#set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g3") include_directories(${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_BINARY_DIR}) include(CheckFunctionExists) diff --git a/src/io/pibinarylog.cpp b/src/io/pibinarylog.cpp index 238786d5..17fc5fc5 100644 --- a/src/io/pibinarylog.cpp +++ b/src/io/pibinarylog.cpp @@ -146,10 +146,12 @@ bool PIBinaryLog::threadedRead(uchar *readed, int size) { int dtc; if (is_started) { if (delay > 0) { - cdelay = delay / play_speed; + cdelay = delay * play_speed; dtc = int(cdelay) /100; + if (play_speed <= 0.) dtc = 1; for (int j=0; j 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 7178d2d9..243a8c61 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;} + double playSpeed() const {return play_speed > 0 ? 1. / play_speed : 0;} //! Returns current play delay PISystemTime playDelay() const {return play_delay;}