luarc: add frame by frame support.
authorRémi Duraffort <ivoire@videolan.org>
Thu, 12 Nov 2009 17:58:58 +0000 (18:58 +0100)
committerRémi Duraffort <ivoire@videolan.org>
Fri, 13 Nov 2009 16:48:35 +0000 (17:48 +0100)
share/lua/intf/rc.lua

index ae18bc0..4b07157 100644 (file)
@@ -384,6 +384,10 @@ function rate(name,client)
     end
 end
 
+function frame(name,client)
+    vlc.var.trigger_callback(vlc.object.input(),"frame-next");
+end
+
 function listvalue(obj,var)
     return function(client,value)
         local o = vlc.object.find(nil,obj,"anywhere")
@@ -443,8 +447,10 @@ commands_ordered = {
     { "faster"; { func = rate; help = "faster playing of stream" } };
     { "slower"; { func = rate; help = "slower playing of stream" } };
     { "normal"; { func = rate; help = "normal playing of stream" } };
+    { "frame"; { func = frame; help = "play frame by frame" } };
     { "fullscreen"; { func = skip2(vlc.video.fullscreen); args = "[on|off]"; help = "toggle fullscreen"; aliases = { "f", "F" } } };
     { "info"; { func = input_info; help = "information about the current stream" } };
+    { "states"; { func = fixme; help = "show statistical information" } };
     { "get_time"; { func = get_time("time"); help = "seconds elapsed since stream's beginning" } };
     { "is_playing"; { func = is_playing; help = "1 if a stream plays, 0 otherwise" } };
     { "get_title"; { func = ret_print(vlc.input.get_title); help = "the title of the current stream" } };