]> git.sesse.net Git - casparcg/blobdiff - core/producer/stage.cpp
2.0. Applied tk3 patch, STATUS command for layer status querying.
[casparcg] / core / producer / stage.cpp
index 1c5d99014f39b65db4bbc0ede4d7e982109307ef..d222b39d73e9a6b98319a7bd6bb35d666fb6bde7 100644 (file)
@@ -39,7 +39,7 @@
 #include <set>\r
 \r
 namespace caspar { namespace core {\r
-               \r
+       \r
 void destroy_producer(safe_ptr<frame_producer>& producer)\r
 {\r
        if(!producer.unique())\r
@@ -194,6 +194,14 @@ public:
                \r
                channel_.execution().invoke([&]{other.impl_->channel_.execution().invoke(func, high_priority);});\r
        }\r
+\r
+       layer_status get_status(int index)\r
+       {               \r
+               return channel_.execution().invoke([&]\r
+               {\r
+                       return layers_[index].status();\r
+               }, high_priority );\r
+       }\r
        \r
        boost::unique_future<safe_ptr<frame_producer>> foreground(int index)\r
        {\r
@@ -222,6 +230,7 @@ void stage::clear(int index){impl_->clear(index);}
 void stage::clear(){impl_->clear();}\r
 void stage::swap_layer(int index, size_t other_index){impl_->swap_layer(index, other_index);}\r
 void stage::swap_layer(int index, size_t other_index, stage& other){impl_->swap_layer(index, other_index, other);}\r
+layer_status stage::get_status(int index){return impl_->get_status(index);}\r
 boost::unique_future<safe_ptr<frame_producer>> stage::foreground(size_t index) {return impl_->foreground(index);}\r
 boost::unique_future<safe_ptr<frame_producer>> stage::background(size_t index) {return impl_->background(index);}\r
 std::map<int, safe_ptr<basic_frame>> stage::execute(){return impl_->execute();}\r