42 : Thread(
"video-cache"), speed(1), is_playing(false), position(1)
70 position = new_position;
89 using ms = std::chrono::milliseconds;
90 using double_ms = std::chrono::duration<double, ms::period>;
132 std::this_thread::sleep_for(frame_duration);
Header file for all Exception classes.
#define OPEN_MP_NUM_PROCESSORS
Source file for VideoCacheThread class.
virtual std::shared_ptr< openshot::Frame > GetSmallestFrame()=0
Get the smallest frame number.
double ToDouble() const
Return this fraction as a double (i.e. 1/2 = 0.5)
Exception for frames that are out of bounds.
openshot::ReaderInfo info
Information about the current media file.
virtual openshot::CacheBase * GetCache()=0
Get the cache object used by this reader (note: not all readers use cache)
virtual std::shared_ptr< openshot::Frame > GetFrame(int64_t number)=0
std::shared_ptr< Frame > frame
void Play()
Play the video.
int64_t getCurrentFramePosition()
Get the currently playing frame number (if any)
void Stop()
Stop the audio playback.
~VideoCacheThread()
Destructor.
int64_t current_display_frame
VideoCacheThread()
Constructor.
void Seek(int64_t new_position)
Seek the reader to a particular frame number.
int max_concurrent_frames
void setCurrentFramePosition(int64_t current_frame_number)
Set the currently displaying frame number.
void run()
Start the thread.
void AppendDebugMethod(std::string method_name, std::string arg1_name="", float arg1_value=-1.0, std::string arg2_name="", float arg2_value=-1.0, std::string arg3_name="", float arg3_value=-1.0, std::string arg4_name="", float arg4_value=-1.0, std::string arg5_name="", float arg5_value=-1.0, std::string arg6_name="", float arg6_value=-1.0)
Append debug information.
static ZmqLogger * Instance()
Create or get an instance of this logger singleton (invoke the class with this method)
This namespace is the default namespace for all code in the openshot library.
openshot::Fraction fps
Frames per second, as a fraction (i.e. 24/1 = 24 fps)