virtual void visit(const core::const_frame& frame);\r
virtual void pop();\r
\r
- virtual boost::unique_future<array<const std::uint8_t>> operator()(const core::video_format_desc& format_desc) override;\r
+ boost::unique_future<array<const std::uint8_t>> operator()(const core::video_format_desc& format_desc) override;\r
\r
- virtual core::mutable_frame create_frame(const void* tag, const core::pixel_format_desc& desc, double frame_rate, core::field_mode field_mode) override;\r
+ core::mutable_frame create_frame(const void* tag, const core::pixel_format_desc& desc, double frame_rate, core::field_mode field_mode) override;\r
\r
// Properties\r
\r
return renderer_(std::move(layers_), format_desc);\r
}\r
\r
- virtual core::mutable_frame create_frame(const void* tag, const core::pixel_format_desc& desc, double frame_rate, core::field_mode field_mode) override\r
+ core::mutable_frame create_frame(const void* tag, const core::pixel_format_desc& desc, double frame_rate, core::field_mode field_mode) override\r
{\r
std::vector<array<std::uint8_t>> buffers;\r
BOOST_FOREACH(auto& plane, desc.planes) \r
\r
// Methods\r
\r
- virtual boost::unique_future<array<const std::uint8_t>> operator()(const core::video_format_desc& format_desc) override; \r
- virtual core::mutable_frame create_frame(const void* tag, const core::pixel_format_desc& desc, double frame_rate, core::field_mode field_mode) override;\r
+ boost::unique_future<array<const std::uint8_t>> operator()(const core::video_format_desc& format_desc) override; \r
+ core::mutable_frame create_frame(const void* tag, const core::pixel_format_desc& desc, double frame_rate, core::field_mode field_mode) override;\r
\r
// core::image_mixer\r
\r
- virtual void begin_layer(core::blend_mode blend_mode) override;\r
- virtual void end_layer() override;\r
+ void begin_layer(core::blend_mode blend_mode) override;\r
+ void end_layer() override;\r
\r
- virtual void push(const core::frame_transform& frame) override;\r
- virtual void visit(const core::const_frame& frame) override;\r
- virtual void pop() override;\r
+ void push(const core::frame_transform& frame) override;\r
+ void visit(const core::const_frame& frame) override;\r
+ void pop() override;\r
\r
// Properties\r
\r
std::swap(filter_, other.filter_);\r
}\r
\r
- virtual void on_next(const T& e) override\r
+ void on_next(const T& e) override\r
{\r
func_(e);\r
}\r
impl_.swap(other.impl_);\r
}\r
\r
- virtual void subscribe(const observer_ptr& o) override\r
+ void subscribe(const observer_ptr& o) override\r
{ \r
impl_->subscribe(o);\r
}\r
\r
- virtual void unsubscribe(const observer_ptr& o) override\r
+ void unsubscribe(const observer_ptr& o) override\r
{\r
impl_->unsubscribe(o);\r
}\r
\r
- virtual void on_next(const I& e) override\r
+ void on_next(const I& e) override\r
{ \r
impl_->on_next(e);\r
}\r
}).detach(); \r
}\r
\r
- virtual bool send(const_frame frame) override {return consumer_->send(std::move(frame));}\r
+ bool send(const_frame frame) override {return consumer_->send(std::move(frame));}\r
virtual void initialize(const struct video_format_desc& format_desc, int channel_index) override {return consumer_->initialize(format_desc, channel_index);}\r
- virtual std::wstring print() const override {return consumer_->print();} \r
- virtual std::wstring name() const override {return consumer_->name();}\r
- virtual boost::property_tree::wptree info() const override {return consumer_->info();}\r
- virtual bool has_synchronization_clock() const override {return consumer_->has_synchronization_clock();}\r
- virtual int buffer_depth() const override {return consumer_->buffer_depth();}\r
- virtual int index() const override {return consumer_->index();}\r
+ std::wstring print() const override {return consumer_->print();} \r
+ std::wstring name() const override {return consumer_->name();}\r
+ boost::property_tree::wptree info() const override {return consumer_->info();}\r
+ bool has_synchronization_clock() const override {return consumer_->has_synchronization_clock();}\r
+ int buffer_depth() const override {return consumer_->buffer_depth();}\r
+ int index() const override {return consumer_->index();}\r
};\r
\r
class print_consumer_proxy : public frame_consumer\r
CASPAR_LOG(info) << str << L" Uninitialized.";\r
}\r
\r
- virtual bool send(const_frame frame) override {return consumer_->send(std::move(frame));}\r
+ bool send(const_frame frame) override {return consumer_->send(std::move(frame));}\r
virtual void initialize(const struct video_format_desc& format_desc, int channel_index) override {return consumer_->initialize(format_desc, channel_index);}\r
- virtual std::wstring print() const override {return consumer_->print();}\r
- virtual std::wstring name() const override {return consumer_->name();}\r
- virtual boost::property_tree::wptree info() const override {return consumer_->info();}\r
- virtual bool has_synchronization_clock() const override {return consumer_->has_synchronization_clock();}\r
- virtual int buffer_depth() const override {return consumer_->buffer_depth();}\r
- virtual int index() const override {return consumer_->index();}\r
+ std::wstring print() const override {return consumer_->print();}\r
+ std::wstring name() const override {return consumer_->name();}\r
+ boost::property_tree::wptree info() const override {return consumer_->info();}\r
+ bool has_synchronization_clock() const override {return consumer_->has_synchronization_clock();}\r
+ int buffer_depth() const override {return consumer_->buffer_depth();}\r
+ int index() const override {return consumer_->index();}\r
};\r
\r
class recover_consumer_proxy : public frame_consumer\r
return consumer_->initialize(format_desc, channel_index);\r
}\r
\r
- virtual std::wstring print() const override {return consumer_->print();}\r
- virtual std::wstring name() const override {return consumer_->name();}\r
- virtual boost::property_tree::wptree info() const override {return consumer_->info();}\r
- virtual bool has_synchronization_clock() const override {return consumer_->has_synchronization_clock();}\r
- virtual int buffer_depth() const override {return consumer_->buffer_depth();}\r
- virtual int index() const override {return consumer_->index();}\r
+ std::wstring print() const override {return consumer_->print();}\r
+ std::wstring name() const override {return consumer_->name();}\r
+ boost::property_tree::wptree info() const override {return consumer_->info();}\r
+ bool has_synchronization_clock() const override {return consumer_->has_synchronization_clock();}\r
+ int buffer_depth() const override {return consumer_->buffer_depth();}\r
+ int index() const override {return consumer_->index();}\r
};\r
\r
// This class is used to guarantee that audio cadence is correct. This is important for NTSC audio.\r
{\r
}\r
\r
- virtual void initialize(const video_format_desc& format_desc, int channel_index) override\r
+ void initialize(const video_format_desc& format_desc, int channel_index) override\r
{\r
audio_cadence_ = format_desc.audio_cadence;\r
sync_buffer_ = boost::circular_buffer<std::size_t>(format_desc.audio_cadence.size());\r
consumer_->initialize(format_desc, channel_index);\r
}\r
\r
- virtual bool send(const_frame frame) override\r
+ bool send(const_frame frame) override\r
{ \r
if(audio_cadence_.size() == 1)\r
return consumer_->send(frame);\r
return result;\r
}\r
\r
- virtual std::wstring print() const override {return consumer_->print();}\r
- virtual std::wstring name() const override {return consumer_->name();}\r
- virtual boost::property_tree::wptree info() const override {return consumer_->info();}\r
- virtual bool has_synchronization_clock() const override {return consumer_->has_synchronization_clock();}\r
- virtual int buffer_depth() const override {return consumer_->buffer_depth();}\r
- virtual int index() const override {return consumer_->index();}\r
+ std::wstring print() const override {return consumer_->print();}\r
+ std::wstring name() const override {return consumer_->name();}\r
+ boost::property_tree::wptree info() const override {return consumer_->info();}\r
+ bool has_synchronization_clock() const override {return consumer_->has_synchronization_clock();}\r
+ int buffer_depth() const override {return consumer_->buffer_depth();}\r
+ int index() const override {return consumer_->index();}\r
};\r
\r
spl::shared_ptr<core::frame_consumer> create_consumer(const std::vector<std::wstring>& params)\r
class empty_frame_consumer : public frame_consumer\r
{\r
public:\r
- virtual bool send(const_frame) override {return false;}\r
- virtual void initialize(const video_format_desc&, int) override{}\r
- virtual std::wstring print() const override {return L"empty";}\r
- virtual std::wstring name() const override {return L"empty";}\r
- virtual bool has_synchronization_clock() const override {return false;}\r
- virtual int buffer_depth() const override {return 0;};\r
+ bool send(const_frame) override {return false;}\r
+ void initialize(const video_format_desc&, int) override{}\r
+ std::wstring print() const override {return L"empty";}\r
+ std::wstring name() const override {return L"empty";}\r
+ bool has_synchronization_clock() const override {return false;}\r
+ int buffer_depth() const override {return 0;};\r
virtual int index() const{return -1;}\r
- virtual boost::property_tree::wptree info() const override\r
+ boost::property_tree::wptree info() const override\r
{\r
boost::property_tree::wptree info;\r
info.add(L"type", L"empty");\r
\r
// observable\r
\r
- virtual void subscribe(const observer_ptr& o) override\r
+ void subscribe(const observer_ptr& o) override\r
{ \r
impl_->subscribe(o);\r
}\r
\r
- virtual void unsubscribe(const observer_ptr& o) override\r
+ void unsubscribe(const observer_ptr& o) override\r
{\r
impl_->unsubscribe(o);\r
}\r
\r
// observer\r
\r
- virtual void on_next(const monitor::event& e) override\r
+ void on_next(const monitor::event& e) override\r
{ \r
impl_->on_next(e);\r
}\r
\r
// frame_producer\r
\r
- virtual draw_frame receive(int) override\r
+ draw_frame receive(int) override\r
{\r
event_subject_ << monitor::event("color") % color_str_;\r
\r
return frame_;\r
} \r
\r
- virtual std::wstring print() const override\r
+ std::wstring print() const override\r
{\r
return L"color[" + color_str_ + L"]";\r
}\r
\r
- virtual std::wstring name() const override\r
+ std::wstring name() const override\r
{\r
return L"color";\r
}\r
\r
- virtual draw_frame last_frame() const override\r
+ draw_frame last_frame() const override\r
{\r
return frame_;\r
}\r
return info;\r
}\r
\r
- virtual void subscribe(const monitor::observable::observer_ptr& o) override \r
+ void subscribe(const monitor::observable::observer_ptr& o) override \r
{\r
return event_subject_.subscribe(o);\r
}\r
\r
- virtual void unsubscribe(const monitor::observable::observer_ptr& o) override \r
+ void unsubscribe(const monitor::observable::observer_ptr& o) override \r
{\r
return event_subject_.unsubscribe(o);\r
}\r
virtual void unsubscribe(const monitor::observable::observer_ptr& o){} \r
virtual std::wstring name() const {return L"empty";}\r
\r
- virtual boost::property_tree::wptree info() const override\r
+ boost::property_tree::wptree info() const override\r
{\r
boost::property_tree::wptree info;\r
info.add(L"type", L"empty-producer");\r
}).detach(); \r
}\r
\r
- virtual draw_frame receive(int flags) override {return producer_->receive(flags);}\r
- virtual draw_frame last_frame() const override {return producer_->last_frame();}\r
- virtual std::wstring print() const override {return producer_->print();}\r
- virtual std::wstring name() const override {return producer_->name();}\r
- virtual boost::property_tree::wptree info() const override {return producer_->info();}\r
- virtual boost::unique_future<std::wstring> call(const std::wstring& str) override {return producer_->call(str);}\r
- virtual void leading_producer(const spl::shared_ptr<frame_producer>& producer) override {return producer_->leading_producer(producer);}\r
- virtual uint32_t nb_frames() const override {return producer_->nb_frames();}\r
+ draw_frame receive(int flags) override {return producer_->receive(flags);}\r
+ draw_frame last_frame() const override {return producer_->last_frame();}\r
+ std::wstring print() const override {return producer_->print();}\r
+ std::wstring name() const override {return producer_->name();}\r
+ boost::property_tree::wptree info() const override {return producer_->info();}\r
+ boost::unique_future<std::wstring> call(const std::wstring& str) override {return producer_->call(str);}\r
+ void leading_producer(const spl::shared_ptr<frame_producer>& producer) override {return producer_->leading_producer(producer);}\r
+ uint32_t nb_frames() const override {return producer_->nb_frames();}\r
virtual void subscribe(const monitor::observable::observer_ptr& o) {return producer_->subscribe(o);}\r
virtual void unsubscribe(const monitor::observable::observer_ptr& o) {return producer_->unsubscribe(o);}\r
};\r
\r
// monitor::observable\r
\r
- virtual void subscribe(const monitor::observable::observer_ptr& o) override;\r
- virtual void unsubscribe(const monitor::observable::observer_ptr& o) override;\r
+ void subscribe(const monitor::observable::observer_ptr& o) override;\r
+ void unsubscribe(const monitor::observable::observer_ptr& o) override;\r
\r
// Properties\r
\r
\r
// frame_producer\r
\r
- virtual draw_frame receive(int flags) override\r
+ draw_frame receive(int flags) override\r
{\r
tbb::parallel_invoke(\r
[&]\r
return frame;\r
}\r
\r
- virtual draw_frame last_frame() const override\r
+ draw_frame last_frame() const override\r
{\r
return draw_frame::still(last_frame_);\r
}\r
\r
- virtual uint32_t nb_frames() const override\r
+ uint32_t nb_frames() const override\r
{\r
return std::min(fill_producer_->nb_frames(), key_producer_->nb_frames());\r
}\r
\r
- virtual std::wstring print() const override\r
+ std::wstring print() const override\r
{\r
return L"separated[fill:" + fill_producer_->print() + L"|key[" + key_producer_->print() + L"]]";\r
} \r
\r
- virtual boost::unique_future<std::wstring> call(const std::wstring& str) override\r
+ boost::unique_future<std::wstring> call(const std::wstring& str) override\r
{\r
key_producer_->call(str);\r
return fill_producer_->call(str);\r
}\r
\r
- virtual std::wstring name() const override\r
+ std::wstring name() const override\r
{\r
return L"separated";\r
}\r
return fill_producer_->info();;\r
}\r
\r
- virtual void subscribe(const monitor::observable::observer_ptr& o) override \r
+ void subscribe(const monitor::observable::observer_ptr& o) override \r
{\r
return event_subject_.subscribe(o);\r
}\r
\r
- virtual void unsubscribe(const monitor::observable::observer_ptr& o) override \r
+ void unsubscribe(const monitor::observable::observer_ptr& o) override \r
{\r
return event_subject_.unsubscribe(o);\r
}\r
\r
// monitor::observable\r
\r
- virtual void subscribe(const monitor::observable::observer_ptr& o) override;\r
- virtual void unsubscribe(const monitor::observable::observer_ptr& o) override;\r
+ void subscribe(const monitor::observable::observer_ptr& o) override;\r
+ void unsubscribe(const monitor::observable::observer_ptr& o) override;\r
\r
// Properties\r
\r
\r
// frame_producer\r
\r
- virtual void leading_producer(const spl::shared_ptr<frame_producer>& producer) override\r
+ void leading_producer(const spl::shared_ptr<frame_producer>& producer) override\r
{\r
source_producer_ = create_destroy_proxy(producer);\r
}\r
\r
- virtual draw_frame receive(int flags) override\r
+ draw_frame receive(int flags) override\r
{\r
if(current_frame_ >= info_.duration)\r
{\r
return compose(dest, source);\r
}\r
\r
- virtual draw_frame last_frame() const override\r
+ draw_frame last_frame() const override\r
{\r
return dest_producer_->last_frame();\r
}\r
\r
- virtual uint32_t nb_frames() const override\r
+ uint32_t nb_frames() const override\r
{\r
return dest_producer_->nb_frames();\r
}\r
\r
- virtual std::wstring print() const override\r
+ std::wstring print() const override\r
{\r
return L"transition[" + source_producer_->print() + L"=>" + dest_producer_->print() + L"]";\r
}\r
\r
- virtual std::wstring name() const override\r
+ std::wstring name() const override\r
{\r
return L"transition";\r
}\r
\r
- virtual boost::property_tree::wptree info() const override\r
+ boost::property_tree::wptree info() const override\r
{\r
return dest_producer_->info();\r
}\r
\r
- virtual boost::unique_future<std::wstring> call(const std::wstring& str) override\r
+ boost::unique_future<std::wstring> call(const std::wstring& str) override\r
{\r
return dest_producer_->call(str);\r
}\r
return draw_frame::over(s_frame, d_frame);\r
}\r
\r
- virtual void subscribe(const monitor::observable::observer_ptr& o) override \r
+ void subscribe(const monitor::observable::observer_ptr& o) override \r
{\r
event_subject_.subscribe(o);\r
}\r
\r
- virtual void unsubscribe(const monitor::observable::observer_ptr& o) override \r
+ void unsubscribe(const monitor::observable::observer_ptr& o) override \r
{\r
event_subject_.unsubscribe(o);\r
}\r
\r
// monitor::observable\r
\r
- virtual void subscribe(const monitor::observable::observer_ptr& o) override;\r
- virtual void unsubscribe(const monitor::observable::observer_ptr& o) override;\r
+ void subscribe(const monitor::observable::observer_ptr& o) override;\r
+ void unsubscribe(const monitor::observable::observer_ptr& o) override;\r
\r
// Properties\r
\r
\r
// frame_consumer\r
\r
- virtual void initialize(const core::video_format_desc& format_desc, int channel_index) override\r
+ void initialize(const core::video_format_desc& format_desc, int channel_index) override\r
{\r
consumer_.reset();\r
consumer_.reset(new bluefish_consumer(format_desc, device_index_, embedded_audio_, key_only_, channel_index));\r
}\r
\r
- virtual bool send(core::const_frame frame) override\r
+ bool send(core::const_frame frame) override\r
{\r
consumer_->send(frame);\r
return true;\r
}\r
\r
- virtual std::wstring print() const override\r
+ std::wstring print() const override\r
{\r
return consumer_ ? consumer_->print() : L"[bluefish_consumer]";\r
}\r
\r
- virtual std::wstring name() const override\r
+ std::wstring name() const override\r
{\r
return L"bluefish";\r
}\r
\r
- virtual boost::property_tree::wptree info() const override\r
+ boost::property_tree::wptree info() const override\r
{\r
boost::property_tree::wptree info;\r
info.add(L"type", L"bluefish");\r
return 1;\r
}\r
\r
- virtual int index() const override\r
+ int index() const override\r
{\r
return 400 + device_index_;\r
}\r
\r
// frame_consumer\r
\r
- virtual void initialize(const core::video_format_desc& format_desc, int channel_index) override\r
+ void initialize(const core::video_format_desc& format_desc, int channel_index) override\r
{\r
executor_.invoke([=]\r
{\r
});\r
}\r
\r
- virtual bool send(core::const_frame frame) override\r
+ bool send(core::const_frame frame) override\r
{\r
consumer_->send(frame);\r
return true;\r
}\r
\r
- virtual std::wstring print() const override\r
+ std::wstring print() const override\r
{\r
return consumer_ ? consumer_->print() : L"[decklink_consumer]";\r
} \r
\r
- virtual std::wstring name() const override\r
+ std::wstring name() const override\r
{\r
return L"decklink";\r
}\r
\r
- virtual boost::property_tree::wptree info() const override\r
+ boost::property_tree::wptree info() const override\r
{\r
boost::property_tree::wptree info;\r
info.add(L"type", L"decklink");\r
return info;\r
}\r
\r
- virtual int buffer_depth() const override\r
+ int buffer_depth() const override\r
{\r
return config_.buffer_depth();\r
}\r
\r
- virtual int index() const override\r
+ int index() const override\r
{\r
return 300 + config_.device_index;\r
}\r
});\r
}\r
\r
- virtual void subscribe(const monitor::observable::observer_ptr& o) override\r
+ void subscribe(const monitor::observable::observer_ptr& o) override\r
{\r
producer_->subscribe(o);\r
}\r
\r
- virtual void unsubscribe(const monitor::observable::observer_ptr& o) override\r
+ void unsubscribe(const monitor::observable::observer_ptr& o) override\r
{\r
producer_->unsubscribe(o);\r
}\r
\r
// frame_producer\r
\r
- virtual core::draw_frame receive(int flags) override\r
+ core::draw_frame receive(int flags) override\r
{\r
auto frame = producer_->get_frame(flags);\r
\r
return frame;\r
}\r
\r
- virtual core::draw_frame last_frame() const override\r
+ core::draw_frame last_frame() const override\r
{\r
return core::draw_frame::still(last_frame_);\r
}\r
\r
- virtual uint32_t nb_frames() const override\r
+ uint32_t nb_frames() const override\r
{\r
return length_;\r
}\r
\r
- virtual std::wstring print() const override\r
+ std::wstring print() const override\r
{\r
return producer_->print();\r
}\r
\r
- virtual std::wstring name() const override\r
+ std::wstring name() const override\r
{\r
return L"decklink";\r
}\r
\r
- virtual boost::property_tree::wptree info() const override\r
+ boost::property_tree::wptree info() const override\r
{\r
boost::property_tree::wptree info;\r
info.add(L"type", L"decklink");\r
consumer_.reset(new ffmpeg_consumer(u8(filename_), format_desc, options_));\r
}\r
\r
- virtual bool send(core::const_frame frame) override\r
+ bool send(core::const_frame frame) override\r
{\r
consumer_->send(frame);\r
return true;\r
}\r
\r
- virtual std::wstring print() const override\r
+ std::wstring print() const override\r
{\r
return consumer_ ? consumer_->print() : L"[ffmpeg_consumer]";\r
}\r
\r
- virtual std::wstring name() const override\r
+ std::wstring name() const override\r
{\r
return L"file";\r
}\r
\r
- virtual boost::property_tree::wptree info() const override\r
+ boost::property_tree::wptree info() const override\r
{\r
boost::property_tree::wptree info;\r
info.add(L"type", L"file");\r
return info;\r
}\r
\r
- virtual bool has_synchronization_clock() const override\r
+ bool has_synchronization_clock() const override\r
{\r
return false;\r
}\r
\r
- virtual int buffer_depth() const override\r
+ int buffer_depth() const override\r
{\r
return 1;\r
}\r
\r
- virtual int index() const override\r
+ int index() const override\r
{\r
return 200;\r
}\r
\r
// monitor::observable\r
\r
- virtual void subscribe(const monitor::observable::observer_ptr& o) override;\r
- virtual void unsubscribe(const monitor::observable::observer_ptr& o) override;\r
+ void subscribe(const monitor::observable::observer_ptr& o) override;\r
+ void unsubscribe(const monitor::observable::observer_ptr& o) override;\r
\r
private:\r
struct impl;\r
\r
// frame_producer\r
\r
- virtual core::draw_frame receive(int flags) override\r
+ core::draw_frame receive(int flags) override\r
{ \r
boost::timer frame_timer;\r
\r
return frame;\r
}\r
\r
- virtual core::draw_frame last_frame() const override\r
+ core::draw_frame last_frame() const override\r
{\r
return core::draw_frame::still(last_frame_);\r
}\r
\r
- virtual uint32_t nb_frames() const override\r
+ uint32_t nb_frames() const override\r
{\r
if(input_.loop())\r
return std::numeric_limits<uint32_t>::max();\r
return video_decoder_ ? video_decoder_->file_frame_number() : 0;\r
}\r
\r
- virtual boost::unique_future<std::wstring> call(const std::wstring& param) override\r
+ boost::unique_future<std::wstring> call(const std::wstring& param) override\r
{\r
boost::promise<std::wstring> promise;\r
promise.set_value(do_call(param));\r
return promise.get_future();\r
}\r
\r
- virtual std::wstring print() const override\r
+ std::wstring print() const override\r
{\r
return L"ffmpeg[" + boost::filesystem::path(filename_).filename().wstring() + L"|" \r
+ print_mode() + L"|" \r
+ boost::lexical_cast<std::wstring>(file_frame_number()) + L"/" + boost::lexical_cast<std::wstring>(file_nb_frames()) + L"]";\r
}\r
\r
- virtual std::wstring name() const override\r
+ std::wstring name() const override\r
{\r
return L"ffmpeg";\r
}\r
return info;\r
}\r
\r
- virtual void subscribe(const monitor::observable::observer_ptr& o) override\r
+ void subscribe(const monitor::observable::observer_ptr& o) override\r
{\r
event_subject_.subscribe(o);\r
}\r
\r
- virtual void unsubscribe(const monitor::observable::observer_ptr& o) override\r
+ void unsubscribe(const monitor::observable::observer_ptr& o) override\r
{\r
event_subject_.unsubscribe(o);\r
}\r
\r
// monitor::observable\r
\r
- virtual void subscribe(const monitor::observable::observer_ptr& o) override;\r
- virtual void unsubscribe(const monitor::observable::observer_ptr& o) override;\r
+ void subscribe(const monitor::observable::observer_ptr& o) override;\r
+ void unsubscribe(const monitor::observable::observer_ptr& o) override;\r
\r
private:\r
struct impl;\r
\r
// frame_producer\r
\r
- virtual core::draw_frame receive(int) override\r
+ core::draw_frame receive(int) override\r
{ \r
auto frame = core::draw_frame::late();\r
\r
return frame;\r
}\r
\r
- virtual core::draw_frame last_frame() const override\r
+ core::draw_frame last_frame() const override\r
{\r
return core::draw_frame::still(last_frame_);\r
}\r
\r
- virtual boost::unique_future<std::wstring> call(const std::wstring& param) override\r
+ boost::unique_future<std::wstring> call(const std::wstring& param) override\r
{ \r
return executor_.begin_invoke([this, param]() -> std::wstring\r
{ \r
});\r
}\r
\r
- virtual std::wstring print() const override\r
+ std::wstring print() const override\r
{ \r
return L"flash[" + boost::filesystem::path(filename_).wstring() + L"|" + boost::lexical_cast<std::wstring>(fps_) + L"]"; \r
} \r
\r
- virtual std::wstring name() const override\r
+ std::wstring name() const override\r
{\r
return L"flash";\r
}\r
\r
- virtual boost::property_tree::wptree info() const override\r
+ boost::property_tree::wptree info() const override\r
{\r
boost::property_tree::wptree info;\r
info.add(L"type", L"flash");\r
return info;\r
}\r
\r
- virtual void subscribe(const monitor::observable::observer_ptr& o) override\r
+ void subscribe(const monitor::observable::observer_ptr& o) override\r
{\r
event_subject_.subscribe(o);\r
}\r
\r
- virtual void unsubscribe(const monitor::observable::observer_ptr& o) override\r
+ void unsubscribe(const monitor::observable::observer_ptr& o) override\r
{\r
event_subject_.unsubscribe(o);\r
}\r
\r
// frame_consumer\r
\r
- virtual void initialize(const core::video_format_desc&, int) override\r
+ void initialize(const core::video_format_desc&, int) override\r
{\r
}\r
\r
- virtual bool send(core::const_frame frame) override\r
+ bool send(core::const_frame frame) override\r
{ \r
boost::thread async([frame]\r
{\r
return false;\r
}\r
\r
- virtual std::wstring print() const override\r
+ std::wstring print() const override\r
{\r
return L"image[]";\r
}\r
\r
- virtual std::wstring name() const override\r
+ std::wstring name() const override\r
{\r
return L"image";\r
}\r
\r
- virtual boost::property_tree::wptree info() const override\r
+ boost::property_tree::wptree info() const override\r
{\r
boost::property_tree::wptree info;\r
info.add(L"type", L"image");\r
return info;\r
}\r
\r
- virtual int buffer_depth() const override\r
+ int buffer_depth() const override\r
{\r
return 0;\r
}\r
\r
- virtual int index() const override\r
+ int index() const override\r
{\r
return 100;\r
}\r
\r
// frame_producer\r
\r
- virtual core::draw_frame receive(int) override\r
+ core::draw_frame receive(int) override\r
{\r
event_subject_ << monitor::event("file/path") % filename_;\r
\r
return frame_;\r
}\r
\r
- virtual core::draw_frame last_frame() const override\r
+ core::draw_frame last_frame() const override\r
{\r
return frame_;\r
}\r
\r
- virtual std::wstring print() const override\r
+ std::wstring print() const override\r
{\r
return L"image_producer[" + filename_ + L"]";\r
}\r
\r
- virtual std::wstring name() const override\r
+ std::wstring name() const override\r
{\r
return L"image";\r
}\r
\r
- virtual boost::property_tree::wptree info() const override\r
+ boost::property_tree::wptree info() const override\r
{\r
boost::property_tree::wptree info;\r
info.add(L"type", L"image");\r
return info;\r
}\r
\r
- virtual void subscribe(const monitor::observable::observer_ptr& o) override \r
+ void subscribe(const monitor::observable::observer_ptr& o) override \r
{\r
return event_subject_.subscribe(o);\r
}\r
\r
- virtual void unsubscribe(const monitor::observable::observer_ptr& o) override \r
+ void unsubscribe(const monitor::observable::observer_ptr& o) override \r
{\r
return event_subject_.unsubscribe(o);\r
}\r
\r
// frame_producer\r
\r
- virtual core::draw_frame receive(int) override\r
+ core::draw_frame receive(int) override\r
{ \r
delta_ += speed_;\r
\r
return last_frame_ = core::draw_frame(frames_);\r
}\r
\r
- virtual core::draw_frame last_frame() const override\r
+ core::draw_frame last_frame() const override\r
{\r
return core::draw_frame::still(last_frame_);\r
}\r
\r
- virtual std::wstring print() const override\r
+ std::wstring print() const override\r
{\r
return L"image_scroll_producer[" + filename_ + L"]";\r
}\r
\r
- virtual std::wstring name() const override\r
+ std::wstring name() const override\r
{\r
return L"image-scroll";\r
}\r
\r
- virtual boost::property_tree::wptree info() const override\r
+ boost::property_tree::wptree info() const override\r
{\r
boost::property_tree::wptree info;\r
info.add(L"type", L"image-scroll");\r
return info;\r
}\r
\r
- virtual uint32_t nb_frames() const override\r
+ uint32_t nb_frames() const override\r
{\r
if(height_ > format_desc_.height)\r
{\r
}\r
}\r
\r
- virtual void subscribe(const monitor::observable::observer_ptr& o) override \r
+ void subscribe(const monitor::observable::observer_ptr& o) override \r
{\r
return event_subject_.subscribe(o);\r
}\r
\r
- virtual void unsubscribe(const monitor::observable::observer_ptr& o) override \r
+ void unsubscribe(const monitor::observable::observer_ptr& o) override \r
{\r
return event_subject_.unsubscribe(o);\r
}\r
\r
// frame consumer\r
\r
- virtual void initialize(const core::video_format_desc& format_desc, int channel_index) override\r
+ void initialize(const core::video_format_desc& format_desc, int channel_index) override\r
{\r
format_desc_ = format_desc; \r
channel_index_ = channel_index;\r
}\r
}\r
\r
- virtual bool send(core::const_frame frame) override\r
+ bool send(core::const_frame frame) override\r
{ \r
if(!input_.try_push(std::make_shared<audio_buffer_16>(core::audio_32_to_16(frame.audio_data()))))\r
graph_->set_tag("dropped-frame");\r
return true;\r
}\r
\r
- virtual std::wstring print() const override\r
+ std::wstring print() const override\r
{\r
return L"oal[" + boost::lexical_cast<std::wstring>(channel_index_) + L"|" + format_desc_.name + L"]";\r
}\r
\r
- virtual std::wstring name() const override\r
+ std::wstring name() const override\r
{\r
return L"system-audio";\r
}\r
\r
- virtual boost::property_tree::wptree info() const override\r
+ boost::property_tree::wptree info() const override\r
{\r
boost::property_tree::wptree info;\r
info.add(L"type", L"system-audio");\r
return info;\r
}\r
\r
- virtual bool has_synchronization_clock() const override\r
+ bool has_synchronization_clock() const override\r
{\r
return false;\r
}\r
\r
- virtual int buffer_depth() const override\r
+ int buffer_depth() const override\r
{\r
return 3;\r
}\r
\r
// oal_consumer\r
\r
- virtual bool OnGetData(sf::SoundStream::Chunk& data) override\r
+ bool OnGetData(sf::SoundStream::Chunk& data) override\r
{ \r
std::shared_ptr<audio_buffer_16> audio_data; \r
input_.pop(audio_data);\r
return is_running_;\r
}\r
\r
- virtual int index() const override\r
+ int index() const override\r
{\r
return 500;\r
}\r
//\r
// // frame_producer\r
// \r
-// virtual core::draw_frame receive(int) override\r
+// core::draw_frame receive(int) override\r
// {\r
// if(!frame_buffer_.empty())\r
// {\r
// return receive(0);\r
// } \r
//\r
-// virtual core::draw_frame last_frame() const override\r
+// core::draw_frame last_frame() const override\r
// {\r
// return core::draw_frame::still(last_frame_);\r
// }\r
// \r
-// virtual std::wstring print() const override\r
+// std::wstring print() const override\r
// {\r
// return L"reroute[]";\r
// }\r
//\r
-// virtual std::wstring name() const override\r
+// std::wstring name() const override\r
// {\r
// return L"reroute";\r
// }\r
//\r
-// virtual boost::property_tree::wptree info() const override\r
+// boost::property_tree::wptree info() const override\r
// {\r
// boost::property_tree::wptree info;\r
// info.add(L"type", L"rerotue-producer");\r
\r
// frame_consumer\r
\r
- virtual void initialize(const core::video_format_desc& format_desc, int channel_index) override\r
+ void initialize(const core::video_format_desc& format_desc, int channel_index) override\r
{\r
consumer_.reset();\r
consumer_.reset(new screen_consumer(config_, format_desc, channel_index));\r
}\r
\r
- virtual bool send(core::const_frame frame) override\r
+ bool send(core::const_frame frame) override\r
{\r
return consumer_->send(frame);\r
}\r
\r
- virtual std::wstring print() const override\r
+ std::wstring print() const override\r
{\r
return consumer_ ? consumer_->print() : L"[screen_consumer]";\r
}\r
\r
- virtual std::wstring name() const override\r
+ std::wstring name() const override\r
{\r
return L"screen";\r
}\r
\r
- virtual boost::property_tree::wptree info() const override\r
+ boost::property_tree::wptree info() const override\r
{\r
boost::property_tree::wptree info;\r
info.add(L"type", L"screen");\r
return info;\r
}\r
\r
- virtual bool has_synchronization_clock() const override\r
+ bool has_synchronization_clock() const override\r
{\r
return false;\r
}\r
\r
- virtual int buffer_depth() const override\r
+ int buffer_depth() const override\r
{\r
return 2;\r
}\r
\r
- virtual int index() const override\r
+ int index() const override\r
{\r
return 600;\r
}\r
public: \r
server(unsigned short port);\r
\r
- virtual void on_next(const monitor::event& e) override;\r
+ void on_next(const monitor::event& e) override;\r
private:\r
spl::shared_ptr<observer<monitor::event>> impl_;\r
};\r
\r
// monitor::observable\r
\r
- virtual void subscribe(const monitor::observable::observer_ptr& o) override;\r
- virtual void unsubscribe(const monitor::observable::observer_ptr& o) override;\r
+ void subscribe(const monitor::observable::observer_ptr& o) override;\r
+ void unsubscribe(const monitor::observable::observer_ptr& o) override;\r
private:\r
struct impl;\r
spl::shared_ptr<impl> impl_;\r