{"id":1436,"date":"2018-10-26T02:29:41","date_gmt":"2018-10-26T02:29:41","guid":{"rendered":"https:\/\/lab.florianschwarz.net\/PennController\/?post_type=yada_wiki&#038;p=1436"},"modified":"2018-10-26T02:29:41","modified_gmt":"2018-10-26T02:29:41","slug":"video-settings-log","status":"publish","type":"yada_wiki","link":"https:\/\/lab.florianschwarz.net\/PennController\/wiki\/video-settings-log\/","title":{"rendered":"video.settings.log"},"content":{"rendered":"<p class='command-format'><code>getVideo(id).settings.log()<\/code><\/p>\n<p class='command-format'>or <code>getVideo(id).settings.log(\"play\")<\/code><\/p>\n<p class='command-format'>or <code>getVideo(id).settings.log(\"pause\")<\/code><\/p>\n<p class='command-format'>or <code>getVideo(id).settings.log(\"end\")<\/code><\/p>\n<p class='command-format'>or <code>getVideo(id).settings.log(\"seek\")<\/code><\/p>\n<p>Tells to add a line in the results file each time an event happens. If you do not specify which event you want to log, all of them will add a line to the results file.<\/p>\n<p><em>&#8220;play&#8221;<\/em> adds a line including a timestamp and an offset, as the playing is sometimes detected only after a delay. You can compute the actual timestamp for when some sound started to be emitted by subtracting the offset from the timestamp.<\/p>\n<p><em>&#8220;pause&#8221;<\/em> and <em>&#8220;end&#8221;<\/em> add lines of the same format for the respective events. <em>&#8220;seek&#8221;<\/em> adds a line when the progress bar is clicked (visible if the controls are displayed, see the action <code>print<\/code>).<\/p>\n<p><strong>Example:<\/strong><\/p>\n<p>[js highlight=&#8221;6&#8243;]<br \/>\nnewText(&#8220;instructions&#8221;, &#8220;Please watch the video below&#8221;)<br \/>\n    .print()<br \/>\n,<br \/>\nnewVideo(&#8220;scene&#8221;, &#8220;test_scene.mp4&#8221;)<br \/>\n    .settings.once()<br \/>\n    .settings.log()<br \/>\n    .print()<br \/>\n    .wait()<br \/>\n,<br \/>\nnewButton(&#8220;validation&#8221;, &#8220;Validate&#8221;)<br \/>\n    .print()<br \/>\n    .wait()<br \/>\n[\/js]<\/p>\n<p>Adds some instruction text to the screen and control buttons below the text. After the video gets played, the control buttons are grayed out, and a <em>Validate<\/em> button appears below them.<\/p>\n<p>The results file will contain as many lines for when the video was played, paused, when it ended playing and when its position was changed by clicking the progress bar.<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"_bbp_topic_count":0,"_bbp_reply_count":0,"_bbp_total_topic_count":0,"_bbp_total_reply_count":0,"_bbp_voice_count":0,"_bbp_anonymous_reply_count":0,"_bbp_topic_count_hidden":0,"_bbp_reply_count_hidden":0,"_bbp_forum_subforum_count":0,"inline_featured_image":false,"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"wiki_cats":[13,5,4,14,30],"wiki_tags":[],"class_list":["post-1436","yada_wiki","type-yada_wiki","status-publish","hentry","wiki_cats-command","wiki_cats-documentation","wiki_cats-element","wiki_cats-settings-command","wiki_cats-video-element"],"_links":{"self":[{"href":"https:\/\/lab.florianschwarz.net\/PennController\/wp-json\/wp\/v2\/yada_wiki\/1436","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/lab.florianschwarz.net\/PennController\/wp-json\/wp\/v2\/yada_wiki"}],"about":[{"href":"https:\/\/lab.florianschwarz.net\/PennController\/wp-json\/wp\/v2\/types\/yada_wiki"}],"author":[{"embeddable":true,"href":"https:\/\/lab.florianschwarz.net\/PennController\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/lab.florianschwarz.net\/PennController\/wp-json\/wp\/v2\/comments?post=1436"}],"version-history":[{"count":1,"href":"https:\/\/lab.florianschwarz.net\/PennController\/wp-json\/wp\/v2\/yada_wiki\/1436\/revisions"}],"predecessor-version":[{"id":1437,"href":"https:\/\/lab.florianschwarz.net\/PennController\/wp-json\/wp\/v2\/yada_wiki\/1436\/revisions\/1437"}],"wp:attachment":[{"href":"https:\/\/lab.florianschwarz.net\/PennController\/wp-json\/wp\/v2\/media?parent=1436"}],"wp:term":[{"taxonomy":"wiki_cats","embeddable":true,"href":"https:\/\/lab.florianschwarz.net\/PennController\/wp-json\/wp\/v2\/wiki_cats?post=1436"},{"taxonomy":"wiki_tags","embeddable":true,"href":"https:\/\/lab.florianschwarz.net\/PennController\/wp-json\/wp\/v2\/wiki_tags?post=1436"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}