2016-04-07 16 views

答えて

3

一つの可能​​な解決策は--stop-time <seconds>を指定することです:

subprocess.call([vlc_path, video_path, '--play-and-exit', 
    '--fullscreen', '--stop-time','3600'], shell=False) 

長いヘルプ(vlc -H)から:

Playback control: 
    --input-repeat <integer [-2147483648 .. 2147483647]> 
          Input repetitions 
     Number of time the same input will be repeated 
    --start-time <float>  Start time 
     The stream will start at this position (in seconds). 
    --stop-time <float>  Stop time 
     The stream will stop at this position (in seconds). 
    --run-time <float>   Run time 
     The stream will run this duration (in seconds). 
+0

はyou.Whereをありがとう、私はVLCのコマンドラインのヘルプを参照してくださいか? 端末に「vlc:command not found」が表示されます。 – Jaydev

+0

@JaydevKalivarapuあなたが 'bash'を使用していると仮定します。通常、vlcはインストール時にコマンドとして追加されます。 '.bashrc':' alias vlc = abs_vlc_path'にエイリアスとして追加することができます。 Windowsを使用している場合は、[here](http://superuser.com/questions/689333/how-to-add-installed-program-to-command-prompt-in-news)に記載されているように、vlc.exeをパスに追加する必要があります。 windows) –

+0

-bash:abs_vlc_path:コマンドが見つかりません 明らかに間違っていますか? – Jaydev

関連する問題