update syncplay.lua - improve display-osd, verup
This commit is contained in:
parent
1fc34a088a
commit
443396d873
@ -8,7 +8,7 @@
|
|||||||
require "common"
|
require "common"
|
||||||
require "host"
|
require "host"
|
||||||
|
|
||||||
local connectorversion = "0.0.1"
|
local connectorversion = "0.0.2"
|
||||||
|
|
||||||
local port
|
local port
|
||||||
|
|
||||||
@ -33,7 +33,11 @@ function get_args (argument, argcount)
|
|||||||
|
|
||||||
for i = 1, argcount,1 do
|
for i = 1, argcount,1 do
|
||||||
if i == argcount then
|
if i == argcount then
|
||||||
|
if argbuffer == nil then
|
||||||
|
argarray[i] = ""
|
||||||
|
else
|
||||||
argarray[i] = argbuffer
|
argarray[i] = argbuffer
|
||||||
|
end
|
||||||
else
|
else
|
||||||
if string.find(argbuffer, argseperator) then
|
if string.find(argbuffer, argseperator) then
|
||||||
index = string.find(argbuffer, argseperator)
|
index = string.find(argbuffer, argseperator)
|
||||||
@ -135,9 +139,14 @@ end
|
|||||||
function display_osd ( argument )
|
function display_osd ( argument )
|
||||||
local errormsg
|
local errormsg
|
||||||
local osdarray
|
local osdarray
|
||||||
osdarray = get_args(argument,3)
|
local input = vlc.object.input()
|
||||||
--position, duration ms, message
|
if input then
|
||||||
vlc.osd.message(osdarray[3],channel1,osdarray[1],osdarray[2])
|
osdarray = get_args(argument,3)
|
||||||
|
--position, duration, message -> message, , position, duration
|
||||||
|
vlc.osd.message(osdarray[3],channel1,osdarray[1],tonumber(osdarray[2]))
|
||||||
|
else
|
||||||
|
errormsg = noinput
|
||||||
|
end
|
||||||
return errormsg
|
return errormsg
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user