yWeb: enable grab to do screenshots

Origin commit data
------------------
Branch: ni/coolstream
Commit: 641346d84b
Author: vanhofen <vanhofen@gmx.de>
Date: 2017-10-13 (Fri, 13 Oct 2017)

Origin message was:
------------------
- yWeb: enable grab to do screenshots

------------------
No further description and justification available within origin commit message!

------------------
This commit was generated by Migit
This commit is contained in:
vanhofen
2017-10-13 14:06:04 +02:00
parent 5ae57414b0
commit d2d00f8d7a
3 changed files with 20 additions and 4 deletions

View File

@@ -1,3 +1,4 @@
{=var-set:grab={=find-exec:grab=}=}
{=var-set:fbshot={=find-exec:fbshot=}=}
{=include-block:Y_NI_Blocks.txt;head=}
@@ -43,8 +44,10 @@ function do_snapshot() {
filename = id("filename").value;
}
if ("{=var-get:fbshot=}" != "" && enableVideo == 0)
dbox_exec_tools("fbshot fb /tmp/"+filename+".png");
if ("{=var-get:grab=}" != "" && enableVideo == 0)
dbox_exec_tools("fbshot grab -p -o /tmp/"+filename+".png");
else if ("{=var-get:fbshot=}" != "" && enableVideo == 0)
dbox_exec_tools("fbshot fbshot /tmp/"+filename+".png");
else
loadSyncURL("/control/screenshot?name="+filename+"&osd="+enableOSD+"&video="+enableVideo);