forked from fbuchinger/rawson.js
-
Notifications
You must be signed in to change notification settings - Fork 0
/
rawson.html
236 lines (189 loc) · 7.93 KB
/
rawson.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
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<title>rawson.js - a camera raw previewer in javascript</title>
<meta http-equiv="content-type" content="text/html;charset=utf-8" />
<link rel="stylesheet" type="text/css" href="external/bootstrap/css/bootstrap.min.css"/>
<link rel="stylesheet" type="text/css" href="external/bootstrap/css/darkstrap.css"/>
<script type="text/javascript">
var Module = {
noInitialRun: true,
printErr: function(data){alert(data)}
};
</script>
<script type="text/javascript" src="build/dcraw.js"></script>
<script type="text/javascript" src="external/jquery-1.7.1.min.js"></script>
<script type="text/javascript" src="external/handlebars.js"></script>
<script type="text/javascript" src="lib/rawson.util.js"></script>
<script type="text/javascript" src="lib/rawson.js"></script>
<script type="text/javascript" src="lib/rawson.viewer.js"></script>
<script type="text/javascript" src="lib/rawson.formats.js"></script>
<script type="text/javascript" src="lib/rawson.controls.js"></script>
<script type="text/javascript" src="lib/controls/menu.js"></script>
<script type="text/javascript" src="lib/controls/imageposter.js"></script>
<script type="text/javascript" src="lib/controls/filedragndrop.js"></script>
<script type="text/javascript" src="lib/controls/fileopener.js"></script>
<script type="text/javascript" src="lib/controls/imagesaver.js"></script>
<script type="text/javascript" src="lib/controls/fileprogress.js"></script>
<script type="text/javascript" src="lib/controls/thumbnaillist.js"></script>
<script type="text/javascript" src="lib/controls/metadatatable.js"></script>
<script type="text/javascript" src="lib/controls/zoom.js"></script>
<script type="text/javascript" src="lib/rawson.services.js"></script>
<script type="text/javascript" src="lib/rawson.preview.js"></script>
<script type="text/javascript" src="external/jquery.event.drag-2.0.min.js"></script>
<script type="text/javascript" src="external/bootstrap/js/bootstrap.min.js"></script>
<style>
body {
font-family: Arial, Helvetica,Verdana,sans-serif;
}
#content {
margin-left:20%;
margin-right:20%;
}
#preview-container {
position:relative;
overflow: hidden;
top:50px;
}
a.inactive {
color: #ddd !important;
}
#preview-container img, #preview-container canvas {
display:block;
position: relative;
background-color: green;
/*border: none;
width: 800px;
height: 600px;*/
}
.drag-hint {
bottom: 0;
height: 40px;
left: 0;
margin: auto;
position: absolute;
right: 0;
top: 0;
width: 300px;
font-size:24px;
color:#ddd;
}
.thumbnails {
height: 200px;
overflow: auto;
}
.hero-unit {
background-color: inherit;
padding: 0;
border: 0px dashed #ddd;
}
.sidebar-nav {
padding: 9px 0;
}
.subheadline {
font-size:12px;
text-transform:uppercase;
}
.footer {
color:#fff;
font-size:11px;
position:absolute;
width:auto;
padding-left:30%;
height:20px;
bottom:10px;
top:0;
left:0;
right:0;
margin:auto;
margin-bottom:0px;
}
</style>
<script>
$(function(){
window.rawViewer = new Rawson.Viewer('preview',{
formats: {
read: ['JPEG', 'PNG','RAW'],
write: ['JPEG', 'PNG'],
},
controls: [
new Rawson.Control.Menu({
container: '#menu-container',
menuItems: [
{id:'file', label:'File'},
{id:'image', label:'Image'},
{id:'rawson', label:'Rawson.js'},
{id:'rawson-about', parentItem: 'rawson', label:'About', href: 'http://dev.tag.is/rawson.js'},
{id:'rawson-github', parentItem: 'rawson', label:'Github Repository', href:'https://github.com/fbuchinger/rawson.js/'},
]
}),
new Rawson.Control.FileProgress(),
new Rawson.Control.FileOpener({fileInputContainer: '#fileinput-container'}),
new Rawson.Control.FileDragNDrop(),
new Rawson.Control.Zoom(),
new Rawson.Control.ImageSaver({ formats: ['JPEG','PNG']}),
new Rawson.Control.ThumbnailList({container: '#thumbnail-list'}),
new Rawson.Control.MetadataTable({container: '#metadata-pane'})
]
});
});
</script>
</head>
<body>
<div class="navbar navbar-fixed-top">
<div class="navbar-inner">
<div class="container-fluid">
<a class="brand" href="#">rawson.js <span class="subheadline">a camera raw previewer in javascript</span></a>
<div id="menu-container">
</div>
<!--<div class="nav-collapse">
<p class="navbar-text pull-right"></p>
</div>-->
</div>
</div>
</div>
<div class="container-fluid">
<div class="row-fluid">
<div class="span3">
<!-- PROJECT INFO-->
<div class="well" style="margin-top:60px;">
rawson.js is a <a href="http://en.wikipedia.org/wiki/Raw_image_format" target="_new">camera raw</a> previewer in javascript. It displays the embedded JPEG preview
and metadata of a raw file, but not (yet) the captured sensor data. <br /><br />
<span class="label label-warning">Firefox/Chrome only - won't run in IE</span>
<span class="label label-warning">Experimental - may crash your browser</span>
</div>
<div class="tabbable">
<ul class="nav nav-tabs">
<li class="active"><a href="#thumbnail-pane" data-toggle="tab">Files</a></li>
<li><a href="#metadata-pane" data-toggle="tab">Metadata</a></li>
<li><a href="#rawprocessing-pane" data-toggle="tab">Raw Processing</a></li>
</ul>
<div class="tab-content">
<!-- Thumbnail Pane-->
<div class="tab-pane active" id="thumbnail-pane">
<div id="fileinput-container"></div>
<div id="thumbnail-list"></div>
</div>
<!-- Metadata Pane -->
<div class="tab-pane" id="metadata-pane">
</div>
<!-- Raw Processor -->
<div class="tab-pane" id="rawprocessing-pane">
<h3>Raw Processing</h3>
not yet...
</div>
</div>
</div>
</div><!--/span-->
<div class="span9">
<div class="hero-unit well" id="preview-container">
<img id="preview">
</div>
</div>
</div><!--/span-->
</div><!--/row-->
</div><!--/.fluid-container-->
<div class="footer"><small>© 2012 by <a href="http://fbuchinger.github.com/">Franz Buchinger</a> rawson.js uses on <a href="http://www.cybercom.net/~dcoffin/dcraw/">Dave Coffin's great dcraw library</a>,
ported with <a href="https://github.com/kripken/emscripten/wiki">emscripten</a>. (Many thanks to <a href="https://github.com/kripken">Alon Zakai</a> for his invaluable help)</small></div>
</body>
</html>