svvitch
digital signage player
D:/vs_workspace/switch_sf/src/svvitch/MFContent.h
Go to the documentation of this file.
00001 #pragma once
00002 
00003 #include "Content.h"
00004 #include "Renderer.h"
00005 #include <Poco/ActiveMethod.h>
00006 #include <Poco/Mutex.h>
00007 #include <mfapi.h>
00008 #include <mfidl.h>
00009 
00010 #pragma comment(lib, "mf.lib")
00011 
00012 
00016 class MFContent: public Content {
00017 private:
00018     Poco::FastMutex _lock;
00019     bool _finished;
00020     IMFMediaSession* _session;
00021 
00022 public:
00023     MFContent(Renderer& renderer, int splitType);
00024 
00025     virtual ‾MFContent();
00026 
00027 
00028     void initialize();
00029 
00031     bool open(const MediaItemPtr media, const int offset = 0);
00032 
00036     void play();
00037 
00041     void stop();
00042 
00046     const bool playing() const;
00047 
00048     const bool finished();
00049 
00051     void close();
00052 
00053     void process(const DWORD& frame);
00054 
00055     void draw(const DWORD& frame);
00056 };
00057 
00058 typedef MFContent* MFContentPtr;
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines