<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Profile|Win32'">Create</PrecompiledHeader>\r
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Develop|Win32'">Create</PrecompiledHeader>\r
</ClCompile>\r
+ <ClCompile Include="video_channel_context.cpp" />\r
<ClCompile Include="video_format.cpp">\r
<PrecompiledHeaderFile Condition="'$(Configuration)|$(Platform)'=='Profile|Win32'">StdAfx.h</PrecompiledHeaderFile>\r
<PrecompiledHeaderFile Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">StdAfx.h</PrecompiledHeaderFile>\r
</ClCompile>\r
<ClCompile Include="video_channel.cpp" />\r
<ClCompile Include="StdAfx.cpp" />\r
+ <ClCompile Include="video_channel_context.cpp" />\r
</ItemGroup>\r
</Project>
\ No newline at end of file
--- /dev/null
+#include "stdAfx.h"\r
+\r
+#include "video_channel_context.h"\r
+\r
+namespace caspar { namespace core {\r
+\r
+video_channel_context::video_channel_context(int index, ogl_device& ogl, const video_format_desc& format_desc) \r
+ : index_(index)\r
+ , format_desc_(format_desc)\r
+ , execution_(print() + L"/execution")\r
+ , destruction_(print() + L"/destruction")\r
+ , ogl_(ogl)\r
+{\r
+ execution_.set_priority_class(above_normal_priority_class);\r
+ destruction_.set_priority_class(below_normal_priority_class);\r
+}\r
+\r
+const int video_channel_context::index() const {return index_;}\r
+\r
+video_format_desc video_channel_context::get_format_desc()\r
+{\r
+ tbb::spin_rw_mutex::scoped_lock lock(mutex_, false);\r
+ return format_desc_;\r
+}\r
+\r
+void video_channel_context::set_format_desc(const video_format_desc& format_desc)\r
+{\r
+ tbb::spin_rw_mutex::scoped_lock lock(mutex_, true);\r
+ format_desc_ = format_desc;\r
+}\r
+\r
+executor& video_channel_context::execution() {return execution_;}\r
+executor& video_channel_context::destruction() {return destruction_;}\r
+ogl_device& video_channel_context::ogl() { return ogl_;}\r
+\r
+std::wstring video_channel_context::print() const\r
+{\r
+ return L"video_channel[" + boost::lexical_cast<std::wstring>(index_+1) + L"-" + format_desc_.name + L"]";\r
+}\r
+\r
+}}
\ No newline at end of file
ogl_device& ogl_;\r
\r
public:\r
- video_channel_context(int index, ogl_device& ogl, const video_format_desc& format_desc) \r
- : index_(index)\r
- , format_desc_(format_desc)\r
- , execution_(print() + L"/execution")\r
- , destruction_(print() + L"/destruction")\r
- , ogl_(ogl)\r
- {\r
- execution_.set_priority_class(above_normal_priority_class);\r
- destruction_.set_priority_class(below_normal_priority_class);\r
- }\r
-\r
- const int index() const {return index_;}\r
-\r
- video_format_desc get_format_desc()\r
- {\r
- tbb::spin_rw_mutex::scoped_lock lock(mutex_, false);\r
- return format_desc_;\r
- }\r
-\r
- void set_format_desc(const video_format_desc& format_desc)\r
- {\r
- tbb::spin_rw_mutex::scoped_lock lock(mutex_, true);\r
- format_desc_ = format_desc;\r
- }\r
-\r
- executor& execution() {return execution_;}\r
- executor& destruction() {return destruction_;}\r
- ogl_device& ogl() { return ogl_;}\r
-\r
- std::wstring print() const\r
- {\r
- return L"video_channel[" + boost::lexical_cast<std::wstring>(index_+1) + L"-" + format_desc_.name + L"]";\r
- }\r
+ video_channel_context(int index, ogl_device& ogl, const video_format_desc& format_desc);\r
+\r
+ const int index() const;\r
+ video_format_desc get_format_desc();\r
+ void set_format_desc(const video_format_desc& format_desc);\r
+ executor& execution();\r
+ executor& destruction();\r
+ ogl_device& ogl();\r
+ std::wstring print() const;\r
};\r
\r
}}
\ No newline at end of file