diff options
Diffstat (limited to 'src/lib')
| -rw-r--r-- | src/lib/cross.cc | 8 | ||||
| -rw-r--r-- | src/lib/cross.h | 1 | ||||
| -rw-r--r-- | src/lib/encoder.cc | 2 |
3 files changed, 11 insertions, 0 deletions
diff --git a/src/lib/cross.cc b/src/lib/cross.cc index 57b3f93b2..9f7a76124 100644 --- a/src/lib/cross.cc +++ b/src/lib/cross.cc @@ -298,3 +298,11 @@ dcpomatic_fseek (FILE* stream, int64_t offset, int whence) return fseek (stream, offset, whence); #endif } + +void +kick () +{ +#ifdef DCPOMATIC_WINDOWS + SetThreadExecutionState (ES_CONTINUOUS); +#endif +} diff --git a/src/lib/cross.h b/src/lib/cross.h index 7e032e5a1..822b36631 100644 --- a/src/lib/cross.h +++ b/src/lib/cross.h @@ -35,3 +35,4 @@ extern boost::filesystem::path app_contents (); #endif extern FILE * fopen_boost (boost::filesystem::path, std::string); extern int dcpomatic_fseek (FILE *, int64_t, int); +void kick (); diff --git a/src/lib/encoder.cc b/src/lib/encoder.cc index fbec3e4d0..92b4763be 100644 --- a/src/lib/encoder.cc +++ b/src/lib/encoder.cc @@ -180,6 +180,8 @@ Encoder::frame_done () void Encoder::process_video (shared_ptr<PlayerImage> image, Eyes eyes, ColourConversion conversion, bool same) { + kick (); + boost::mutex::scoped_lock lock (_mutex); /* XXX: discard 3D here if required */ |
