From ed117d70730c73fcc5de9c96d7f775a5dea0f6c2 Mon Sep 17 00:00:00 2001 From: Chris Tallon Date: Sun, 23 Feb 2020 16:41:31 +0000 Subject: [PATCH] WIN32 compatibility --- dssourcefilter.h | 1 - osdwinvector.h | 11 +++++------ timers.cc | 6 ++++-- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/dssourcefilter.h b/dssourcefilter.h index ab34c9d..dd163e3 100644 --- a/dssourcefilter.h +++ b/dssourcefilter.h @@ -22,7 +22,6 @@ #define DSSOURCEFILTER_H -#include "mutex.h" #include "dssourcepin.h" struct mptype_video_detail{ //here should be all information added the Video Draintarget needs for rendering, to be extended in the future diff --git a/osdwinvector.h b/osdwinvector.h index 9a72ca9..058e205 100644 --- a/osdwinvector.h +++ b/osdwinvector.h @@ -20,21 +20,20 @@ #ifndef OSDWINVECTOR_H #define OSDWINVECTOR_H -#include -#include -#include -#include #include #include #include -#include "osdvector.h" #include "defines.h" -#include "log.h" #include "windowsosd.h" +#include +#include +#include +#include "log.h" +#include "osdvector.h" class OsdWinVector : public OsdVector, public WindowsOsd { diff --git a/timers.cc b/timers.cc index f1f73da..7caed9b 100644 --- a/timers.cc +++ b/timers.cc @@ -95,7 +95,8 @@ bool Timers::setTimerD(TimerReceiver* client, int clientReference, long int requ { std::chrono::system_clock::time_point fireTime = std::chrono::system_clock::now(); fireTime += std::chrono::seconds(requestedSecs); - fireTime += std::chrono::nanoseconds(requestedNSecs); + //fireTime += std::chrono::nanoseconds(requestedNSecs); + fireTime += std::chrono::duration_cast(std::chrono::nanoseconds(requestedNSecs)); return setTimerC(client, clientReference, fireTime); } @@ -103,7 +104,8 @@ bool Timers::setTimerD(TimerReceiver* client, int clientReference, long int requ bool Timers::setTimerT(TimerReceiver* client, int clientReference, long int requestedTime, long int requestedTimeNSecs) { std::chrono::system_clock::time_point fireTime = std::chrono::system_clock::from_time_t(requestedTime); - fireTime += std::chrono::nanoseconds(requestedTimeNSecs); + //fireTime += std::chrono::nanoseconds(requestedTimeNSecs); + fireTime += std::chrono::duration_cast(std::chrono::nanoseconds(requestedTimeNSecs)); return setTimerC(client, clientReference, fireTime); } -- 2.39.5