tarina

git clone https://git.tarina.org/tarina
Log | Files | Refs | README | LICENSE

filmpage.html (2177B)


      1 $def with (film, scenes, str, filmfolder, counttakes, countshots, shots, scene, takes, shot, take)
      2 $ video = ''
      3 $if take != None:
      4     <h1>$film | scene $scene | shot $shot | take $take</h1>
      5     <h2><a href='?scene=$scene&shot=$shot'>go back</a></h2><br>
      6     $ video = '/static/Videos/' + film + '/scene' + str(scene).zfill(3) + '/shot' + str(shot).zfill(3) + '/take' + str(take).zfill(3) + '.mp4'
      7 $elif shot != None:
      8     <h1>$film | scene $scene | shot $shot</h1>
      9     <h2><a href='?scene=$scene'>go back</a></h2><br>
     10     $ video = '/static/Videos/' + film + '/scene' + str(scene).zfill(3) + '/shot' + str(shot).zfill(3) + '/take' + str(takes).zfill(3) + '.mp4'
     11 $elif scene != None:
     12     <h1>$film | scene $scene</h1>
     13     <h2><a href='/f/$film'>go back</a><h2><br>
     14     $ video = '/static/Videos/' + film + '/scene' + str(scene).zfill(3) + '/scene.mp4'
     15 $elif scene == None:
     16     <h1>$film</h1>
     17     $ video = '/static/Videos/' + film + '/' + film + '.mp4'
     18 <video width="80%" controls>
     19 <source src="$video" type="video/mp4">
     20 Your brower is caput
     21 </video>
     22 <p>Copy project to your destination:</p>
     23 <pre>scp -r pi@tarina.local:~/Videos/$film ~/films/$film </pre>
     24 
     25 $if shot != None:
     26     $for t in range(takes):
     27         $ thumbnail_url = '/static/Videos/' + film + '/scene' + str(scene).zfill(3) + '/shot' + str(shot).zfill(3) + '/take' + str(t+1).zfill(3) + '.jpeg'
     28         <a href="?scene=$scene&shot=$shot&take=${str(t+1)}"><img width="80%" src="$thumbnail_url"/></a><br>
     29 $elif scene != None:
     30     $for s in range(shots)
     31         $ t = countshots(film, filmfolder, scene)
     32         $ p = counttakes(film, filmfolder, scene, s+1)
     33         $ thumbnail_url = '/static/Videos/' + film + '/scene' + str(scene).zfill(3) + '/shot' + str(s+1).zfill(3) + '/take' + str(p).zfill(3) + '.jpeg'
     34         <a href="?scene=$scene&shot=${str(s+1)}"><img width="80%" src="$thumbnail_url"/></a><br>
     35 $else:
     36     $for s in range(scenes):
     37         $ t = counttakes(film, filmfolder, s+1, 1)
     38         $ thumbnail_url = '/static/Videos/' + film + '/scene' + str(s+1).zfill(3) + '/shot001/take' + str(t).zfill(3) + '.jpeg'
     39         <a href="?scene=${str(s+1)}"><img width="80%" src="$thumbnail_url"/></a><br>