-
Notifications
You must be signed in to change notification settings - Fork 0
/
index - old.html
584 lines (505 loc) · 22.5 KB
/
index - old.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
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
<!DOCTYPE html>
<html lang="en">
<head>
<title>The Sea By, Brian Spiegel.</title>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, user-scalable=no, minimum-scale=1.0, maximum-scale=1.0">
<link type="text/css" rel="stylesheet" href="/SlideShow_GPU_HDR/yui/build/fonts/fonts-min.css">
<link type="text/css" rel="stylesheet" href="/SlideShow_GPU_HDR/yui/build/slider/assets/skins/sam/slider.css">
<link type="text/css" rel="stylesheet" href="/SlideShow_GPU_HDR/yui/build/button/assets/skins/sam/button.css">
<link type="text/css" rel="stylesheet" href="/SlideShow_GPU_HDR/yui/build/treeview/assets/skins/sam/treeview.css">
<script src="/SlideShow_GPU_HDR/js/helperClass.js" type="text/javascript"></script>
<script type="text/javascript" language="JavaScript" src="/SlideShow_GPU_HDR/js/slideShowClass.js"></script>
<!--script type="text/javascript" language="JavaScript" src="/js/debugClass.js"></script-->
<script src="/SlideShow_GPU_HDR/yui/build/yahoo/yahoo.js" type="text/javascript"></script>
<script src="/SlideShow_GPU_HDR/yui/build/dom/dom.js" type="text/javascript"></script>
<script src="/SlideShow_GPU_HDR/yui/build/event/event.js" type="text/javascript"></script>
<script src="/SlideShow_GPU_HDR/yui/build/container/container.js" type="text/javascript"></script>
<script src="/SlideShow_GPU_HDR/yui/build/menu/menu-min.js" type="text/javascript"></script>
<script src="/SlideShow_GPU_HDR/yui/build/connection/connection-min.js" type="text/javascript"></script>
<script src="/SlideShow_GPU_HDR/yui/build/dragdrop/dragdrop-min.js" type="text/javascript"></script>
<script src="/SlideShow_GPU_HDR/yui/build/slider/slider.js" type="text/javascript"></script>
<script src="/SlideShow_GPU_HDR/yui/build/animation/animation-min.js" type="text/javascript"></script>
<script src="/SlideShow_GPU_HDR/yui/build/datasource/datasource-min.js" type="text/javascript"></script>
<script src="/SlideShow_GPU_HDR/yui/build/autocomplete/autocomplete-min.js" type="text/javascript"></script>
<script src="/SlideShow_GPU_HDR/yui/build/element/element-min.js" type="text/javascript"></script>
<script src="/SlideShow_GPU_HDR/yui/build/button/button-min.js" type="text/javascript"></script>
<script src="/SlideShow_GPU_HDR/yui/build/dragdrop/dragdrop-min.js" type="text/javascript"></script>
<script src="/SlideShow_GPU_HDR/yui/build/treeview/treeview-min.js" type="text/javascript"></script>
<script src="/SlideShow_GPU_HDR/yui/build/resize/resize.js" type="text/javascript"></script>
<style type="text/css"><!--
#pausebtn{
position:absolute;
left:50%;
bottom:0px;
}
#mutebtn{
position:absolute;
left:25%;
bottom:0px;
}
#btncontainer{
position:absolute;
top:0px;
bottom:40px;
width:99%;
}
#dummy,
#dummy2,
#dummy3{
position:absolute;
top:0px;
left:0px;
}
#sig{
width:1060px;
margin-left:auto;
margin-right:auto;
position:absolute;
bottom:10px;
right:25%;
}
#sig p,
#title_sig{
text-align:right;
}
#container{
position:absolute;
}
#innerContainer{
position:relative;
width:1024px;
margin-left:auto;
margin-right:auto;
}
#mutebtn{
width:50px;
height:50px;
}
#text_items{
position:absolute;
width:1024px;
height:768px;
margin-left:auto;
margin-right:auto;
color:#FFF;
top:0px;
}
#text_items div{
display:none;
}
#item_0 h1,
#item_1 h2{
text-align:center;
}
body{
color:#FFF;
background-color:#000;
}
-->
</style>
</head>
<body>
<div id="page">
<div id="container">
<div id="innerContainer">
<div id="text_items">
<div id="item_0"><h1>The Sea </h1>
<span id="title_sig">
<p>By Brian Spiegel.<br/></p>
</span>
</div>
<div id="item_1"><h2>I want to show the coastline from beach, to cliff, to rock, to stone. I want to show the coastline it is made better by time and will of nature. I want to show the beach showing as the light from the sun bounces off of it. I want you to see it in all its vivid color that's why these images are now HDR and you are seeing the most light detail possible perceived. I hope you like these pictures they took time and effort to create and I enjoy viewing them. </h2></div>
</div>
</div>
</div>
<div id="sig">
<p><span id="index"></span> Brian Spiegel.<br/></p>
</div>
<div id="btncontainer">
<audio autoplay="true" id="myAudio" loop="true">
<source src="https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/gh-pages/mp3/ocean_waves.mp3" type="audio/mpeg"/>
Your browser does not support the audio tag.
</audio>
<img src="https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/slide_show_assets/p.png" title="Pause" id="pausebtn"/>
<img src="https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/audio_icons/mute_off.png" title="mute" id="mutebtn"/>
</div>
<div id="dummy"></div>
<div id="dummy2"></div>
<div id="dummy3"></div>
<script type="module">
import * as THREE from '/SlideShow_GPU_HDR/three.js/build/three.module.js';
import { GUI } from '/SlideShow_GPU_HDR/three.js/examples/jsm/libs/dat.gui.module.js';
import { RGBELoader } from '/SlideShow_GPU_HDR/three.js/examples/jsm/loaders/RGBELoader.js';
var params = {
exposure: 2.0
};
var renderer, scene, camera;
var files =['https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_2525And7more.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_2601_2_3_4_6_7_8.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_2755And9more.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_3660And7more.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_4144_5_6_newest.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_4191_2_3.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_4940And9more.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_5471And9more.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_5569And9more.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_6256And9more2.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_6313And9more.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_7030And7more.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_7645And9more.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_8418And7more.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_8633_4_5_6_7_8_9.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_8643And9more.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_9146And9more_more.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_9656And9more.hdr'];
//document.getElementById("myAudio").play();
var setsOfFiles = [{name: "The Sea", list:[
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_2525And7more.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_2601_2_3_4_6_7_8.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_2755And9more.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_3660And7more.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_4144_5_6_newest.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_4191_2_3.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_4940And9more.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_5471And9more.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_5569And9more.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_6256And9more2.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_6313And9more.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_7030And7more.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_7645And9more.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_8418And7more.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_8633_4_5_6_7_8_9.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_8643And9more.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_9146And9more_more.hdr',
'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/the_sea_portfiolo/_MG_9656And9more.hdr']},
{name: "The Forest", list:[
"/the_forest_portfolio/_MG_0886And9more.hdr",
"/the_forest_portfolio/_MG_2343And9more.hdr",
"/the_forest_portfolio/_MG_5545And9more.hdr",
"/the_forest_portfolio/_MG_5560And9more.hdr",
"/the_forest_portfolio/_MG_8041And9more.hdr",
"/the_forest_portfolio/_MG_9778_79_80.hdr",
"/the_forest_portfolio/_MG_9700And9more.hdr",
"/the_forest_portfolio/_MG_8583_4_5.hdr",
"/the_forest_portfolio/_MG_8208_09_10_i.hdr",
"/the_forest_portfolio/_MG_0152And9more.hdr",
"/the_forest_portfolio/_MG_0239_40_41_42_43.hdr",
"/the_forest_portfolio/_MG_3677 Panorama.jpg",
"/the_forest_portfolio/_MG_6033 Panorama.jpg",
"/the_forest_portfolio/_MG_7294And8more.hdr",
"/the_forest_portfolio/IMG_5471_2_3_4.hdr",
"/the_forest_portfolio/IMG_5499_500_501_502.hdr",
"/the_forest_portfolio/IMG_5495_6_7_8.hdr",
"/the_forest_portfolio/_MG_0320_1_2_3_4.hdr",
"/the_forest_portfolio/_MG_0227_8.hdr",
"/the_forest_portfolio/_MG_0194_5.hdr",
"/the_forest_portfolio/_MG_9713_4_5.hdr"
]}];
init();
function init() {
//var b = new debugClass({createNode:1,nodeId:"test"});
var t = 0;
var timerObj = [null];// setInterval(set_aminte_pulse(params, t), 1);
var element = { bit: 1, playBtnImage : 'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/slide_show_assets/play.png',
pauseBtnImage :'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/slide_show_assets/p.png',
muteOffBtnImage :'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/audio_icons/mute_off.png',
muteonBtnImage :'https://raw.githubusercontent.com/flyingdeath/SlideShow_GPU_HDR/master/audio_icons/mute_on.png',
mutebtn : "mutebtn",
pbtnId:'pausebtn',
s : scene,
f : files,
st : 0,
ft: "crossFade",//"none",// "OutIn", //"crossFade",
audioBit: 1,
t : [],
p: params,
debug: null,
tObj: [null]
};
YAHOO.util.Event.addListener(element.pbtnId, 'click', toggleShow, element);
YAHOO.util.Event.addListener(element.mutebtn, 'click', toggleAudio, element);
var textList = ["item_0","item_1"];
var i = 8;
renderer = new THREE.WebGLRenderer();
renderer.setPixelRatio( window.devicePixelRatio );
renderer.setSize( window.innerWidth -30, window.innerHeight -30);
document.getElementById('container').appendChild( renderer.domElement );
YAHOO.util.Dom.generateId(renderer.domElement);
var id = renderer.domElement.id;
renderer.toneMapping = THREE.ReinhardToneMapping;
renderer.toneMappingExposure = params.exposure;
renderer.gammaOutput = true;
scene = new THREE.Scene();
var h = new helperClass();
var aspect = window.innerWidth / window.innerHeight;
camera = new THREE.OrthographicCamera( - aspect, aspect, 1, - 1, 0, 1 );
var texture01 =[];
function changeImageSrc(id,src){
var domObj = document.getElementById(id);
if(domObj){
domObj.src = src;
}
domObj = new helperClass().deleteDomElement(domObj);
}
window.addEventListener( 'resize', onWindowResize, false );
function set_aminte_pulse(p,t){
var param01 = p, ticks = t;
var flag = false;
return function(){
if(param01){
param01.exposure = Math.sin(ticks*0.01 ) +1;
render();
if(flag){
ticks--;
}else{
ticks++;
}
if( ticks == Number.MAX_VALUE){
flag = true;
}
if( ticks == 0){
flag = false;
}
}
}
}
//setInterval(function(){ alert("Hello"); }, 3000);
function slideShow(scene,files,ticks, texture01, params, timerobj, fadeType , debug){
var t0 = ticks, par = params, texture01, timer = timerobj, ft = fadeType, d = debug;
var s = scene, f = files;
return function (){
setnewtexture(s,f[t0], texture01, par,timer, t0, f.length, ft,false, d);
t0++;
if(t0 == f.length){
t0 = 0;
}
}
}
h.hide("sig");
h.show(textList[0])
new slideShowClass({fade:true,
fadeTime:1.5,
initInterval:i,
interval: i*2,
'textList': textList,
onCompleteDelay:i/2,
onComplete: function(){
h.show("sig");
setnewtexture(scene,files[0], element.t, params, element.tObj, element.st, element.f.length,element.ft,"new", element.debug);
element.st++;
h.updateHTML('index',"1/"+files.length + "<br/>The Sea By, <br/> " );
element.slide_showObj = setInterval(
slideShow(element.s,element.f,element.st, element.t, element.p, element.tObj, element.ft, element.debug),10000)
}
});
/* */
function toggleAudio(eventObj, element){
if(element.audioBit){
changeImageSrc(element.mutebtn,element.muteonBtnImage);
element.audioBit = 0 ;
document.getElementById("myAudio").pause();
}else{
element.audioBit = 1 ;
changeImageSrc(element.mutebtn,element.muteOffBtnImage);
document.getElementById("myAudio").play();
}
}
function toggleShow(eventObj, element){
if(element.bit){
changeImageSrc(element.pbtnId,element.playBtnImage);
clearInterval(element.slide_showObj);
element.bit = 0 ;
}else{
element.bit = 1 ;
slideShow(element.s,element.f,element.st, element.t, element.p, element.tObj, element.ft, element.debug)();
element.st++;
changeImageSrc(element.pbtnId,element.pauseBtnImage);
clearInterval(element.slide_showObj);
element.slide_showObj = setInterval(
slideShow(element.s,element.f,element.st, element.t, element.p, element.tObj, element.ft, element.debug),10000)
}
}
//var gui = new GUI();
//gui.add( params, 'exposure', 0, 4, 0.01 ).onChange( render );
//gui.open();
function setnewtexture(scene, filepath, oldmesh, param0, time, index, len, fadeType, isNew,debug){
if(oldmesh[0]){
if (fadeType == "OutIn"){
h.fadeAnimation({run: true,
seconds: 3,
obj:"dummy3",
method: YAHOO.util.Easing.easeOutStrong,
start:1.0,
finish: 0.0,
onTween:function(obj1,obj2,obj3){
param0.exposure = parseFloat(YAHOO.util.Dom.getStyle("dummy3","opacity"))*1.2;
render();
},
onComplete:function(){
param0.exposure = 0;
render();
scene.remove( oldmesh[0] );
render();
setMesh(filepath,id,params, t, time, oldmesh, index, len, fadeType, isNew,debug);
},
onStart: function(){
YAHOO.util.Dom.setStyle("dummy3","opacity",1.0)
//h.show(renderer.domElement);
}});
}else{
setMesh(filepath,id,params, t, time, oldmesh, index, len, fadeType, isNew,debug);
}
}else{
setMesh(filepath,id,param0, t, time, oldmesh, index, len, fadeType, isNew,debug);
}
}
function setMesh(filepath,id0,params, t, timerObj, texture_mesh, index, len,fadeType, isNew,debug){
new RGBELoader()
.setDataType( THREE.UnsignedByteType ) // alt: FloatType, HalfFloatType
.load( filepath, function ( texture, textureData ) {
try{
//console.log( textureData );
//console.log( texture );
var material = new THREE.MeshBasicMaterial( { map: texture } );
var quad = new THREE.PlaneBufferGeometry( 1.5 * textureData.width / textureData.height, 1.5 );
var mesh = new THREE.Mesh( quad, material );
scene.add(mesh);
if(!isNew && fadeType !== "OutIn"){
mesh.material.opacity = 1.0;
mesh.material.transparent = false;
params.exposure = 1.2;
}
if(texture_mesh[0] && fadeType !== "OutIn"){
texture_mesh[0].material.transparent = true;
texture_mesh[0].material.opacity = 1.0;
}
if( "OutIn" == fadeType){
if(texture_mesh[0]){
delete texture_mesh[0];
texture_mesh[0] = mesh;
}
params.exposure = 0;
h.fadeAnimation({run: true, seconds:3,
obj:"dummy3",
start:0.0,
finish: 1.0,
method: YAHOO.util.Easing.easeInStrong,
onTween:function(obj1,obj2,obj3){
params.exposure = parseFloat(YAHOO.util.Dom.getStyle("dummy3","opacity"))*1.2;
render();
},
onComplete:function(){
texture_mesh[0] = mesh;
},
onStart: function(){
if( Number.isInteger(index)){
h.updateHTML('index', parseInt(index+1) +"/"+len + "<br/>The Sea By, <br/> " );
}
YAHOO.util.Dom.setStyle("dummy3","opacity",0.0);
}});
}else if("crossFade" == fadeType){
mesh.material.opacity = 0.0;
mesh.material.transparent = true;
// method: YAHOO.util.Easing.easeOutStrong,
if(texture_mesh[0]){
h.fadeAnimation({run: true, seconds:3,
obj:"dummy2",
start:1.0,
finish: 0.0,
onComplete:function(){
timerObj[1] = "done";
},
onTween:function(obj1,obj2,obj3){
if(timerObj[1] !== "done"){
//debug.output(parseFloat(YAHOO.util.Dom.getStyle("dummy2","opacity")))
//render();
}
},
onStart: function(){
timerObj[1] = "";
texture_mesh[0].opacity = 1.0;
texture_mesh[0].transparent = true;
params.exposure = 1.2;
texture_mesh[0].material.opacity = 1.0;
if( Number.isInteger(index)){
h.updateHTML('index', parseInt(index+1) +"/"+len + "<br/>The Sea By, <br/> " );
}
YAHOO.util.Dom.setStyle("dummy2","opacity",1.0);
}});
}
//method: YAHOO.util.Easing.easeInStrong,
h.fadeAnimation({run: true, seconds:3,
obj:"dummy",
start:0.0,
finish: 1.0,
onTween:function(obj1,obj2,obj3){
//params.exposure = parseFloat(YAHOO.util.Dom.getStyle("dummy","opacity")*1.2);
if(timerObj[1] !== "done"){
if(texture_mesh[0]){
texture_mesh[0].material.opacity = parseFloat(YAHOO.util.Dom.getStyle("dummy2","opacity"));
}
mesh.material.opacity = parseFloat(YAHOO.util.Dom.getStyle("dummy","opacity"));
render();
}
},
onComplete:function(){
if(texture_mesh[0]){
scene.remove( texture_mesh[0] );
}
//params.exposure = 1.2;
mesh.material.opacity = 1.0;
timerObj[1] = "done";
render();
delete texture_mesh[0];
texture_mesh[0] = mesh;
},
onStart: function(){
//params.exposure = 0.0;
params.exposure = 1.2;
mesh.material.opacity = 0.0;
if( Number.isInteger(index)){
h.updateHTML('index', parseInt(index+1) +"/"+len + "<br/>The Sea By, <br/> " );
}
YAHOO.util.Dom.setStyle("dummy","opacity",0.0);
render();
}});
}else{
mesh.material.opacity = 1.0;
mesh.material.transparent = false;
params.exposure = 1.2;
if(texture_mesh[0]){
params.exposure = 1.2;
scene.remove( texture_mesh[0] );
delete texture_mesh[0];
}
h.updateHTML('index', parseInt(index + 1) +"/"+len + "<br/>The Sea By, <br/> " );
render();
texture_mesh[0] = mesh;
}
}catch(error){
debugger;
}{
// clearInterval(timerObj[0]);
// timerObj[0] =null;
// timerObj[0] = setInterval(set_aminte_pulse(params, t), 1);
}} );
}
}
function onWindowResize() {
var aspect = window.innerWidth / window.innerHeight;
var frustumHeight = camera.top - camera.bottom;
camera.left = - frustumHeight * aspect / 2;
camera.right = frustumHeight * aspect / 2;
camera.updateProjectionMatrix();
renderer.setSize( window.innerWidth -30, window.innerHeight-30 );
render();
}
//
function render() {
renderer.toneMappingExposure = params.exposure;
renderer.render( scene, camera );
}
</script>
</body>
</html>