Julien Chaumond commited on
Commit
d039b4e
·
0 Parent(s):

initial import

Browse files
.gitattributes ADDED
@@ -0,0 +1 @@
 
 
1
+ *.usdz filter=lfs diff=lfs merge=lfs -text
ec5eb683-8d16-4def-b542-9e48fa8c0ae0.jpg ADDED
ec5eb683-8d16-4def-b542-9e48fa8c0ae0.usdz ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:e33081cb46b524ad08024931e41bd6acd66252c95f8c1799c04ec1055373672e
3
+ size 1027916
index.html ADDED
@@ -0,0 +1,30 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <title>Talking Egg 🥚</title>
6
+ <meta property="og:title" content="Talking Egg – USDZ Preview">
7
+ <meta name="description" content="Turn ideas into AR Experience with this easy-to-use online 3D modeling software.">
8
+ <meta property="og:description" content="Turn ideas into AR Experience with this easy-to-use online 3D modeling software.">
9
+ <meta name="keywords" content="3d design, 3d design software, 3d design online, 3d modeling, 3d modeling online, 3d render, usdz, usdz file, usdz converter, usdz embed, 3d file">
10
+ <meta property="og:type" content="website">
11
+ <meta property="og:url" content="https://huggingface.co/">
12
+ <link rel="shortcut icon" type="image/png" href="https://www.vectary.com/static/images/favicon.png">
13
+ <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no">
14
+ <link href="https://fonts.googleapis.com/css?family=Open+Sans:400" rel="stylesheet" preload="preload">
15
+ <script src="https://code.jquery.com/jquery-3.3.1.min.js"
16
+ integrity="sha256-FgpCb/KJQlLNfOu91ta32o/NMZxltwRo8QtmkMRdAu8=" crossOrigin="anonymous"></script>
17
+ <script src="./usdz-embed.js" async=""></script>
18
+ <link rel="stylesheet" href="./usdz-embed.css" preload="preload">
19
+ </head>
20
+ <body>
21
+ <div class="viewerVersionNote">
22
+ <span>Visit this page on iOS 12 in Safari to try AR Quick Look</span>
23
+ </div>
24
+ <img src="./svg-a.svg" class="ar">
25
+ <div class="cleanPreview"></div>
26
+ <a href="./ec5eb683-8d16-4def-b542-9e48fa8c0ae0.usdz" rel="ar">
27
+ <img src="./ec5eb683-8d16-4def-b542-9e48fa8c0ae0.jpg">
28
+ </a>
29
+ </body>
30
+ </html>
simple.html ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <title>Talking Egg 🥚</title>
6
+ </head>
7
+ <body>
8
+ <a href="./ec5eb683-8d16-4def-b542-9e48fa8c0ae0.usdz" rel="ar">
9
+ <img src="./ec5eb683-8d16-4def-b542-9e48fa8c0ae0.jpg">
10
+ </a>
11
+ </body>
12
+ </html>
svg-a.svg ADDED
usdz-embed.css ADDED
@@ -0,0 +1,117 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ html, body {
2
+ height: 100%;
3
+ width: 100%;
4
+ font-family: Open Sans, sans-serif;
5
+ font-size: 13px;
6
+ }
7
+
8
+ body {
9
+ margin: 0;
10
+ display: flex;
11
+ justify-content: center;
12
+ align-items: center;
13
+ flex-direction: column;
14
+ position: relative;
15
+ }
16
+
17
+ h1, h3 {
18
+ display: block;
19
+ }
20
+
21
+ img {
22
+ width: 100vw;
23
+ height: 100vh;
24
+ display: block;
25
+ object-fit: cover;
26
+ }
27
+
28
+ .cleanPreview {
29
+ position: absolute;
30
+ width: 100vw;
31
+ height: 100vh;
32
+ display: block;
33
+ z-index: 2;
34
+ top: 0;
35
+ left: 0;
36
+ pointer-events: none;
37
+ }
38
+ .cleanPreview.active {
39
+ z-index: 3;
40
+ }
41
+
42
+ a {
43
+ z-index: 0;
44
+ display: block;
45
+ position: relative;
46
+ }
47
+
48
+ a.disabled {
49
+ cursor: default;
50
+ }
51
+
52
+ .viewerVersionNote {
53
+ opacity: 0;
54
+ visibility: hidden;
55
+ position: absolute;
56
+ top: 20px;
57
+ left: 0;
58
+ right: 0;
59
+ padding: 0 20px;
60
+ pointer-events: none;
61
+ transition: all 0.3s ease;
62
+ z-index: 2;
63
+ color: #555;
64
+ text-align: center;
65
+ }
66
+
67
+ .viewerVersionNote span {
68
+ margin: auto;
69
+ display: inline-block;
70
+ background: rgba(255, 255, 255, 0.9);
71
+ padding: 10px 15px;
72
+ border-radius: 3px;
73
+ }
74
+
75
+ .viewerVersionNote.active {
76
+ opacity: 1;
77
+ visibility: visible;
78
+ }
79
+
80
+ svg.ar {
81
+ position: fixed;
82
+ z-index: 10;
83
+ top: 20px;
84
+ right: 20px;
85
+ visibility: hidden;
86
+ opacity: 0;
87
+ transition: all 0.3s ease;
88
+ pointer-events: none;
89
+ }
90
+
91
+ img.ar {
92
+ position: fixed;
93
+ z-index: 10;
94
+ top: 20px;
95
+ right: 20px;
96
+ visibility: hidden;
97
+ opacity: 0;
98
+ transition: all 0.3s ease;
99
+ pointer-events: none;
100
+ width: 74px;
101
+ height: 74px;
102
+ }
103
+
104
+ img.ar.active {
105
+ opacity: 1;
106
+ visibility: visible;
107
+ }
108
+
109
+ img.vectaryLogo {
110
+ position: fixed;
111
+ z-index: 9;
112
+ bottom: 20px;
113
+ left: 20px;
114
+ opacity: 0.8;
115
+ width: 113px;
116
+ height: auto;
117
+ }
usdz-embed.js ADDED
@@ -0,0 +1,26 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ $(document).ready(function () {
2
+ function iOSversion() {
3
+ if (/iP(hone|od|ad)/.test(navigator.platform)) {
4
+ var v = (navigator.appVersion).match(/OS (\d+)_(\d+)_?(\d+)?/);
5
+ return [parseInt(v[1], 10), parseInt(v[2], 10), parseInt(v[3] || 0, 10)];
6
+ }
7
+ }
8
+
9
+ version = iOSversion();
10
+ var ua = window.navigator.userAgent;
11
+ var iOS = !!ua.match(/iPad/i) || !!ua.match(/iPhone/i);
12
+ var webkit = !!ua.match(/WebKit/i);
13
+ var iOSSafari = iOS && webkit && !ua.match(/CriOS/i);
14
+
15
+ if ((version) && (iOSSafari) && (version[0] >= 12)) {
16
+ var defaultImage = $('a').html();
17
+ $('.cleanPreview').html(defaultImage);
18
+ $('img.ar').addClass('active');
19
+ setTimeout(function(){
20
+ $('.cleanPreview').addClass('active');
21
+ }, 100);
22
+ } else {
23
+ $('.viewerVersionNote').addClass('active');
24
+ $('a').attr('href', '#').addClass('disabled');
25
+ }
26
+ });