forked from hummypkg/webif
f0d22b3b01
git-svn-id: file:///root/webif/svn/humax/pkg/src/webif/trunk@1052 2a923420-c742-0410-a762-8d5b09965624
67 lines
1.7 KiB
Plaintext
Executable File
67 lines
1.7 KiB
Plaintext
Executable File
#!/mod/bin/jimsh
|
|
|
|
package require cgi
|
|
source /mod/webif/lib/setup
|
|
require ts.class pretty_size
|
|
|
|
puts "Content-Type: text/html\r\n\r\n"
|
|
|
|
cgi_input
|
|
#cgi_dump
|
|
|
|
set rfile [cgi_get file]
|
|
set ts [ts fetch $rfile]
|
|
set dir [file dirname $rfile]
|
|
|
|
set len [$ts duration 1]
|
|
|
|
set esttime $([$ts size] / 5700000)
|
|
|
|
header
|
|
|
|
puts "
|
|
<link href=/css/jquery.progressbar.css rel=stylesheet type=text/css />
|
|
<script type=text/javascript src=/js/jquery.progressbar.js></script>
|
|
<script type=text/javascript src=strip.js></script>
|
|
|
|
<fieldset class=cleft>
|
|
<legend>Strip unecessary frames from recording</legend>
|
|
|
|
<p><i>This process will remove freeview EIT packets from the recording.<br>
|
|
These packets are not required but typically increase the size of the
|
|
recording file by as much as 20%.<br>
|
|
Your original recording files will be retained in a folder called _original.
|
|
</i>
|
|
|
|
<table class=keyval cellpadding=5>
|
|
<tr><th>File:</th><td>$rfile</td></tr>
|
|
<tr><th>Length:</th><td>[clock format $len -format %T]</td></tr>
|
|
<tr><th>Size:</th><td>[pretty_size [$ts size]] ([$ts get definition])</td></tr>
|
|
<tr><th>Time:</th>
|
|
<td>Stripping will take around [clock format $esttime -format "%T"]</td></tr>
|
|
<tr><th>Estimated Saving:</th>
|
|
<td class=va><span id=analysis class=va>
|
|
<img class=va src=/img/loading.gif> Analysing file, please wait...
|
|
</span></td></tr>
|
|
</table>
|
|
|
|
<span class=hidden id=params
|
|
file=\"[cgi_quote_url $rfile]\"
|
|
dir=\"[cgi_quote_url $dir]\"
|
|
></span>
|
|
|
|
<div id=stripdiv class=hidden style=\"padding: 1em\">
|
|
<button id=stripit>Perform strip operation</button>
|
|
</div>
|
|
|
|
<div id=progressdiv class=hidden>
|
|
Stripping: <div id=progressbar></div>
|
|
</div>
|
|
|
|
<button id=back class=hidden>Back to media list</button>
|
|
|
|
<div id=output class=pre style=\"margin-top: 10px\"></div>
|
|
</fieldset>
|
|
"
|
|
|