\r
#include <common/memory/safe_ptr.h>\r
\r
+#include <boost/noncopyable.hpp>\r
+\r
+#include <string>\r
#include <vector>\r
\r
struct AVFrame;\r
+enum PixelFormat;\r
\r
-namespace caspar {\r
+namespace caspar { namespace ffmpeg {\r
\r
-class filter\r
+static bool double_rate(const std::wstring& filters)\r
+{\r
+ if(filters.find(L"YADIF=1") != std::string::npos)\r
+ return true;\r
+ \r
+ if(filters.find(L"YADIF=3") != std::string::npos)\r
+ return true;\r
+\r
+ return false;\r
+}\r
+\r
+class filter : boost::noncopyable\r
{\r
public:\r
- filter(const std::string& filters);\r
+ filter(const std::wstring& filters = L"", const std::vector<PixelFormat>& pix_fmts = std::vector<PixelFormat>());\r
+ filter(filter&& other);\r
+ filter& operator=(filter&& other);\r
\r
- void push(const safe_ptr<AVFrame>& frame);\r
- std::vector<safe_ptr<AVFrame>> poll();\r
- bool is_ready() const;\r
+ std::vector<safe_ptr<AVFrame>> execute(const std::shared_ptr<AVFrame>& frame);\r
\r
private:\r
struct implementation;\r
safe_ptr<implementation> impl_;\r
};\r
\r
-}
\ No newline at end of file
+}}
\ No newline at end of file