aboutsummaryrefslogtreecommitdiff
path: root/www/chromium/files/patch-ui__gl__sync_control_vsync_provider.cc
blob: 3bcbb62628d03aa134d8421342f44c68718bb02a (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
--- ui/gl/sync_control_vsync_provider.cc.orig	2015-10-14 19:12:40.408387000 +0200
+++ ui/gl/sync_control_vsync_provider.cc	2015-10-14 19:13:44.335913000 +0200
@@ -10,7 +10,7 @@
 #include "base/time/time.h"
 #include "base/trace_event/trace_event.h"
 
-#if defined(OS_LINUX)
+#if defined(OS_LINUX) || defined(OS_BSD)
 // These constants define a reasonable range for a calculated refresh interval.
 // Calculating refreshes out of this range will be considered a fatal error.
 const int64 kMinVsyncIntervalUs = base::Time::kMicrosecondsPerSecond / 400;
@@ -37,7 +37,7 @@
 void SyncControlVSyncProvider::GetVSyncParameters(
     const UpdateVSyncCallback& callback) {
   TRACE_EVENT0("gpu", "SyncControlVSyncProvider::GetVSyncParameters");
-#if defined(OS_LINUX)
+#if defined(OS_LINUX) || defined(OS_BSD)
   base::TimeTicks timebase;
 
   // The actual clock used for the system time returned by glXGetSyncValuesOML
@@ -153,7 +153,7 @@
   last_timebase_ = timebase;
   last_media_stream_counter_ = media_stream_counter;
   callback.Run(timebase, last_good_interval_);
-#endif  // defined(OS_LINUX)
+#endif  // defined(OS_LINUX) || defined(OS_BSD)
 }
 
 }  // namespace gfx