-
Notifications
You must be signed in to change notification settings - Fork 1
/
dev.html
74 lines (54 loc) · 2.88 KB
/
dev.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
<!DOCTYPE html>
<html lang="en">
<head>
<title>Unique Flow</title>
<meta charset="utf-8">
<meta http-equiv="Content-Type" content="text/html;charset=utf-8">
<meta http-equiv="x-ua-compatible" content="ie=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, user-scalable=no, minimal-ui">
<meta name="twitter:card" content="summary_large_image"/>
<meta name="twitter:site" content=""/>
<meta name="twitter:creator" content="@mark_lundin"/>
<meta name="twitter:title" content="Unique Flow">
<meta name="twitter:description" content="A realtime generative animation built with WebGL">
<meta name="twitter:image" content="http://www.mark-lundin.com/uniqueflow/assets/twitter-share.jpg">
<meta property="og:locale" content="en_GB" />
<meta property="og:title" content="Unique Flow" />
<meta property="og:description" content="A realtime generative animation built with WebGL">
<meta property="og:url" content="http://www.mark-lundin.com/uniqueflow" />
<meta property="og:image" content="http://www.mark-lundin.com/uniqueflow/assets/facebook-share.jpg" />
<meta property="og:image:width" content="1204" />
<meta property="og:type" content="website" />
<meta property="og:site_name" content="Unique Flow" />
<meta name="share-text" content="My Unique Flow artwork in collaboration with @field_io">
<link href="assets/main.css" rel="stylesheet" type="text/css">
<!-- <link rel="stylesheet" href="https://fonts.googleapis.com/icon?family=Material+Icons"> -->
<!-- <link rel="stylesheet" href="https://code.getmdl.io/1.1.1/material.indigo-red.min.css"> -->
<!-- <script defer src="https://code.getmdl.io/1.1.1/material.min.js"></script> -->
<script src='src/canvas-to-blob.min.js'></script>
<script src='src/FileSaver.min.js'></script>
<script src='jspm_packages/system.js'></script>
<script src='config.js'></script>
</head>
<body>
<div id="main"></div>
<button id="cast" class="mdl-button cast-button"></button>
<script type="text/javascript">
console.warn( 'For those of you that way inclined, you can run this application as a second screen from any high powered Cast enabled device' )
// console.warn( 'If you want to capture a still of the render, you can call `capture()` from the console')
var filePath = './jspm_packages/github/marklundin/toyota2@gh-pages/'
var canvas = document.createElement("canvas");
document.querySelector("#main").appendChild(canvas);
// Start the app
var artwork
System.import( './src/main' ).then( function(){
artwork = new InstallationArtwork( canvas, filePath, devicePixelRatio )
})
// Screen grab
function capture(){
var canvas = document.querySelector('canvas')
canvas.toBlob( function( blob ){ saveAs( blob, 'unique-flow.png' )})
}
</script>
</body>
</html>