Automatically playing video in 10 second blocks.
#1
Posted 05 July 2011 - 08:11 PM
It's for a uni project I'm about to start - apparently the uni doesn't have a way of doing this or doesn't know how to. I think the files are .mpg, but not 100% on that.
Maybe some kind of free video editing software could do this? But then again uni might not let me install programs on their PC.
Any advice would be appreciated
#2
Posted 05 July 2011 - 09:48 PM
It's probably not the only way of doing it, but without knowing what software is available it's hard to say (I'm assuming Office will be installed on a Uni PC).
2010 Focus XR5 Turbo
Source: Alpine INA-W900E + H100
Fronts: Focal Utopia 165W / Alpine PDX F6
Sub: AlpineType S 12 / Alpine PDX M12
#3
Posted 06 July 2011 - 09:25 AM
What about just a tiny app that emulates 'CTRL+P' every 10 seconds? Or something similar?
V6 Powered GH Sigma (99.08% completed....Lack of funds!)
Daily: VX Calais International - Stock Stereo
Trusted BuyersSellers: dcstraight, Mr_bob, Stik79, smeg, Ben_ra23, bobbyd, TEGBOY, nevrl8, Pyroay, Gozza
#4
Posted 07 July 2011 - 10:59 PM
Yeah it must sound like an unusual request. It's for research into developmental disorders, and involves watching hours of footage of many people. Each 10 second block of video needs to be carefully watched, assessed and given a separate numerical score, which will provide lots of data which can then be analysed with statistics sofware.
So, given the large amount of footage and the need to consider each 10 sec block separately, I am looking for a way to automatically stop the video every 10 sec, so I can keep my eyes on the video instead of the timer, and to stop me from going insane.
An app that emulates 'CTRL+P' every 10 seconds does sound ideal, but I have no idea how to do that. I assume I would need to understand programming to do that?
#5
Posted 07 July 2011 - 11:51 PM
This will be easy to do with a bit of Vbscript.
I'll have a crack at it tomorrow if I have time.
#6
Posted 08 July 2011 - 04:52 PM
Selfdestruktor, on 07 July 2011 - 11:51 PM, said:
This will be easy to do with a bit of Vbscript.
I'll have a crack at it tomorrow if I have time.
Agreed, VBScript or powershell should be ableto do this easily.
V6 Powered GH Sigma (99.08% completed....Lack of funds!)
Daily: VX Calais International - Stock Stereo
Trusted BuyersSellers: dcstraight, Mr_bob, Stik79, smeg, Ben_ra23, bobbyd, TEGBOY, nevrl8, Pyroay, Gozza
#7
Posted 10 July 2011 - 10:44 PM
Wikipedia: "The SendKeys method sends one or more keystrokes to the active window (as if typed on the keyboard). In this example the script sends the characters “Hello World!” three times, each time pausing for 2 seconds (2000 milliseconds).
set shl = createobject("wscript.shell")
shl.sendkeys "Hello World!"
wscript.sleep 2000
shl.sendkeys "Hello World!"
wscript.sleep 2000
shl.sendkeys "Hello World!"
wscript.sleep 2000
The code should be saved as whatever.vbs, then executed using cscript.exe or wscript.exe in a command window. During execution, the characters “Hello World!” will be displayed after the command prompt."
Would Sendkeys be the method to use in my stuation to pause the video?
Edited by Steve77, 10 July 2011 - 10:47 PM.
#8
Posted 12 July 2011 - 12:17 AM
There are a few additional bits and pieces, including 'AppActivate', which switches focus to your chosen application if you haven't got that window active.
I think this is necessary to stop lots of clicking between windows.
Trouble is, it works with every bloody application except for bloody Windows Media Player!!!
I've been trying for hours and can't work it out.
Anyway, I taught myself some different stuff (first time 'not' using Vbscript for me) and have come up with something for you to try.
Here's an exe that I just uploaded to the first fileshare site Google gave me: http://www14.zippysh...57575/file.html
Usage?: Set up your movie in Windows Media Player (i'm using version 12 in Win 7, but others should work too), maximize (but don't fullscreen) and leave paused.
Switch to another window, containing the folder where you've stored the program and run it.
It should switch to Media Player, unpause the movie, play it for 10 seconds, then pop up with a prompt asking whether you want to continue or not.
If yes, it will play for another 10 seconds, pause, play, pause, etc.....
If no, it will simply break out of the loop and the program will shut itself off.
A real programmer could probably do a better job, but it works (for me anyway).
Ha ha.... crap.... it's late.... nooooooo!!! I love sleep too much!!!
#9
Posted 12 July 2011 - 11:24 AM
If you started with VLC, that already has scripting, and even http control modes built in.
Just a thought
edit:
here are some examples of making a web "page" that plays a file under javascript control
http://wiki.videolan...ation:WebPlugin
[more]
humm looks like WMP 11-12 understand dlna and uPnP av - so you might be able to script your playback via one of those command interfaces
(at least its another avenue of attack for you)
good luck!
Jen
Edited by iffer, 12 July 2011 - 06:40 PM.
#10
Posted 13 July 2011 - 11:00 PM
I have downloaded the .exe file that Selfdestruktor made, and it works great on my computer. It will make my work a lot easier!
Now I just need to try it at uni next week. I assume it will work on their computer, unless there is some kind of security thing to stop us saving and running executable files.
The only other thing on my wishlist would be another button which would replay the previous 10sec block again when needed, but hey I'm not complaining - the .exe file is very helpful the way it is.
Thanks Selfdestruktor for your time and effort, it's much appreciated!
#11
Posted 16 July 2011 - 12:40 AM
They just happened to skip you back and forward in 10 sec blocks.
However, starting in WMP 12 (I believe), you have to 'focus' on the progress bar thing (click on it) before this will work.
With my basically non-existent programming knowledge, and limitations of WMP, it's going to be pretty hard.
If it has to be something transportable, it might be better to go for the suggested VLC.
Don't have much time these days, but I might look into it at some stage.
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users













