-- frame and not per field, since we deinterlace.
local last_resolution = {}
-local caspar_input = VideoInput.new("unix:///tmp/caspar.sock", Nageru.VIDEO_FORMAT_BGRA)
-caspar_input:change_rate(2.0)
+local cef_input = HTMLInput.new("file:///home/sesse/dev/ultimatescore/score.html")
+cef_input:set_url("file:///home/sesse/dev/ultimatescore/score.html");
+cef_input:execute_javascript_async("play()")
+
+function reload_cef()
+ cef_input:reload()
+ cef_input:execute_javascript_async("play()")
+end
-- Utility function to help creating many similar chains that can differ
-- in a free set of chosen parameters.
-- An overlay with variable alpha.
function make_overlay(chain, base)
- local image = chain:add_video_input(caspar_input, false)
+ local image = chain:add_html_input(cef_input)
local multiply_effect = chain:add_effect(MultiplyEffect.new())
local overlay_effect = chain:add_effect(OverlayEffect.new(), base, multiply_effect)
return {
-- A chain to show the overlay and nothing more. LQ only,
-- since it is not a valid live signal.
local overlay_chain_lq = EffectChain.new(16, 9)
-local overlay_chain_lq_input = overlay_chain_lq:add_video_input(caspar_input, false)
+local overlay_chain_lq_input = overlay_chain_lq:add_html_input(cef_input)
overlay_chain_lq:finalize(false)
-- Used for indexing into the tables of chains.
return tt
end
+
+ThemeMenu.set(
+ { "Reload overlay", reload_cef }
+)