//////////////////////////////////////////////////////////////////////
// Pano2VR 6.1.2/17873 HTML5/CSS3 & WebGL Panorama Player           //
// License: BKYM.COM                                                //
// (c) 2019, Garden Gnome Software, http://ggnome.com               //
//////////////////////////////////////////////////////////////////////

var jh="function"==typeof Object.defineProperties?Object.defineProperty:function(r,n,m){r!=Array.prototype&&r!=Object.prototype&&(r[n]=m.value)},lh="undefined"!=typeof window&&window===this?this:"undefined"!=typeof global&&null!=global?global:this;function mh(r,n){if(n){var m=lh;r=r.split(".");for(var d=0;d<r.length-1;d++){var c=r[d];c in m||(m[c]={});m=m[c]}r=r[r.length-1];d=m[r];n=n(d);n!=d&&null!=n&&jh(m,r,{configurable:!0,writable:!0,value:n})}}var sh;
if("function"==typeof Object.setPrototypeOf)sh=Object.setPrototypeOf;else{var th;a:{var uh={a:!0},vh={};try{vh.__proto__=uh;th=vh.a;break a}catch(r){}th=!1}sh=th?function(r,n){r.__proto__=n;if(r.__proto__!==n)throw new TypeError(r+" is not extensible");return r}:null}var wh=sh;mh("Object.setPrototypeOf",function(r){return r||wh});
mh("Array.prototype.fill",function(r){return r?r:function(n,m,d){var c=this.length||0;0>m&&(m=Math.max(0,c+m));if(null==d||d>c)d=c;d=Number(d);0>d&&(d=Math.max(0,c+d));for(m=Number(m||0);m<d;m++)this[m]=n;return this}});function xh(r){var n=0;return function(){return n<r.length?{done:!1,value:r[n++]}:{done:!0}}}function yh(){yh=function(){};lh.Symbol||(lh.Symbol=zh)}function Ah(r,n){this.io=r;jh(this,"description",{configurable:!0,writable:!0,value:n})}Ah.prototype.toString=function(){return this.io};
var zh=function(){function r(m){if(this instanceof r)throw new TypeError("Symbol is not a constructor");return new Ah("jscomp_symbol_"+(m||"")+"_"+n++,m)}var n=0;return r}();function Bh(){yh();var r=lh.Symbol.iterator;r||(r=lh.Symbol.iterator=lh.Symbol("Symbol.iterator"));"function"!=typeof Array.prototype[r]&&jh(Array.prototype,r,{configurable:!0,writable:!0,value:function(){return Ch(xh(this))}});Bh=function(){}}
function Ch(r){Bh();r={next:r};r[lh.Symbol.iterator]=function(){return this};return r}function Dh(r,n){Bh();r instanceof String&&(r+="");var m=0,d={next:function(){if(m<r.length){var c=m++;return{value:n(c,r[c]),done:!1}}d.next=function(){return{done:!0,value:void 0}};return d.next()}};d[Symbol.iterator]=function(){return d};return d}mh("Array.prototype.keys",function(r){return r?r:function(){return Dh(this,function(n){return n})}});
mh("Object.is",function(r){return r?r:function(n,m){return n===m?0!==n||1/n===1/m:n!==n&&m!==m}});mh("Array.prototype.includes",function(r){return r?r:function(n,m){var d=this;d instanceof String&&(d=String(d));var c=d.length;m=m||0;for(0>m&&(m=Math.max(m+c,0));m<c;m++){var a=d[m];if(a===n||Object.is(a,n))return!0}return!1}});
mh("String.prototype.includes",function(r){return r?r:function(n,m){if(null==this)throw new TypeError("The 'this' value for String.prototype.includes must not be null or undefined");if(n instanceof RegExp)throw new TypeError("First argument to String.prototype.includes must not be a regular expression");return-1!==(this+"").indexOf(n,m||0)}});
var __extends=this&&this.__extends||function(){function r(n,m){r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,c){d.__proto__=c}||function(d,c){for(var a in c)c.hasOwnProperty(a)&&(d[a]=c[a])};return r(n,m)}return function(n,m){function d(){this.constructor=n}r(n,m);n.prototype=null===m?Object.create(m):(d.prototype=m.prototype,new d)}}();
function Eh(){var r="perspective",n=["Webkit","Moz","O","ms","Ms"],m;for(m=0;m<n.length;m++)"undefined"!==typeof document.documentElement.style[n[m]+"Perspective"]&&(r=n[m]+"Perspective");"undefined"!==typeof document.documentElement.style[r]?"webkitPerspective"in document.documentElement.style?(r=document.createElement("style"),n=document.createElement("div"),m=document.head||document.getElementsByTagName("head")[0],r.textContent="@media (-webkit-transform-3d) {#ggswhtml5{height:5px}}",m.appendChild(r),
n.id="ggswhtml5",document.documentElement.appendChild(n),m=5===n.offsetHeight,r.parentNode.removeChild(r),n.parentNode.removeChild(n)):m=!0:m=!1;return m}function Fh(){var r;if(r=!!window.WebGLRenderingContext)try{var n=document.createElement("canvas");n.width=100;n.height=100;var m=n.getContext("webgl");m||(m=n.getContext("experimental-webgl"));r=!!m}catch(d){r=!1}return r}var ggP2VR;
(function(r){var n=function(){function d(c){this.u=null;this.Ig=this.om=this.pb=!1;this.qb=!0;this.lb=this.La=this.Ga=0;this.fov=70;this.hb=0;this.autoplay=this.Ng=!1;this.id="";this.A=this.pan=0;this.u=c;this.$c=this.xc=100;this.Gc=1}d.prototype.Yb=function(c){var a;if(a=c.getAttributeNode("id"))this.id=a.nodeValue.toString();if(a=c.getAttributeNode("pan"))this.pan=Number(a.nodeValue);if(a=c.getAttributeNode("tilt"))this.A=Number(a.nodeValue)};d.prototype.Un=function(c){var a="",b=this.u,e=!0;if(b.si){var f=
new r.Ha(0,0,-100);f.Ga(-this.A*Math.PI/180);f.La(this.pan*Math.PI/180);f.La(-b.pan.m*Math.PI/180);f.Ga(b.A.m*Math.PI/180);f.lb(b.V.m*Math.PI/180);.01<=f.z&&(e=!1)}b.Mc&&(a+="perspective("+c+"px) ");a=a+("translate3d(0px,0px,"+c+"px) ")+("rotateZ("+b.V.m.toFixed(10)+"deg) ");a+="rotateX("+b.A.m.toFixed(10)+"deg) ";a+="rotateY("+(-b.pan.m).toFixed(10)+"deg) ";a+="rotateY("+this.pan.toFixed(10)+"deg) ";a+="rotateX("+(-this.A).toFixed(10)+"deg) ";c=1E4;f=this.j.videoWidth;var g=this.j.videoHeight;if(0==
f||0==g)f=640,g=480;0<this.xc&&(f=this.xc);0<this.$c&&(g=this.$c);0<f&&0<g&&(this.j.width=f,this.j.height=g,this.j.style.width=f+"px",this.j.style.height=g+"px");0<this.fov&&(c=f/(2*Math.tan(this.fov/2*Math.PI/180)));a+="translate3d(0px,0px,"+(-c).toFixed(10)+"px) ";a+="rotateZ("+this.lb.toFixed(10)+"deg) ";a+="rotateY("+(-this.La).toFixed(10)+"deg) ";a+="rotateX("+this.Ga.toFixed(10)+"deg) ";this.Gc&&1!=this.Gc&&(a+="scaleY("+this.Gc+") ");a+="translate3d("+-f/2+"px,"+-g/2+"px,0px) ";this.j.style[b.Va+
"Origin"]="0% 0%";this.pb&&(a="",1==this.hb&&(a+="scale("+Math.min(b.D.width/f,b.D.height/g)+") "),a+="translate3d("+-f/2+"px,"+-g/2+"px,0px) ");this.aq!=a&&(this.aq=a,this.j.style[b.Va]=a,this.j.style.visibility=e&&this.qb?"visible":"hidden",this.Ig&&this.om==this.pb&&(this.j.style[b.Xc]="all 0s linear 0s"),this.om=this.pb)};d.prototype.Wf=function(c){this.j&&(this.j.style.visibility=c?"visible":"hidden")};d.prototype.df=function(){var c=this.u;c.ia?(this.j.style.left=c.D.width/2+"px",this.j.style.top=
c.D.height/2+"px"):(this.j.style.left=c.margin.left+c.D.width/2+"px",this.j.style.top=c.margin.top+c.D.height/2+"px")};return d}();r.ws=n;var m=function(d){function c(a){a=d.call(this,a)||this;a.va=!1;a.Gn=!1;a.Rm=!1;a.$f=!1;a.Pj=!1;a.wk=!1;a.se=!1;a.fc=null;a.Th=null;a.wh=0;a.Re=0;a.Nf=!1;a.Vq=!1;a.stopped=!1;a.url=[];a.loop=0;a.level=1;a.tc=0;a.mode=1;a.bi=10;a.Bb=0;a.Zf=0;a.ua=1;a.Qc=0;a.Rc=0;a.Sc=0;a.Tc=0;a.Ii=-1;return a}__extends(c,d);c.prototype.Sk=function(){var a=this,b=a.j.play();if(void 0!==
b)b.then(function(){a.Ph()})["catch"](function(){a.j.pause();a.Gn&&(a.j.muted=!0,a.j.play())})};c.prototype.Cn=function(){this.va&&this.stopped?this.stopped=!1:0==this.loop?this.va?(this.fc=null,this.Wd()):this.j.play():0<this.wb?(this.wb--,this.va||(this.j.currentTime=0),this.Pj&&(this.ic&&0==this.ic.gain.value||0==this.Hb.gain.value&&0==this.Sb.gain.value&&0==this.Qb.gain.value&&0==this.Rb.gain.value)||(this.va?(this.fc=null,this.Wd()):this.j.play())):this.va&&(this.fc=null,this.Nf=!1)};c.prototype.Ph=
function(){this.se=!1;var a=this.u.wa;a&&(this.va||(this.source=a.createMediaElementSource(this.j)),2==this.mode||3==this.mode||5==this.mode?(this.Ad=a.createChannelSplitter(2),this.Hb=a.createGain(),this.Qb=a.createGain(),this.Rb=a.createGain(),this.Sb=a.createGain(),this.og=a.createChannelMerger(2),this.va||this.source.connect(this.Ad),this.Ad.connect(this.Hb,0),this.Ad.connect(this.Qb,0),this.Ad.connect(this.Rb,1),this.Ad.connect(this.Sb,1),this.Hb.connect(this.og,0,0),this.Qb.connect(this.og,
0,1),this.Rb.connect(this.og,0,0),this.Sb.connect(this.og,0,1),this.og.connect(a.destination),1==this.Ii&&this.In()):(this.ic=a.createGain(),this.va||this.source.connect(this.ic),this.ic.connect(a.destination)))};c.prototype.In=function(){1!=this.Ii||this.se||!this.Ad||2!=this.mode&&3!=this.mode&&5!=this.mode||(this.Ad.connect(this.Rb,0),this.Ad.connect(this.Sb,0))};c.prototype.th=function(){var a=this.u.wa;this.pb||this.wk||(this.Hb?(this.Hb.gain.setValueAtTime(this.Qc,a.currentTime),this.Sb.gain.setValueAtTime(this.Tc,
a.currentTime),this.Qb.gain.setValueAtTime(this.Rc,a.currentTime),this.Rb.gain.setValueAtTime(this.Sc,a.currentTime)):this.ic&&this.ic.gain.setValueAtTime((this.Qc+this.Tc)/2,a.currentTime+1))};c.prototype.kj=function(){if(!this.se||4==this.mode||6==this.mode){var a=this.u,b=this.u.wa;if(this.j||this.va){var e,f=this.pan-a.pan.m;for(e=this.A-a.A.m;-180>f;)f+=360;for(;180<f;)f-=360;var g=this.tc,h=this.bi;0==h&&(h=.01);0>h&&(h=a.fov.m);this.ac||(this.ac=new r.Ha,this.ac.Nl(this.pan,this.A));0!=this.mode&&
1!=this.mode||!b||this.ic&&this.ic.gain.setValueAtTime(this.level*a.ca*this.ua,b.currentTime);if(2==this.mode&&b){var l=.5*Math.cos(f*Math.PI/180)+.5;this.Qc=Math.sqrt(l)*this.ua*this.level*a.ca;this.Tc=Math.sqrt(l)*this.ua*this.level*a.ca;this.Rc=Math.sqrt(1-l)*this.ua*this.level*a.ca;this.Sc=Math.sqrt(1-l)*this.ua*this.level*a.ca;this.th()}if(3==this.mode){f=0>f?f<-this.Bb?f+this.Bb:0:f>this.Bb?f-this.Bb:0;var k=this.level;e=Math.abs(e);e=e<this.Zf?0:e-this.Zf;var q=1-e/h;if(Math.abs(f)>h||0>q)l=
k*g*a.ca,b?(this.Qc=l*this.ua,this.Tc=l*this.ua,this.Sc=this.Rc=0,this.th()):this.j.volume=k*g*a.ca;else if(l=1-Math.abs(f/h),b){var p=k*(g+(1-g)*q*l)*a.ca;l=k*g*a.ca;0<=f?(this.Qc=p*this.ua,this.Tc=l*this.ua):(this.Qc=l*this.ua,this.Tc=p*this.ua);2*Math.abs(f)<h?(l=1-Math.abs(2*f)/h,p=k*(g+(1-g)*q*l)*a.ca,l=.5*k*(1-g)*q*(1-l)*a.ca,0<=f?(this.Tc=p*this.ua,this.Sc=l*this.ua,this.Rc=0):(this.Qc=p*this.ua,this.Rc=l*this.ua,this.Sc=0)):(l=1-(Math.abs(2*f)-h)/h,p=.5*k*(1-g)*q*l*a.ca,0<=f?(this.Sc=p*this.ua,
this.Rc=0):(this.Rc=p*this.ua,this.Sc=0));this.th()}else this.j.volume=k*(g+(1-g)*q*l)*a.ca}4==this.mode&&(Math.abs(f)<this.Bb&&Math.abs(e)<this.Zf?this.$f||(this.$f=!0,this.wb=this.loop-1,a.uf||(this.j.play(),this.se&&this.Ph())):this.$f=!1);5==this.mode&&(e=180*Math.acos(a.Hj.Mi(this.ac))/Math.PI,e<this.Bb?b?(this.Qc=this.level*a.ca*this.ua,this.Tc=this.level*a.ca*this.ua,this.Sc=this.Rc=0,this.th()):this.j.volume=this.level*a.ca:b?(e<this.Bb+h?(f=0>f?f>-this.Bb?0:f+this.Bb:f<this.Bb?0:f-this.Bb,
p=1-Math.max(e-this.Bb,0)/h,l=Math.max(1-Math.abs(f)*Math.cos(this.A*Math.PI/180)/h,0),0<f?(this.Qc=this.level*(p*(1-this.tc)+this.tc)*a.ca*this.ua,this.Tc=this.level*(p*l*(1-this.tc)+this.tc)*a.ca*this.ua,this.Rc=0,this.Sc=this.level*p*(1-l)*a.ca*this.ua):(this.Qc=this.level*(p*l*(1-this.tc)+this.tc)*a.ca*this.ua,this.Tc=this.level*(p*(1-this.tc)+this.tc)*a.ca*this.ua,this.Rc=this.level*p*(1-l)*a.ca*this.ua,this.Sc=0)):(p=this.level*this.tc*a.ca,this.Qc=p*this.ua,this.Tc=p*this.ua,this.Sc=this.Rc=
0),this.th()):(e-=this.Bb,e<h&&0<h?(l=1-Math.abs(e/h),this.j.volume=this.level*(g+(1-g)*l)*a.ca):this.j.volume=g*a.ca));6==this.mode&&(e=180*Math.acos(a.Hj.Mi(this.ac))/Math.PI,Math.abs(e)<this.Bb?this.$f||(this.$f=!0,this.wb=this.loop-1,this.va?this.Nf||this.Wd():this.j.play()):this.$f=!1)}}};c.prototype.Uo=function(){var a=this;a.fc=this.u.wa.createBufferSource();a.fc.addEventListener("ended",function(){a.Cn()},!1);2==a.mode||3==a.mode||5==a.mode?a.fc.connect(a.Ad):a.fc.connect(a.ic)};c.prototype.Wd=
function(){var a=this.u.wa,b=this.Re;this.Th?(null==this.fc&&(this.Uo(),this.fc.buffer=this.Th),this.wh=a.currentTime-b,this.Re=0,this.Nf=!0,this.stopped=!1,this.fc.start(0,b),this.u.O("buffer Source started")):(this.u.O("bufferSoundPlay() -> no audio buffer -> playWhenReady"),this.Vq=!0)};c.prototype.uj=function(){var a=this.u.wa.currentTime-this.wh;this.mf();this.Re=a};c.prototype.mf=function(){this.fc&&this.Nf&&(this.stopped=!0,this.fc.disconnect(),this.fc.stop(0),this.fc=null);this.wh=this.Re=
0;this.Nf=!1};c.prototype.Ho=function(){var a=this.u.wa;return this.Re?this.Re:this.wh?a.currentTime-this.wh:0};c.prototype.Io=function(a){this.mf();this.Re=a;this.Wd()};c.prototype.addElement=function(){var a=-1,b=this,e=this.u,f=this.u.wa;try{for(var g=!1,h=0;h<e.Y.length;h++)e.Y[h].id==b.id&&(a=h,null==e.Y[h].j&&!e.Y[h].va||e.Y[h].url.join()!=b.url.join()||e.Y[h].loop!=b.loop||e.Y[h].mode!=b.mode||(g=!0,e.Y[h].pan=b.pan,e.Y[h].A=b.A,e.Y[h].level=b.level,e.Y[h].tc=b.tc,e.Y[h].bi=b.bi,e.Y[h].Bb=
b.Bb,e.Y[h].Zf=b.Zf));if(g)e.O("Keep playing "+b.id);else{if(0<=a){var l=e.Y[a];if(null!=l.j||l.va)if(f&&e.Ya.enabled)e.Ya.Ch.push(l),1!=e.K.sa&&2!=e.K.sa&&6!=e.K.sa&&e.Ya.Il(l);else{try{l.va?l.uj():l.j.pause()}catch(q){e.O(q)}try{l.Te()}catch(q){e.O(q)}}}f&&(this.se=!0);b.j=document.createElement("audio");b.j.crossOrigin=e.crossOrigin;b.j.setAttribute("class","ggmedia");e.Cf&&b.j.setAttribute("id",e.Cf+b.id);for(h=0;h<b.url.length;h++)g=void 0,g=document.createElement("source"),""!=b.url[h]&&"#"!=
b.url[h]&&(g.crossOrigin=e.crossOrigin,g.setAttribute("src",e.Pb(b.url[h])),b.j.appendChild(g));b.j.volume=b.level*e.ca;if(0<b.j.childNodes.length&&(e.aa.appendChild(b.j),b.j.addEventListener("ended",function(){b.Cn()},!1),f)){b.Pj=!1;0==b.loop&&b.source&&b.source.mediaElement&&(b.source.mediaElement.loop=!0);var k=new XMLHttpRequest;k.open("GET",e.Pb(b.url[0]),!0);k.responseType="arraybuffer";k.onload=function(){f.decodeAudioData(k.response,function(q){b.Ii=q.numberOfChannels;1==b.Ii&&b.In()})};
k.send()}1<=b.loop&&(b.wb=b.loop-1);0<=a?e.Y[a]=b:e.Y.push(b);b.kj();-1!=this.u.gd.indexOf(b.id)||-1!=this.u.gd.indexOf("_main")&&-1==this.u.re.indexOf(b.id)||(1!=b.mode&&2!=b.mode&&3!=b.mode&&5!=b.mode||!(0<=b.loop)||f&&e.Ya.enabled||(b.va||(b.j.autoplay=!0,b.Sk()),b.autoplay=!0),0==b.mode&&0<=b.loop&&(b.autoplay=!0,b.Sk()))}}catch(q){this.u.O(q)}};c.prototype.Te=function(){try{this.u.O("Remove Snd:"+this.id),this.va||(this.u.aa.removeChild(this.j),this.j=null)}catch(a){this.u.O(a)}};c.prototype.Yb=
function(a){d.prototype.Yb.call(this,a);var b;(b=a.getAttributeNode("url"))&&this.url.push(b.nodeValue.toString());if(b=a.getAttributeNode("level"))this.level=Number(b.nodeValue);if(b=a.getAttributeNode("loop"))this.loop=Number(b.nodeValue);if(b=a.getAttributeNode("mode"))this.mode=Number(b.nodeValue);if(b=a.getAttributeNode("nodechangekeep"))this.Rm=1==Number(b.nodeValue);if(b=a.getAttributeNode("field"))this.bi=Number(b.nodeValue);if(b=a.getAttributeNode("ambientlevel"))this.tc=Number(b.nodeValue);
if(b=a.getAttributeNode("pansize"))this.Bb=Number(b.nodeValue);if(b=a.getAttributeNode("tiltsize"))this.Zf=Number(b.nodeValue);for(a=a.firstChild;a;)"source"==a.nodeName&&(b=a.getAttributeNode("url"))&&this.url.push(b.nodeValue.toString()),a=a.nextSibling};return c}(n);r.ro=m;m=function(d){function c(a){a=d.call(this,a)||this;a.poster="";a.Ga=0;a.La=0;a.lb=0;a.fov=50;a.hb=0;a.Ng=!1;a.cd=!1;return a}__extends(c,d);c.prototype.Ie=function(){1!=this.hb&&4!=this.hb||this.Kg(!this.pb);2==this.hb&&this.u.$m(this.id)};
c.prototype.Kg=function(a){var b=this.u,e=b.wa;if(1==this.hb||4==this.hb)if(this.pb=a,this.u.Nb)(b=b.ra)&&b.activateSound(this.id,this.pb?1:0);else{if(this.pb)this.j.style.pointerEvents="auto",this.j.style.cursor="pointer",this.j.style.zIndex=(b.Lh+8E4).toString(),this.j.style[this.u.Xc]="all 1s ease 0s",this.u.isPlaying(this.id)||b.fe(this.id);else{this.j.style.pointerEvents="none";this.j.style.cursor="default";this.j.style.zIndex=b.Lh.toString();this.j.style[this.u.Xc]="all 1s ease 0s";this.u.isPlaying(this.id)&&
b.$i(this.id);this.wk=!0;var f=this;setTimeout(function(){f.wk=!1},1E3)}if(e&&(2==this.mode||3==this.mode||5==this.mode)&&(e=e.currentTime,this.Hb&&this.Sb&&this.Qb.gain&&this.Qb&&this.Rb)){var g=this.Hb.gain.value,h=this.Sb.gain.value,l=this.Qb.gain.value,k=this.Rb.gain.value;this.pb?(this.Hb.gain.linearRampToValueAtTime(g,e),this.Hb.gain.linearRampToValueAtTime(this.level*b.ca,e+1),this.Sb.gain.linearRampToValueAtTime(h,e),this.Sb.gain.linearRampToValueAtTime(this.level*b.ca,e+1),this.Qb.gain.linearRampToValueAtTime(l,
e),this.Qb.gain.linearRampToValueAtTime(0,e+1),this.Rb.gain.linearRampToValueAtTime(k,e),this.Rb.gain.linearRampToValueAtTime(0,e+1)):(this.Hb.gain.linearRampToValueAtTime(g,e),this.Hb.gain.linearRampToValueAtTime(this.Qc,e+1),this.Sb.gain.linearRampToValueAtTime(h,e),this.Sb.gain.linearRampToValueAtTime(this.Tc,e+1),this.Qb.gain.linearRampToValueAtTime(l,e),this.Qb.gain.linearRampToValueAtTime(this.Rc,e+1),this.Rb.gain.linearRampToValueAtTime(k,e),this.Rb.gain.linearRampToValueAtTime(this.Sc,e+1))}this.Ig=
!0;this.u.Vn()}2==this.hb&&(a?this.u.fe(this.id):this.u.vk(this.id))};c.prototype.Lg=function(){this.Ig=!1;this.j.style[this.u.Xc]="none"};c.prototype.ms=function(){0==this.loop?this.j.play():0<this.wb?(this.wb--,this.j.currentTime=0,this.j.play()):this.isRunning=!1};c.prototype.Yb=function(a){d.prototype.Yb.call(this,a);var b;if(b=a.getAttributeNode("poster"))this.poster=String(b.nodeValue);if(b=a.getAttributeNode("rotx"))this.Ga=Number(b.nodeValue);if(b=a.getAttributeNode("roty"))this.La=Number(b.nodeValue);
if(b=a.getAttributeNode("rotz"))this.lb=Number(b.nodeValue);if(b=a.getAttributeNode("fov"))this.fov=Number(b.nodeValue);if(b=a.getAttributeNode("width"))this.xc=Number(b.nodeValue);if(b=a.getAttributeNode("height"))this.$c=Number(b.nodeValue);this.Gc=(b=a.getAttributeNode("stretch"))?Number(b.nodeValue):1;if(b=a.getAttributeNode("clickmode"))this.hb=Number(b.nodeValue);if(b=a.getAttributeNode("handcursor"))this.Ng=1==Number(b.nodeValue);if(b=a.getAttributeNode("startmutedmobile"))this.Gn=1==Number(b.nodeValue)};
c.prototype.addElement=function(){var a=this,b=this.u,e=this.u.wa;try{a.j=document.createElement("video");a.j.setAttribute("class","ggmedia");a.j.crossOrigin=b.crossOrigin;a.j.hidden=!0;a.j.addEventListener("click",function(h){h.stopPropagation()});b.Cf&&a.j.setAttribute("id",b.Cf+a.id);if(b.Hh)a.j.setAttribute("playsinline","playsinline"),a.j.setAttribute("style","display: none; max-width:none;");else if(a.j.setAttribute("style","max-width:none;pointer-events:none;"),a.j.setAttribute("playsinline",
"playsinline"),1==a.hb||4==a.hb)a.j.addEventListener(b.eo(),function(){a.Lg()},!1),a.j.addEventListener("transitionend",function(){a.Lg()},!1);var f=void 0;for(f=0;f<a.url.length;f++){var g=void 0;g=document.createElement("source");g.crossOrigin=b.crossOrigin;g.setAttribute("src",b.Pb(a.url[f]));a.j.appendChild(g)}""!=a.poster&&(a.j.poster=b.Pb(a.poster),0>a.loop&&(a.j.preload="none"));a.j.volume=a.level*b.ca;1<=a.loop&&(a.wb=a.loop-1);e&&(this.se=!0);(1==a.mode||2==a.mode||3==a.mode||5==a.mode)&&
0<=a.loop&&(a.j.autoplay=!0,a.isRunning=!0,a.autoplay=!0,a.Sk());b.T.push(this);b.Hh?b.aa.appendChild(a.j):(a.j.style.position="absolute",a.xc&&(a.j.width=a.xc),a.$c&&(a.j.height=a.$c),b.L.appendChild(a.j));a.j.addEventListener("ended",function(){a.ms()},!1)}catch(h){b.O(h)}};c.prototype.registerElement=function(a,b){this.cd=!0;this.j=b;this.id=a;this.level=1;this.u.T.push(this)};c.prototype.Te=function(){var a=this.u;a.Hh&&(a.S.deleteTexture(this.texture),this.texture=0,a.aa.removeChild(this.j));
a.Wn&&a.L.removeChild(this.j);this.j=null};return c}(m);r.fl=m;m=function(d){function c(a){a=d.call(this,a)||this;a.url="";a.Ga=0;a.La=0;a.lb=0;a.fov=50;a.hb=0;a.Ng=!1;a.xc=100;a.$c=100;a.Gc=1;return a}__extends(c,d);c.prototype.Yb=function(a){d.prototype.Yb.call(this,a);var b;if(b=a.getAttributeNode("url"))this.url=b.nodeValue.toString();if(b=a.getAttributeNode("rotx"))this.Ga=Number(b.nodeValue);if(b=a.getAttributeNode("roty"))this.La=Number(b.nodeValue);if(b=a.getAttributeNode("rotz"))this.lb=
Number(b.nodeValue);if(b=a.getAttributeNode("fov"))this.fov=Number(b.nodeValue);if(b=a.getAttributeNode("width"))this.xc=Number(b.nodeValue);if(b=a.getAttributeNode("height"))this.$c=Number(b.nodeValue);this.Gc=(b=a.getAttributeNode("stretch"))?Number(b.nodeValue):1;if(b=a.getAttributeNode("clickmode"))this.hb=Number(b.nodeValue);if(b=a.getAttributeNode("handcursor"))this.Ng=1==Number(b.nodeValue);for(a=a.firstChild;a;)"source"==a.nodeName&&(b=a.getAttributeNode("url"))&&(this.url=b.nodeValue.toString()),
a=a.nextSibling};c.prototype.Lg=function(){this.Ig=!1;this.j.style[this.u.Xc]="none"};c.prototype.Ie=function(){1!==this.hb&&4!==this.hb||this.Kg(!this.pb)};c.prototype.Kg=function(a){var b=this.u;if(1===this.hb||4===this.hb)this.pb=a,this.u.Nb?(a=this.u.ra)&&a.activateSound(this.id,this.pb?1:0):(this.pb?(this.j.style.pointerEvents="auto",this.j.style.cursor="pointer",this.j.style.zIndex=(b.Lh+8E4).toString()):(this.j.style.pointerEvents="none",this.j.style.cursor="default",this.j.style.zIndex=b.Lh.toString()),
this.j.style[b.Xc]="all 1s ease 0s",this.Ig=!0,b.Rn())};c.prototype.addElement=function(){var a=this,b=this.u;try{a.j=document.createElement("img");a.j.setAttribute("style","-webkit-user-drag:none; max-width:none; pointer-events:none;");a.j.setAttribute("class","ggmedia");a.j.hidden=!0;a.j.addEventListener("click",function(e){e.stopPropagation()});b.Cf&&a.j.setAttribute("id",b.Cf+a.id);a.j.ondragstart=function(){return!1};if(1===a.hb||4===a.hb)a.j.addEventListener(b.eo(),function(){a.Lg()},!1),a.j.addEventListener("transitionend",
function(){a.Lg()},!1);a.j.setAttribute("src",b.Pb(a.url));a.xc&&(a.j.width=a.xc);a.$c&&(a.j.height=a.$c);b.fb.push(a);a.j.style.position="absolute";b.L.appendChild(a.j)}catch(e){b.O("Error addimage:"+e)}};c.prototype.Te=function(){this.u.L.removeChild(this.j);this.j=null};return c}(n);r.po=m;n=function(d){function c(a){a=d.call(this,a)||this;a.nl=50;a.alpha=50;a.type=0;a.color=16777215;return a}__extends(c,d);c.prototype.Yb=function(a){d.prototype.Yb.call(this,a);var b;if(b=a.getAttributeNode("blinding"))this.nl=
Number(b.nodeValue);if(b=a.getAttributeNode("alpha"))this.alpha=Number(b.nodeValue);if(b=a.getAttributeNode("type"))this.type=Number(b.nodeValue);if(b=a.getAttributeNode("color"))this.color=1*Number(b.nodeValue)};return c}(n);r.qo=n;n=function(){function d(c){this.u=c;this.type="empty";this.Kk=this.id=this.target=this.description=this.title=this.url="";this.w=100;this.h=20;this.nj=!1;this.j=null;this.Cb=this.Xb=this.nb=this.Ba=this.distance=this.A=this.pan=0;this.visible=!0;this.ec=c.I.ec;this.cc=
c.I.cc;this.dc=c.I.dc;this.bc=c.I.bc;this.zf=c.I.zf;this.Wc="";this.Bd=this.Ae=0;this.bg=!1;this.$h=0;this.vertices=[]}d.prototype.tf=function(){this.id=this.id;this.pan=this.pan;this.tilt=this.A;this.url=this.url;this.target=this.target;this.title=this.title;this.distance=this.distance;this.description=this.description;this.skinid=this.Kk;this.obj=this.j;this.customimage=this.Wc;this.customimagewidth=this.Ae;this.customimageheight=this.Bd;this.use3D=this.bg;this.distance3D=this.$h;this.j&&this.j.__div&&
(this.div=this.j.__div)};d.prototype.Qr=function(){var c=this.url;return"{"==c.charAt(0)?c.substr(1,c.length-2):!1};d.prototype.Yb=function(c){var a;if(a=c.getAttributeNode("url"))this.url=a.nodeValue.toString();if(a=c.getAttributeNode("target"))this.target=a.nodeValue.toString();if(a=c.getAttributeNode("title"))this.title=a.nodeValue.toString();if(a=c.getAttributeNode("description"))this.description=a.nodeValue.toString();if(a=c.getAttributeNode("id"))this.id=a.nodeValue.toString();if(a=c.getAttributeNode("skinid"))this.Kk=
a.nodeValue.toString();if(a=c.getAttributeNode("width"))this.w=Number(a.nodeValue);if(a=c.getAttributeNode("height"))this.h=Number(a.nodeValue);if(a=c.getAttributeNode("wordwrap"))this.nj=1==Number(a.nodeValue);a=c.getAttributeNode("pan");this.pan=1*(a?Number(a.nodeValue):0);a=c.getAttributeNode("tilt");this.A=1*(a?Number(a.nodeValue):0);a=c.getAttributeNode("fov");this.fov=1*(a?Number(a.nodeValue):0);a=c.getAttributeNode("distance");this.distance=1*(a?Number(a.nodeValue):0);if(a=c.getAttributeNode("bordercolor"))this.ec=
1*Number(a.nodeValue);if(a=c.getAttributeNode("backgroundcolor"))this.cc=1*Number(a.nodeValue);if(a=c.getAttributeNode("borderalpha"))this.dc=1*Number(a.nodeValue);if(a=c.getAttributeNode("backgroundalpha"))this.bc=1*Number(a.nodeValue);if(a=c.getAttributeNode("handcursor"))this.zf=1==Number(a.nodeValue);if(a=c.getAttributeNode("customimage"))this.Wc=this.u.Xl()+a.nodeValue;if(a=c.getAttributeNode("customimagewidth"))this.Ae=Number(a.nodeValue);if(a=c.getAttributeNode("customimageheight"))this.Bd=
Number(a.nodeValue);if(a=c.getAttributeNode("use3D"))this.bg=1==Number(a.nodeValue);if(a=c.getAttributeNode("distance3D"))this.$h=Number(a.nodeValue);for(c=c.firstChild;c;){if("polystring"==c.nodeName){a=c.textContent.toString().split("|");for(var b=0;b<a.length;b++){var e=a[b].split("/");if(2==e.length){var f={pan:0,A:0};f.pan=Number(e[0]);f.A=Number(e[1]);this.vertices.push(f)}}}"vertex"==c.nodeName&&(f={pan:0,A:0},a=c.getAttributeNode("pan"),f.pan=1*(a?Number(a.nodeValue):0),a=c.getAttributeNode("tilt"),
f.A=1*(a?Number(a.nodeValue):0),this.vertices.push(f));c=c.nextSibling}this.tf()};return d}();r.Oh=n})(ggP2VR||(ggP2VR={}));
(function(r){var n=function(){function m(d,c){this.x=d;this.y=c}m.prototype.init=function(d,c){this.x=d;this.y=c};m.prototype.Gd=function(d,c,a){var b=c.y-d.y;this.x=d.x+(c.x-d.x)*a;this.y=d.y+b*a};m.prototype.Go=function(d,c,a,b,e){var f=new m;f.Gd(d,a,e);d=new m;d.Gd(a,b,e);a=new m;a.Gd(b,c,e);c=new m;c.Gd(f,d,e);f=new m;f.Gd(d,a,e);d=new m;d.Gd(c,f,e);this.x=d.x;this.y=d.y};m.prototype.sj=function(d,c,a,b,e){var f=new m,g=.5,h=.25;do{f.Go(d,c,a,b,g);var l=f.x-e;g=0<l?g-h:g+h;h/=2}while(.01<Math.abs(l));
this.x=f.x;this.y=f.y};return m}();r.Ec=n})(ggP2VR||(ggP2VR={}));
(function(r){var n=function(){function m(d,c,a,b,e){this.x=d;this.y=c;this.z=a;this.yd=b;this.ac=e}m.prototype.init=function(d,c,a,b,e){this.x=d;this.y=c;this.z=a;this.yd=b;this.ac=e};m.prototype.toString=function(){return"("+this.x+","+this.y+","+this.z+") - ("+this.yd+","+this.ac+")"};m.prototype.Ga=function(d){var c=Math.sin(d);d=Math.cos(d);var a=this.y,b=this.z;this.y=d*a-c*b;this.z=c*a+d*b};m.prototype.br=function(){var d=this.y;this.y=-this.z;this.z=d};m.prototype.ar=function(){var d=this.y;
this.y=this.z;this.z=-d};m.prototype.La=function(d){var c=Math.sin(d);d=Math.cos(d);var a=this.x,b=this.z;this.x=d*a+c*b;this.z=-c*a+d*b};m.prototype.cr=function(){var d=this.x;this.x=-this.z;this.z=d};m.prototype.lb=function(d){var c=Math.sin(d);d=Math.cos(d);var a=this.x,b=this.y;this.x=d*a-c*b;this.y=c*a+d*b};m.prototype.nn=function(){var d=this.x;this.x=-this.y;this.y=d};m.prototype.Od=function(d){this.Ga(d*Math.PI/180)};m.prototype.Ue=function(d){this.La(d*Math.PI/180)};m.prototype.Ve=function(d){this.lb(d*
Math.PI/180)};m.prototype.clone=function(){return new m(this.x,this.y,this.z,this.yd,this.ac)};m.prototype.length=function(){return Math.sqrt(this.x*this.x+this.y*this.y+this.z*this.z)};m.prototype.normalize=function(){var d=this.length();0<d&&(d=1/d,this.x*=d,this.y*=d,this.z*=d)};m.prototype.Mi=function(d){return this.x*d.x+this.y*d.y+this.z*d.z};m.prototype.Nl=function(d,c){var a=Math.cos(c*Math.PI/180);this.x=a*Math.sin(d*Math.PI/180);this.y=Math.sin(c*Math.PI/180);this.z=a*Math.cos(d*Math.PI/
180)};m.prototype.Co=function(){return 180*Math.atan2(-this.x,-this.z)/Math.PI};m.prototype.Do=function(){return 180*Math.asin(this.y/this.length())/Math.PI};m.prototype.Gd=function(d,c,a){this.x=d.x*a+c.x*(1-a);this.y=d.y*a+c.y*(1-a);this.z=d.z*a+c.z*(1-a);this.yd=d.yd*a+c.yd*(1-a);this.ac=d.ac*a+c.ac*(1-a)};return m}();r.Ha=n})(ggP2VR||(ggP2VR={}));
(function(r){var n=function(){function m(){this.tn()}m.prototype.tn=function(){this.kc=1;this.zc=this.lc=this.Kb=0;this.mc=1;this.nc=this.Ub=this.Ac=0;this.Vb=1};m.prototype.clone=function(d){this.kc=d.kc;this.Kb=d.Kb;this.lc=d.lc;this.zc=d.zc;this.mc=d.mc;this.Ac=d.Ac;this.Ub=d.Ub;this.nc=d.nc;this.Vb=d.Vb};m.prototype.sr=function(d){var c=Math.cos(d);d=Math.sin(d);this.kc=1;this.zc=this.lc=this.Kb=0;this.mc=c;this.Ac=-d;this.Ub=0;this.nc=d;this.Vb=c};m.prototype.tr=function(d){var c=Math.cos(d);
d=Math.sin(d);this.kc=c;this.Kb=0;this.lc=d;this.zc=0;this.mc=1;this.Ac=0;this.Ub=-d;this.nc=0;this.Vb=c};m.prototype.ur=function(d){var c=Math.cos(d);d=Math.sin(d);this.kc=c;this.Kb=-d;this.lc=0;this.zc=d;this.mc=c;this.nc=this.Ub=this.Ac=0;this.Vb=1};m.prototype.pr=function(d){this.sr(d*Math.PI/180)};m.prototype.qr=function(d){this.tr(d*Math.PI/180)};m.prototype.rr=function(d){this.ur(d*Math.PI/180)};m.prototype.Od=function(d){this.bd||(this.bd=new m,this.ce=new m);this.bd.pr(d);this.ce.clone(this);
this.multiply(this.bd,this.ce)};m.prototype.Ue=function(d){this.bd||(this.bd=new m,this.ce=new m);this.bd.qr(d);this.ce.clone(this);this.multiply(this.bd,this.ce)};m.prototype.Ve=function(d){this.bd||(this.bd=new m,this.ce=new m);this.bd.rr(d);this.ce.clone(this);this.multiply(this.bd,this.ce)};m.prototype.multiply=function(d,c){this.kc=d.kc*c.kc+d.Kb*c.zc+d.lc*c.Ub;this.Kb=d.kc*c.Kb+d.Kb*c.mc+d.lc*c.nc;this.lc=d.kc*c.lc+d.Kb*c.Ac+d.lc*c.Vb;this.zc=d.zc*c.kc+d.mc*c.zc+d.Ac*c.Ub;this.mc=d.zc*c.Kb+
d.mc*c.mc+d.Ac*c.nc;this.Ac=d.zc*c.lc+d.mc*c.Ac+d.Ac*c.Vb;this.Ub=d.Ub*c.kc+d.nc*c.zc+d.Vb*c.Ub;this.nc=d.Ub*c.Kb+d.nc*c.mc+d.Vb*c.nc;this.Vb=d.Ub*c.lc+d.nc*c.Ac+d.Vb*c.Vb};m.prototype.yq=function(d){var c=d.x;var a=d.y;var b=d.z;d.x=c*this.kc+a*this.Kb+b*this.lc;d.y=c*this.zc+a*this.mc+b*this.Ac;d.z=c*this.Ub+a*this.nc+b*this.Vb};return m}();r.cl=n})(ggP2VR||(ggP2VR={}));
(function(r){r.ka={create:function(n){var m="undefined"!=typeof Float32Array?new Float32Array(16):Array(16);n&&(m[0]=n[0],m[1]=n[1],m[2]=n[2],m[3]=n[3],m[4]=n[4],m[5]=n[5],m[6]=n[6],m[7]=n[7],m[8]=n[8],m[9]=n[9],m[10]=n[10],m[11]=n[11],m[12]=n[12],m[13]=n[13],m[14]=n[14],m[15]=n[15]);return m},set:function(n,m){m[0]=n[0];m[1]=n[1];m[2]=n[2];m[3]=n[3];m[4]=n[4];m[5]=n[5];m[6]=n[6];m[7]=n[7];m[8]=n[8];m[9]=n[9];m[10]=n[10];m[11]=n[11];m[12]=n[12];m[13]=n[13];m[14]=n[14];m[15]=n[15];return m},identity:function(n){n[0]=
1;n[1]=0;n[2]=0;n[3]=0;n[4]=0;n[5]=1;n[6]=0;n[7]=0;n[8]=0;n[9]=0;n[10]=1;n[11]=0;n[12]=0;n[13]=0;n[14]=0;n[15]=1;return n},multiply:function(n,m,d){d||(d=n);var c=n[0],a=n[1],b=n[2],e=n[3],f=n[4],g=n[5],h=n[6],l=n[7],k=n[8],q=n[9],p=n[10],w=n[11],x=n[12],y=n[13],z=n[14];n=n[15];var fa=m[0],la=m[1],B=m[2],db=m[3],ja=m[4],id=m[5],tf=m[6],ih=m[7],hh=m[8],kh=m[9],nh=m[10],oh=m[11],ph=m[12],qh=m[13],rh=m[14];m=m[15];d[0]=fa*c+la*f+B*k+db*x;d[1]=fa*a+la*g+B*q+db*y;d[2]=fa*b+la*h+B*p+db*z;d[3]=fa*e+la*l+
B*w+db*n;d[4]=ja*c+id*f+tf*k+ih*x;d[5]=ja*a+id*g+tf*q+ih*y;d[6]=ja*b+id*h+tf*p+ih*z;d[7]=ja*e+id*l+tf*w+ih*n;d[8]=hh*c+kh*f+nh*k+oh*x;d[9]=hh*a+kh*g+nh*q+oh*y;d[10]=hh*b+kh*h+nh*p+oh*z;d[11]=hh*e+kh*l+nh*w+oh*n;d[12]=ph*c+qh*f+rh*k+m*x;d[13]=ph*a+qh*g+rh*q+m*y;d[14]=ph*b+qh*h+rh*p+m*z;d[15]=ph*e+qh*l+rh*w+m*n;return d},translate:function(n,m,d){var c=m[0],a=m[1];m=m[2];if(!d||n==d)return n[12]=n[0]*c+n[4]*a+n[8]*m+n[12],n[13]=n[1]*c+n[5]*a+n[9]*m+n[13],n[14]=n[2]*c+n[6]*a+n[10]*m+n[14],n[15]=n[3]*
c+n[7]*a+n[11]*m+n[15],n;var b=n[0],e=n[1],f=n[2],g=n[3],h=n[4],l=n[5],k=n[6],q=n[7],p=n[8],w=n[9],x=n[10],y=n[11];d[0]=b;d[1]=e;d[2]=f;d[3]=g;d[4]=h;d[5]=l;d[6]=k;d[7]=q;d[8]=p;d[9]=w;d[10]=x;d[11]=y;d[12]=b*c+h*a+p*m+n[12];d[13]=e*c+l*a+w*m+n[13];d[14]=f*c+k*a+x*m+n[14];d[15]=g*c+q*a+y*m+n[15];return d},scale:function(n,m,d){var c=m[0],a=m[1];m=m[2];if(!d||n==d)return n[0]*=c,n[1]*=c,n[2]*=c,n[3]*=c,n[4]*=a,n[5]*=a,n[6]*=a,n[7]*=a,n[8]*=m,n[9]*=m,n[10]*=m,n[11]*=m,n;d[0]=n[0]*c;d[1]=n[1]*c;d[2]=
n[2]*c;d[3]=n[3]*c;d[4]=n[4]*a;d[5]=n[5]*a;d[6]=n[6]*a;d[7]=n[7]*a;d[8]=n[8]*m;d[9]=n[9]*m;d[10]=n[10]*m;d[11]=n[11]*m;d[12]=n[12];d[13]=n[13];d[14]=n[14];d[15]=n[15];return d},rotate:function(n,m,d,c){var a=d[0],b=d[1];d=d[2];var e=Math.sqrt(a*a+b*b+d*d);if(!e)return null;1!=e&&(e=1/e,a*=e,b*=e,d*=e);var f=Math.sin(m),g=Math.cos(m),h=1-g;m=n[0];e=n[1];var l=n[2],k=n[3],q=n[4],p=n[5],w=n[6],x=n[7],y=n[8],z=n[9],fa=n[10],la=n[11],B=a*a*h+g,db=b*a*h+d*f,ja=d*a*h-b*f,id=a*b*h-d*f,tf=b*b*h+g,ih=d*b*h+
a*f,hh=a*d*h+b*f;a=b*d*h-a*f;b=d*d*h+g;c?n!=c&&(c[12]=n[12],c[13]=n[13],c[14]=n[14],c[15]=n[15]):c=n;c[0]=m*B+q*db+y*ja;c[1]=e*B+p*db+z*ja;c[2]=l*B+w*db+fa*ja;c[3]=k*B+x*db+la*ja;c[4]=m*id+q*tf+y*ih;c[5]=e*id+p*tf+z*ih;c[6]=l*id+w*tf+fa*ih;c[7]=k*id+x*tf+la*ih;c[8]=m*hh+q*a+y*b;c[9]=e*hh+p*a+z*b;c[10]=l*hh+w*a+fa*b;c[11]=k*hh+x*a+la*b;return c},fp:function(n,m,d,c,a,b,e){e||(e=r.ka.create());var f=m-n,g=c-d,h=b-a;e[0]=2*a/f;e[1]=0;e[2]=0;e[3]=0;e[4]=0;e[5]=2*a/g;e[6]=0;e[7]=0;e[8]=(m+n)/f;e[9]=(c+
d)/g;e[10]=-(b+a)/h;e[11]=-1;e[12]=0;e[13]=0;e[14]=-(b*a*2)/h;e[15]=0;return e},perspective:function(n,m,d,c,a){n=d*Math.tan(n*Math.PI/360);m*=n;return r.ka.fp(-m,m,-n,n,d,c,a)},Bs:function(n,m,d,c,a,b,e){e||(e=r.ka.create());var f=m-n,g=c-d,h=b-a;e[0]=2/f;e[1]=0;e[2]=0;e[3]=0;e[4]=0;e[5]=2/g;e[6]=0;e[7]=0;e[8]=0;e[9]=0;e[10]=-2/h;e[11]=0;e[12]=-(n+m)/f;e[13]=-(c+d)/g;e[14]=-(b+a)/h;e[15]=1;return e}}})(ggP2VR||(ggP2VR={}));
(function(r){var n=function(){function m(d){this.ya=r.ka.create();this.Ab=r.ka.create();this.qd=0;this.ib=[];this.Tg=!1;this.Ok=this.Sj=this.Ak=1;this.pf=1E6;this.Xh=[!1,!1,!1,!1,!1,!1];this.Zi=!1;this.Lj=[];this.dl=8;this.qq=new r.cl;this.Yd=[];this.u=d;if(d.Id||d.Qg)d.zh=2}m.prototype.Pg=function(){var d=this.u.S;if(d){var c=d.createShader(d.FRAGMENT_SHADER);d.shaderSource(c,"#ifdef GL_FRAGMENT_PRECISION_HIGH\nprecision highp float;\n#else\nprecision mediump float;\n#endif\nvarying vec2 vTextureCoord;\n\t\t\t\t\tuniform sampler2D uSampler;\n\t\t\t\t\tvoid main(void) {\n\t\t\t\t\t\tgl_FragColor = texture2D(uSampler, vec2(vTextureCoord.s, vTextureCoord.t));\n\t\t\t\t\t}");
d.compileShader(c);d.getShaderParameter(c,d.COMPILE_STATUS)||(console&&console.log(d.getShaderInfoLog(c)),alert(d.getShaderInfoLog(c)),c=null);var a=d.createShader(d.VERTEX_SHADER);this.Zc(a,"#ifdef GL_FRAGMENT_PRECISION_HIGH\nprecision highp float;\n#else\nprecision mediump float;\n#endif\nattribute vec3 aVertexPosition;\n\t\t\t\tattribute vec2 aTextureCoord;\n\t\t\t\tuniform mat4 uMVMatrix;\n\t\t\t\tuniform mat4 uPMatrix;\n\t\t\t\tuniform float uZoffset;\n\t\t\t\tvarying vec2 vTextureCoord;\n\t\t\t\tvoid main(void) {\n\t\t\t\t\tgl_Position = uPMatrix * uMVMatrix * vec4(aVertexPosition, 1.0);\n\t\t\t\t\tgl_Position.z += uZoffset;\n\t\t\t\t\tvTextureCoord = aTextureCoord;\n\t\t\t\t}");
this.P=d.createProgram();this.If(this.P,a,c);this.P.ja=d.getAttribLocation(this.P,"aVertexPosition");d.enableVertexAttribArray(this.P.ja);this.P.Ma=d.getAttribLocation(this.P,"aTextureCoord");d.enableVertexAttribArray(this.P.Ma);this.P.ee=d.getUniformLocation(this.P,"uPMatrix");this.P.jh=d.getUniformLocation(this.P,"uMVMatrix");this.P.Tf=d.getUniformLocation(this.P,"uSampler");this.P.oj=d.getUniformLocation(this.P,"uZoffset");c=d.createShader(d.VERTEX_SHADER);this.Zc(c,"#ifdef GL_FRAGMENT_PRECISION_HIGH\nprecision highp float;\n#else\nprecision mediump float;\n#endif\nattribute vec3 aVertexPosition;\n\t\t\t\tuniform vec2 uCanvasDimensions;\n\t\t\t\tvoid main(void) {\n\t\t\t\t\tvec2 pointNorm = (aVertexPosition.xy / uCanvasDimensions) * 2.0 - vec2(1.0, 1.0);\n\t\t\t\t\tgl_Position = vec4(pointNorm.x, pointNorm.y * -1.0, 0.0, 1.0);\n\t\t\t\t}");
a=d.createShader(d.FRAGMENT_SHADER);this.Zc(a,"#ifdef GL_FRAGMENT_PRECISION_HIGH\nprecision highp float;\n#else\nprecision mediump float;\n#endif\nuniform vec3 uColor;\n\t\t\t\tuniform float uAlpha;\n\t\t\t\tvoid main(void) {\n\t\t\t\t\tgl_FragColor = vec4(uColor, uAlpha);\n\t\t\t\t}");this.Md=d.createProgram();this.If(this.Md,c,a);this.Md.ja=d.getAttribLocation(this.Md,"aVertexPosition");d.enableVertexAttribArray(this.Md.ja);a=d.createShader(d.VERTEX_SHADER);this.Zc(a,"precision highp float;\n\t\t\t\tattribute vec3 aVertexPosition;\n\t\t\t\tvarying vec2 vTextureCoord;\n\t\t\t\tuniform vec2 uCanvasDimensions;\n\t\t\t\tuniform vec4 uRect;\n\t\t\t\tvoid main(void) {\n\t\t\t\t\tvec2 pos = vec2(uRect.x + uRect.z*aVertexPosition.x,uRect.y + uRect.w*aVertexPosition.y);\n\t\t\t\t\tvec2 pointNorm = (pos / uCanvasDimensions) * 2.0 - vec2(1.0, 1.0);\n\t\t\t\t\tgl_Position = vec4(pointNorm.x, pointNorm.y * -1.0, 1.0, 1.0);\n\t\t\t\t\tvTextureCoord.s=aVertexPosition.x;\n\t\t\t\t\tvTextureCoord.t=1.0-aVertexPosition.y;\n\t\t\t\t}");
c=d.createShader(d.FRAGMENT_SHADER);this.Zc(c,"#ifdef GL_FRAGMENT_PRECISION_HIGH\nprecision highp float;\n#else\nprecision mediump float;\n#endif\nvarying vec2 vTextureCoord;\n\t\t\t\tuniform sampler2D uSampler;\n\t\t\t\tvoid main(void) {\n\t\t\t\t\tgl_FragColor = texture2D(uSampler,vTextureCoord);\n\t\t\t\t}");this.zg=d.createProgram();this.If(this.zg,a,c)}};m.prototype.oi=function(){var d=this.u,c=d.S;if(c){var a=c.createShader(c.FRAGMENT_SHADER);var b=this.Xj(13);this.Zc(a,b);b=c.createShader(c.VERTEX_SHADER);
this.Zc(b,"precision highp float;\nattribute vec3 aVertexPosition;\nuniform vec2 uCanvasDimensions;\nvarying vec2 dst;\nuniform vec2 dstSize;\nuniform float zOffset;\nvoid main(void) {\n vec2 pointNorm = (aVertexPosition.xy / uCanvasDimensions) * 2.0 - vec2(1.0, 1.0);\n gl_Position = vec4(pointNorm.x, pointNorm.y * -1.0, zOffset, 1.0);\n dst.x= -1.0 + 2.0*((aVertexPosition.x + 0.5) / uCanvasDimensions.x);\n dst.y= (-1.0 * uCanvasDimensions.y + 2.0*(aVertexPosition.y + 0.5)) / uCanvasDimensions.x;\n}\n");
this.fn=c.createProgram();this.If(this.fn,b,a);a=c.createShader(c.FRAGMENT_SHADER);b=this.Xj(4);this.Zc(a,b);b=c.createShader(c.VERTEX_SHADER);this.Zc(b,"precision highp float;\nattribute vec3 aVertexPosition;\nuniform vec2 uCanvasDimensions;\nvarying vec2 dst;\nuniform vec2 dstSize;\nuniform float zOffset;\nvoid main(void) {\n vec2 pointNorm = (aVertexPosition.xy / uCanvasDimensions) * 2.0 - vec2(1.0, 1.0);\n gl_Position = vec4(pointNorm.x, pointNorm.y * -1.0, zOffset, 1.0);\n dst.x= -1.0 + 2.0*((aVertexPosition.x + 0.5) / uCanvasDimensions.x);\n dst.y= (-1.0 * uCanvasDimensions.y + 2.0*(aVertexPosition.y + 0.5)) / uCanvasDimensions.x;\n}\n");
this.gn=c.createProgram();this.If(this.gn,b,a);a=c.createShader(c.FRAGMENT_SHADER);b=this.Xj(d.F.format);this.Zc(a,b);b=c.createShader(c.VERTEX_SHADER);this.Zc(b,"precision highp float;\nattribute vec3 aVertexPosition;\nuniform vec2 uCanvasDimensions;\nvarying vec2 dst;\nuniform vec2 dstSize;\nvoid main(void) {\n vec2 pointNorm = (aVertexPosition.xy / uCanvasDimensions) * 2.0 - vec2(1.0, 1.0);\n gl_Position = vec4(pointNorm.x, pointNorm.y * -1.0, 0.0, 1.0);\n dst.x= -1.0 + 2.0*((aVertexPosition.x + 0.5) / uCanvasDimensions.x);\n dst.y= (-1.0 * uCanvasDimensions.y + 2.0*(aVertexPosition.y + 0.5)) / uCanvasDimensions.x;\n}\n");
this.hn=c.createProgram();this.If(this.hn,b,a);this.Oi||(this.Oi=c.createBuffer())}else this.u.O("No WebGL to initRemapShader!")};m.prototype.Zc=function(d,c){var a=this.u.S;a.shaderSource(d,c);a.compileShader(d);a.getShaderParameter(d,a.COMPILE_STATUS)||(console&&console.log(a.getShaderInfoLog(d)),Gh&&alert(a.getShaderInfoLog(d)))};m.prototype.If=function(d,c,a){var b=this.u.S;b.attachShader(d,c);b.attachShader(d,a);b.linkProgram(d);b.getProgramParameter(d,b.LINK_STATUS)||(alert("Could not initialise shader program"),
console&&console.log(b.getError()));b.useProgram(d)};m.prototype.Xj=function(d){var c=this.u;var a="#ifdef GL_FRAGMENT_PRECISION_HIGH\nprecision highp float;\n#else\nprecision mediump float;\n#endif\n#define M_PI 3.14159265358979323846\nvarying vec2 dst;\nuniform vec2 srcScale;\nuniform vec2 srcOffset;\nuniform float rectDstDistance;\nuniform float fisheyeDistance;\nuniform float stereoDistance;\nuniform float directionBlend;\nuniform mat4 matRotate; // = mat4( 1.0,0.0,0.0,0.0, 0.0,1.0,0.0,0.0, 0.0,0.0,1.0,0.0, 0.0,0.0,0.0,1.0 );\nconst float rectSrcDistance = 1.0;\nuniform vec2 tonemap;\n";
a=(13==d?a+"uniform samplerCube cubeTexture;":a+"uniform sampler2D tileTexture;\n")+"void main()\n{\n";a+="vec4 direction;\n";a+="vec2 src;\n";a+="vec2 srcCord;\n";a+="vec2 texc;\n";var b=this.km(c.Sa());c.Sa()!=c.Bc&&0!=c.Bc?(c=this.km(c.Bc),a+="vec4 direction1,direction2;\n",a+=b.replace("direction=","direction1="),a+=c.replace("direction=","direction2="),a+="direction=normalize(mix(direction1, direction2,1.0-directionBlend));\n"):a+=b;a+="direction=direction*matRotate;\n";13==d&&(a+="direction.z=-direction.z;",
a+="gl_FragColor = textureCube(cubeTexture, direction.xyz);");4==d&&(a+="float iz=1.0/(direction.z * rectSrcDistance);\n",a+="src.x=-direction.x*iz;\n",a+="src.y= direction.y*iz;\n",a+="texc=src * srcScale + srcOffset;\n",a+="if (",a+="(direction.z<0.0) && ",a+="(texc.x>=0.0) && (texc.x<=1.0) && (texc.y>=0.0) && (texc.y<=1.0)) {\n",a+="  gl_FragColor = texture2D(tileTexture, texc);\n",a+="} else {\n",a+="  discard;\n",a+="}\n");1==d&&(a+="src.x=atan(float(-direction.x), float(-direction.z));",a+=
"src.y=asin(direction.y);\n",a+="texc=src * srcScale + srcOffset;\n",a+="gl_FragColor = texture2D(tileTexture, texc);\n");14==d&&(a+="vec2 cf;\n",a+="if ((direction.z<0.0) && (direction.z<=-abs(direction.x)) && (direction.z<=-abs(direction.y))) {\n",a+="  src.x=-direction.x/direction.z;\n",a+="  src.y=+direction.y/direction.z;\n",a+="  cf.x=1.0;cf.y=3.0;\n",a+="}\n",a+="if ((direction.x>=0.0) && (direction.x>=abs(direction.y)) && (direction.x>=abs(direction.z))) {\n",a+="  src.x=+direction.z/direction.x;\n",
a+="  src.y=-direction.y/direction.x;\n",a+="  cf.x=3.0;cf.y=3.0;\n",a+="}\n",a+="if ((direction.z>=0.0) && (direction.z>=abs(direction.x)) && (direction.z>=abs(direction.y))) {\n",a+="  src.x=-direction.x/direction.z;\n",a+="  src.y=-direction.y/direction.z;\n",a+="  cf.x=5.0;cf.y=3.0;\n",a+="}\n",a+="if ((direction.x<=0.0) && (direction.x<=-abs(direction.y)) && (direction.x<=-abs(direction.z))) {\n",a+="  src.x=+direction.z/direction.x;\n",a+="  src.y=+direction.y/direction.x;\n",a+="  cf.x=1.0;cf.y=1.0;\n",
a+="}\n",a+="if ((direction.y>=0.0) && (direction.y>=abs(direction.x)) && (direction.y>=abs(direction.z))) {\n",a+="  src.x=+direction.x/direction.y;\n",a+="  src.y=-direction.z/direction.y;\n",a+="  cf.x=5.0;cf.y=1.0;\n",a+="}\n",a+="if ((direction.y<=0.0) && (direction.y<=-abs(direction.x)) && (direction.y<=-abs(direction.z))) {\n",a+="  src.x=-direction.x/direction.y;\n",a+="  src.y=-direction.z/direction.y;\n",a+="  cf.x=3.0;cf.y=1.0;\n",a+="}\n",a+="texc.x=(cf.x+src.x*srcScale.x) / 6.0;\n",a+=
"texc.y=(cf.y+src.y*srcScale.y) / 4.0;\n",a+="gl_FragColor = texture2D(tileTexture, texc);\n");return a+="}\n"};m.prototype.km=function(d){var c="";switch(d){case 4:c+="direction.x=dst.x*rectDstDistance;\ndirection.y=dst.y*rectDstDistance;\ndirection.z=-1.0;\n";break;case 12:c+="float r,ph,ro;\nr=length(dst.xy)*0.5;\nro=atan(float(dst.x),float(-dst.y));\nph=r / fisheyeDistance;\ndirection.x= sin(ph) * sin(ro);\ndirection.y=-sin(ph) * cos(ro);\ndirection.z=-cos(ph);\n";break;case 9:c+="float n;\nvec2 ind;\nind=dst*stereoDistance;\nn=1.0 + ind.x*ind.x + ind.y*ind.y;\ndirection.x=2.0*ind.x/n;\ndirection.y=2.0*ind.y/n;\ndirection.z=(n-2.0)/n;\n"}return c+
"direction.w=0.0;\ndirection=normalize(direction);\n"};m.prototype.vm=function(d){var c,a,b=this.u,e=this.u.S;this.Gj=e.createBuffer();e.bindBuffer(e.ARRAY_BUFFER,this.Gj);var f=[-1,-1,1,1,-1,1,1,1,1,-1,1,1];for(c=0;12>c;c++)2>c%3&&(f[c]*=d);e.bufferData(e.ARRAY_BUFFER,new Float32Array(f),e.STATIC_DRAW);this.ze=e.createBuffer();e.bindBuffer(e.ARRAY_BUFFER,this.ze);var g=[1,0,0,0,0,1,1,1];e.bufferData(e.ARRAY_BUFFER,new Float32Array(g),e.STATIC_DRAW);this.md=e.createBuffer();e.bindBuffer(e.ELEMENT_ARRAY_BUFFER,
this.md);var h=[0,1,2,0,2,3];e.bufferData(e.ELEMENT_ARRAY_BUFFER,new Uint16Array(h),e.STATIC_DRAW);f=[];h=[];g=[];var l=new r.Ha;for(d=0;6>d;d++){var k=d%3;var q=3>d?1:0;for(a=0;4>a;a++){l.x=-1;l.y=-1;l.z=1;for(c=0;c<a;c++)l.nn();g.push((0>l.x?.33:0)+.33*k,(0>l.y?0:.5)+.5*q);if(4>d)for(c=0;c<d;c++)l.cr();else 5==d?l.br():l.ar();f.push(l.x,l.y,l.z)}c=4*d;h.push(0+c,1+c,2+c,0+c,2+c,3+c)}b.F.Zk=e.createBuffer();e.bindBuffer(e.ARRAY_BUFFER,b.F.Zk);e.bufferData(e.ARRAY_BUFFER,new Float32Array(f),e.STATIC_DRAW);
b.F.aj=e.createBuffer();e.bindBuffer(e.ARRAY_BUFFER,b.F.aj);e.bufferData(e.ARRAY_BUFFER,new Float32Array(g),e.STATIC_DRAW);b.F.fk=e.createBuffer();e.bindBuffer(e.ELEMENT_ARRAY_BUFFER,b.F.fk);e.bufferData(e.ELEMENT_ARRAY_BUFFER,new Uint16Array(h),e.STATIC_DRAW);this.eq=e.createBuffer();this.cq=e.createBuffer()};m.prototype.$j=function(d){var c=this;return function(){try{if(d.Cq)return;var a=c.u.S;a.pixelStorei(a.UNPACK_FLIP_Y_WEBGL,1);var b=!1;null!=d.Ne&&d.Ne.complete?d.qm||(a.bindTexture(a.TEXTURE_2D,
d),a.texImage2D(a.TEXTURE_2D,0,a.RGBA,a.RGBA,a.UNSIGNED_BYTE,d.Ne),b=d.qm=!0):null!=d.Of&&d.Of.complete&&(a.bindTexture(a.TEXTURE_2D,d),a.texImage2D(a.TEXTURE_2D,0,a.RGBA,a.RGBA,a.UNSIGNED_BYTE,d.Of),b=!0);b&&(d.loaded=!0);a.bindTexture(a.TEXTURE_2D,null);a.pixelStorei(a.UNPACK_FLIP_Y_WEBGL,0)}catch(e){c.u.O(e)}c.u.update(2)}};m.prototype.wm=function(){var d=this.u,c=d.S;if(this.ib)for(;0<this.ib.length;)c.deleteTexture(this.ib.pop());this.ib=[];for(var a=0;6>a;a++){var b=c.createTexture();this.qd++;
b.Of=null;b.Ne=null;b.qm=!1;c.bindTexture(c.TEXTURE_2D,b);c.texImage2D(c.TEXTURE_2D,0,c.RGB,1,1,0,c.RGB,c.UNSIGNED_BYTE,null);c.texParameteri(c.TEXTURE_2D,c.TEXTURE_MIN_FILTER,c.LINEAR);c.texParameteri(c.TEXTURE_2D,c.TEXTURE_WRAP_S,c.CLAMP_TO_EDGE);c.texParameteri(c.TEXTURE_2D,c.TEXTURE_WRAP_T,c.CLAMP_TO_EDGE);if(d.qf[a]){var e=new Image;e.crossOrigin=d.crossOrigin;e.src=d.Pb(d.qf[a]);b.Of=e;e.addEventListener&&e.addEventListener("load",this.$j(b),!1);d.gc.push(e)}this.ib.push(b)}for(a=0;6>a;a++)d.sg[a]&&
(e=new Image,e.crossOrigin=d.crossOrigin,e.src=d.Pb(d.sg[a]),e.addEventListener?e.addEventListener("load",this.$j(this.ib[a]),!1):e.onload=this.$j(this.ib[a]),this.ib[a].Ne=e,d.gc.push(e));for(a=0;a<d.T.length;a++)d.T[a].cd||(d.T[a].texture=c.createTexture(),d.qd++,c.bindTexture(c.TEXTURE_2D,d.T[a].texture),c.texImage2D(c.TEXTURE_2D,0,c.RGB,1,1,0,c.RGB,c.UNSIGNED_BYTE,null),c.texParameteri(c.TEXTURE_2D,c.TEXTURE_MIN_FILTER,c.LINEAR),c.texParameteri(c.TEXTURE_2D,c.TEXTURE_WRAP_S,c.CLAMP_TO_EDGE),c.texParameteri(c.TEXTURE_2D,
c.TEXTURE_WRAP_T,c.CLAMP_TO_EDGE));d.F.texture=c.createTexture();d.qd++;c.bindTexture(c.TEXTURE_2D,d.F.texture);c.texImage2D(c.TEXTURE_2D,0,c.RGB,1,1,0,c.RGB,c.UNSIGNED_BYTE,null);c.texParameteri(c.TEXTURE_2D,c.TEXTURE_MIN_FILTER,c.LINEAR);c.texParameteri(c.TEXTURE_2D,c.TEXTURE_WRAP_S,c.CLAMP_TO_EDGE);c.texParameteri(c.TEXTURE_2D,c.TEXTURE_WRAP_T,c.CLAMP_TO_EDGE);c.bindTexture(c.TEXTURE_2D,null)};m.prototype.ts=function(){var d=this.u;if(d.D.width!=d.L.offsetWidth||d.D.height!=d.L.offsetHeight)d.D.width=
d.L.offsetWidth,d.D.height=d.L.offsetHeight;d.Ee&&(d.ad(0),d.Pc());if(d.S){var c=d.S;this.ij();c.clear(c.DEPTH_BUFFER_BIT);c.useProgram(this.P);this.Xf(0);c.uniform1i(this.P.Tf,0);c.enableVertexAttribArray(this.P.ja);c.enableVertexAttribArray(this.P.Ma);c.bindBuffer(c.ARRAY_BUFFER,this.ze);c.vertexAttribPointer(this.P.Ma,2,c.FLOAT,!1,0,0);c.activeTexture(c.TEXTURE0);c.bindBuffer(c.ELEMENT_ARRAY_BUFFER,this.md);c.uniform1f(this.P.oj,1E-4);c.vertexAttribPointer(this.P.ja,3,c.FLOAT,!1,0,0);r.ka.identity(this.Ab);
r.ka.perspective(d.Tb(),d.zb.width/d.zb.height,.1,100,this.Ab);c.uniformMatrix4fv(this.P.ee,!1,this.Ab);for(d=0;6>d;d++)this.Xf(d),c.bindBuffer(c.ARRAY_BUFFER,this.Gj),c.vertexAttribPointer(this.P.ja,3,c.FLOAT,!1,0,0),c.bindBuffer(c.ARRAY_BUFFER,this.ze),c.vertexAttribPointer(this.P.Ma,2,c.FLOAT,!1,0,0),6<=this.ib.length&&this.ib[d].loaded&&(c.activeTexture(c.TEXTURE0),c.bindTexture(c.TEXTURE_2D,this.ib[d]),c.bindBuffer(c.ELEMENT_ARRAY_BUFFER,this.md),c.uniform1i(this.P.Tf,0),c.uniformMatrix4fv(this.P.jh,
!1,this.ya),c.uniformMatrix4fv(this.P.ee,!1,this.Ab),c.drawElements(c.TRIANGLES,6,c.UNSIGNED_SHORT,0))}};m.prototype.ij=function(){var d=this.u;if(d.v.Pf&&6<d.v.Pf.length){var c=parseInt(d.v.Pf);d.S.clearColor((c>>16&255)/255,(c>>8&255)/255,(c>>0&255)/255,1)}};m.prototype.Xf=function(d,c){void 0===c&&(c=1);var a=this.u;r.ka.identity(this.ya);r.ka.rotate(this.ya,c*-a.V.m*Math.PI/180,[0,0,1]);r.ka.rotate(this.ya,c*-a.A.m*Math.PI/180,[1,0,0]);-1==c?r.ka.rotate(this.ya,-a.pan.m*Math.PI/180,[0,1,0]):r.ka.rotate(this.ya,
(180-a.pan.m)*Math.PI/180,[0,1,0]);a.Oa&&(r.ka.rotate(this.ya,-a.Oa.pitch*Math.PI/180,[1,0,0]),r.ka.rotate(this.ya,a.Oa.V*Math.PI/180,[0,0,1]));4>d?r.ka.rotate(this.ya,-Math.PI/2*d,[0,1,0]):r.ka.rotate(this.ya,Math.PI/2*(5==d?1:-1),[1,0,0])};m.prototype.Tr=function(d){var c=this;return function(){c.Lj.push(d)}};m.prototype.Zo=function(d){this.u.Na=!0;this.u.nd=!0;d.loaded=!0;d.Bk=0;d.ie=0;var c=this.u.S;this.Dl();c.pixelStorei(c.UNPACK_FLIP_Y_WEBGL,1);if(null!=d.v&&d.v.complete){d.rb=c.createTexture();
this.u.qd++;c.bindTexture(c.TEXTURE_2D,d.rb);try{c.texImage2D(c.TEXTURE_2D,0,c.RGBA,c.RGBA,c.UNSIGNED_BYTE,d.v)}catch(a){c.texImage2D(c.TEXTURE_2D,0,c.RGBA,1,1,0,c.RGBA,c.UNSIGNED_BYTE,new Uint8Array([128,128,128,250])),this.u.O(a)}}this.u.update(2)};m.prototype.Dl=function(){this.u.$b&&this.u.$b--};m.prototype.$o=function(){if(0<this.Lj.length){var d=this.Lj.shift();this.Zo(d)}};m.prototype.zq=function(d){var c=this;return function(){c.u.Na=!0;c.u.nd=!0;var a=c.u.v;try{if(null!=d&&d.complete){var b=
a.levels[a.levels.length-1],e=a.Ea;b.height=b.width=d.width-2*e;b.U=b.ea=1;for(var f=0;6>f;f++){var g=new r.Sd;g.W=document.createElement("canvas");c.u.ia?(g.W.width=b.width+2*e,g.W.height=b.height+2*e):(g.W.width=a.N+2*e,g.W.height=a.N+2*e);g.cb=g.W.getContext("2d");g.W.style[c.u.Va+"Origin"]="0% 0%";g.W.style.overflow="hidden";g.W.style.position="absolute";g.v=d;var h=b.width+2*e,l=b.height+2*e;g.cb&&g.cb.drawImage(d,0,f*l,h,l,0,0,h,l);if(c.u.ia&&c.u.S){var k=c.u.S;k.pixelStorei(k.UNPACK_FLIP_Y_WEBGL,
1);g.rb=k.createTexture();c.u.qd++;k.bindTexture(k.TEXTURE_2D,g.rb);try{k.texImage2D(k.TEXTURE_2D,0,k.RGBA,k.RGBA,k.UNSIGNED_BYTE,g.W)}catch(q){c.u.O(q)}k.bindTexture(k.TEXTURE_2D,null);k.pixelStorei(k.UNPACK_FLIP_Y_WEBGL,0)}c.u.hd&&(g.W.$d=-1,c.u.L.insertBefore(g.W,c.u.L.firstChild));b.ba[f]=g}b.loaded=!0}}catch(q){c.u.O(q)}c.u.update(2)}};m.prototype.Mn=function(d){var c=this;return function(){c.u.Na=!0;c.u.nd=!0;c.Dl();d.v=null}};m.prototype.rs=function(){var d=this.u,c=d.v,a=d.v.levels;d.Ee&&
(d.ad(0),d.Pc());if(d.S){var b=d.S;b.useProgram(this.P);this.ij();b.clear(b.DEPTH_BUFFER_BIT);b.enable(b.DEPTH_TEST);r.ka.identity(this.Ab);r.ka.perspective(d.Tb(),d.zb.width/d.zb.height,.1,100,this.Ab);b.uniformMatrix4fv(this.P.ee,!1,this.Ab);d.Tn();d.pk();var e=d.Qj();var f=a.length-1;for(d.Cc=0;f>=e;){var g=a[f],h=1;f==a.length-1&&0==c.Ea&&(h=c.N/(c.N-.5));for(var l=0;6>l;l++){var k=d.cube.faces[l];var q=k.Mf;if(k.qb&&0<q.fg&&0<q.Kh&&0<q.scale||g.cache){k.Na=!1;k.bounds[f]||(k.bounds[f]={jb:0,
Gb:0,Ib:0,Jb:0});var p=k.bounds[f];g.cache?(p.jb=0,p.Gb=0,p.Ib=g.U-1,p.Jb=g.ea-1):d.lm(g,q,p);q=!0;for(var w=p.Gb;w<=p.Jb;w++)for(var x=p.jb;x<=p.Ib;x++){var y=x+w*g.U+l*g.U*g.ea,z=g.ba[y];z||(z=g.ba[y]=new r.Sd);this.ai()?z.v||(z.ie?z.ie--:(this.Ai(z,g,d.ne(l,f,x,w)),d.Na=!0)):d.Cc++;if(z.rb){if(!z.yf){y=.5*f+1;z.yf=b.createBuffer();b.bindBuffer(b.ARRAY_BUFFER,z.yf);var fa=[-1,-1,1,1,-1,1,1,1,1,-1,1,1];fa[3]=x*c.N-c.Ea;fa[0]=Math.min((x+1)*c.N,g.width)+c.Ea;fa[7]=w*c.N-c.Ea;fa[1]=Math.min((w+1)*
c.N,g.height)+c.Ea;fa[4]=fa[1];fa[6]=fa[3];fa[9]=fa[0];fa[10]=fa[7];for(var la=0;12>la;la++)fa[la]=0==la%3?h*y*(-2*fa[la]/g.width+1):1==la%3?h*y*(-2*fa[la]/g.height+1):y;b.bufferData(b.ARRAY_BUFFER,new Float32Array(fa),b.STATIC_DRAW)}}else q=!1;z.visible=k.qb}p.lk=q}}f--}for(l=0;6>l;l++)if(k=d.cube.faces[l],k.qb)for(q=k.Mf,this.Xf(l),b.uniform1i(this.P.Tf,0),b.uniformMatrix4fv(this.P.ee,!1,this.Ab),b.uniformMatrix4fv(this.P.jh,!1,this.ya),b.enableVertexAttribArray(this.P.ja),b.enableVertexAttribArray(this.P.Ma),
b.bindBuffer(b.ARRAY_BUFFER,this.ze),b.vertexAttribPointer(this.P.Ma,2,b.FLOAT,!1,0,0),b.activeTexture(b.TEXTURE0),b.bindBuffer(b.ELEMENT_ARRAY_BUFFER,this.md),b.useProgram(this.P),f=e;f<=a.length-1;){g=a[f];if(k.qb&&0<q.fg&&k.bounds[f]&&0<=k.bounds[f].jb){p=k.bounds[f];for(w=p.Gb;w<=p.Jb;w++)for(x=p.jb;x<=p.Ib;x++)y=x+w*g.U+l*g.U*g.ea,(z=g.ba[y])&&z.rb&&(b.uniform1f(this.P.oj,1E-4*(x%2+w%2*2)),b.bindBuffer(b.ARRAY_BUFFER,z.yf),b.vertexAttribPointer(this.P.ja,3,b.FLOAT,!1,0,0),b.bindTexture(b.TEXTURE_2D,
z.rb),b.texParameteri(b.TEXTURE_2D,b.TEXTURE_MAG_FILTER,b.LINEAR),b.texParameteri(b.TEXTURE_2D,b.TEXTURE_MIN_FILTER,b.LINEAR),b.texParameteri(b.TEXTURE_2D,b.TEXTURE_WRAP_S,b.CLAMP_TO_EDGE),b.texParameteri(b.TEXTURE_2D,b.TEXTURE_WRAP_T,b.CLAMP_TO_EDGE),b.drawElements(b.TRIANGLES,6,b.UNSIGNED_SHORT,0)),z.visible=k.qb;p.lk&&(f=a.length)}f++}this.Ck();d.nd=!1}};m.prototype.ai=function(){return this.u.$b<this.u.zh};m.prototype.Ai=function(d,c,a){var b=this.u;b.ek++;d.v=new Image;d.Bk++;d.ie=1<<d.Bk;d.v.onload=
this.Tr(d);d.v.onerror=this.Mn(d);d.v.onabort=this.Mn(d);d.v.crossOrigin=b.crossOrigin;d.v.setAttribute("src",a);b.O("load "+a);c.cache&&b.gc.push(d.v);b.$b++};m.prototype.co=function(){var d=this.u,c=d.v;d.Ee&&(d.ad(0),d.Pc());if(d.S){var a=d.S;this.ij();Gh&&a.clearColor(.2,0,0,1);a.clear(a.DEPTH_BUFFER_BIT);a.disable(a.DEPTH_TEST);a.disable(a.CULL_FACE);a.bindBuffer(a.ARRAY_BUFFER,this.Oi);var b=[0,0];b[2]=d.D.width;b[3]=0;b[4]=d.D.width;b[5]=d.D.height;b[6]=0;b[7]=d.D.height;a.bufferData(a.ARRAY_BUFFER,
new Float32Array(b),a.STATIC_DRAW);this.u.Cc=0;if(!this.Hc||this.Tg)0<c.levels.length?this.Xo():this.Yo();d.F.td?this.Nq():(a.enable(a.DEPTH_TEST),a.depthRange(0,1),a.depthFunc(a.LESS),this.Zi=!1,0<c.levels.length&&this.ss(),this.Hc&&!this.Zi&&this.Mq())}};m.prototype.Dr=function(d,c,a,b,e,f,g){var h=this.u,l=h.v,k=h.D,q=a*l.N/c.width,p=(a+1)*l.N/c.width;a=b*l.N/c.height;c=(b+1)*l.N/c.height;1<p&&(e*=2,p=1);1<c&&(e*=2,c=1);e=Math.min(this.dl,e);p=(p-q)/e;var w=(c-a)/e;b=c=0;l={x:0,y:0};var x={x:0,
y:0},y=0;d.ki=0;var z=h.kh,fa=new r.Ha,la=this.qq;la.tn();4>f?la.Ue(-90*f):la.Od(5==f?90:-90);h.Oa&&(la.Ve(h.Oa.V),la.Od(-h.Oa.pitch));la.Ue(-h.pan.m);la.Od(h.A.m);la.Ve(h.V.m);for(f=0;f<=e;f++)for(var B=0;B<=e;B++){var db=2*(q+B*p)-1;var ja=2*(a+f*w)-1;fa.x=1*db;fa.y=1*ja;fa.z=-1;fa.normalize();la.yq(fa);db=this.hm(fa,l,h.Sa());0!=h.Bc&&1>z&&(db=db&&this.hm(fa,x,h.Bc),l.x=l.x*z+x.x*(1-z),l.y=l.y*z+x.y*(1-z));db?-1E10<l.x&&1E10>l.x&&-1E10<l.y&&1E10>l.y?-2<l.x&&2>l.x&&-2<l.y&&2>l.y&&(c+=l.x,b+=l.y,
y++):l.x=NaN:l.x=NaN;d.rd[d.ki++]=l.x;d.rd[d.ki++]=l.y}0<y?(c/=y,b/=y):g=0;for(a=0;a<d.ki;a+=2)l.x=d.rd[a],l.y=d.rd[a+1],h=l.x-c,q=l.y-b,l.x+=h*g,l.y+=q*g,d.rd[a]=k.width/2+l.x*k.width/2,d.rd[a+1]=k.height/2-l.y*k.width/2;this.Er(d,e)};m.prototype.hm=function(d,c,a){var b=!0;switch(a){case 0:case 4:a=1/(d.z*this.Ak);c.x=-d.x*a;c.y=d.y*a;0<d.z&&(b=!1);break;case 9:1==d.z&&(b=!1);a=1/((1-d.z)*this.Ok);c.x=d.x*a;c.y=-d.y*a;break;case 12:if(a=Math.sqrt(d.x*d.x+d.y*d.y),0==a)c.x=0,c.y=0;else{var e=2*this.Sj*
Math.acos(-d.z)/a;if(2<a)return!1;c.x=e*d.x;c.y=-e*d.y}}return b};m.prototype.Er=function(d,c){for(var a=this.u,b=[],e,f=d.Fd=0;f<c;f++)for(var g=0;g<c;g++){b[0]=f+g*(c+1);b[1]=f+1+g*(c+1);b[2]=f+(g+1)*(c+1);b[3]=f+1+(g+1)*(c+1);e=!0;for(var h=0;4>h;h++)isNaN(d.rd[2*b[0]])&&(e=!1);if(e){var l=!1,k=!1,q=!1,p=!1;for(h=0;4>h;h++){var w=d.rd[2*b[h]];w<a.D.width&&(k=!0);0<=w&&(l=!0);w=d.rd[2*b[h]+1];w<a.D.height&&(q=!0);0<=w&&(p=!0)}if(e=e&&k&&l&&q&&p)d.Je[d.Fd++]=b[0],d.Je[d.Fd++]=b[3],d.Je[d.Fd++]=b[2],
d.Je[d.Fd++]=b[0],d.Je[d.Fd++]=b[1],d.Je[d.Fd++]=b[3]}}};m.prototype.ss=function(){var d=this.u,c=d.v,a=d.v.levels;d.Ee&&(d.ad(0),d.Pc());if(d.S){var b=d.S,e=this.gn;b.useProgram(e);this.Uk(e);b.enable(b.CULL_FACE);b.cullFace(b.FRONT);b.enable(b.DEPTH_TEST);r.ka.identity(this.Ab);r.ka.perspective(d.Tb(),d.zb.width/d.zb.height,.1,100,this.Ab);b.uniformMatrix4fv(b.getUniformLocation(e,"uPMatrix"),!1,this.Ab);this.u.Cc=0;d.pk();var f=d.Qj(),g=0;var h=a.length-1;for(var l={},k=a[h];k.Se&&0<h;)h--,k=a[h];
for(var q=h,p=q,w=0;6>w;w++)for(var x=0;x<k.ea;x++)for(var y=0;y<k.U;y++){var z=y+x*k.U+w*k.U*k.ea;l[z]=1}for(;h>=f;){var fa={};k=a[h];var la=null;0<h&&(la=a[h-1]);var B=!0;for(var db in l)if(l.hasOwnProperty(db)){z=Number(db);var ja=k.ba[z];w=Number(Math.floor(z/(k.U*k.ea)));x=Math.floor((z-w*k.U*k.ea)/k.U);y=Math.floor(z-(x*k.U+w*k.U*k.ea));if(6<=w)console.log("Grrr...");else{var id=this.u.cube.faces[w];id.Na=!1;ja||(ja=k.ba[z]=new r.Sd,d.O("create "+z));this.Dr(ja,k,y,x,Math.max(1,this.dl>>q-h),
w,-(0!=d.Bc)?.3:.1);ja.visible=0<ja.Fd||k.cache;ja.vi=3;ja.Xg=Date.now();ja.visible&&!ja.rb&&(B=!1,this.ai()?ja.v||(ja.ie?ja.ie--:(this.Ai(ja,k,d.ne(w,h,y,x)),d.Na=!0)):this.u.Cc++);if(la&&(ja.visible||la.cache)){ja=(y*c.N+1)/k.width;y=Math.min(1,((y+1)*c.N-1)/k.width);var tf=(x*c.N+1)/k.height;x=Math.min(1,((x+1)*c.N-1)/k.height);z=c.N/la.width;id=c.N/la.height;var ih=tf;tf=Math.floor(tf*la.height/c.N);do{var hh=ja,kh=Math.floor(ja*la.width/c.N);do{var nh=kh+tf*la.U+w*la.U*la.ea;kh<la.U&&tf<la.ea?
fa[nh]=1:d.O("Grrrr");kh++;hh+=z}while(hh<y);tf++;ih+=id}while(ih<x)}}}B&&(p=h,20>d.fov.m&&h<this.pf&&(this.Zi=!0));l=fa;h--}this.Ck();b.uniform1i(b.getUniformLocation(e,"tileTexture"),0);b.activeTexture(b.TEXTURE0);h=f;for(f=-1;h<=Math.min(p,this.pf-1);){k=a[h];for(db in k.ba)if(k.ba.hasOwnProperty(db)){l=Number(db);ja=k.ba[l];w=Math.floor(l/(k.U*k.ea));x=Math.floor((l-w*k.U*k.ea)/k.U);y=Math.floor(l-(x*k.U+w*k.U*k.ea));f!=w&&(f=w,this.jj(w,e));if(g>d.Oe){d.O("Excided painted tiles");this.Zi=!1;
break}ja.rb&&(l=w=c.N,y==k.U-1&&(w=k.width-c.N*y),x==k.ea-1&&(l=k.height-c.N*x),w=(w+2*c.Ea)/c.N,l=(l+2*c.Ea)/c.N,b.bindTexture(b.TEXTURE_2D,ja.rb),b.uniform2f(b.getUniformLocation(e,"uCanvasDimensions"),d.D.width,d.D.height),q=b.getUniformLocation(e,"srcScale"),b.uniform2f(q,.5*k.width/c.N/w,.5*k.height/c.N/l),q=b.getUniformLocation(e,"srcOffset"),b.uniform2f(q,(.5*k.width+c.Ea-c.N*y)/c.N/w,-(.5*k.height+c.Ea-c.N*x)/c.N/l+1),q=b.getUniformLocation(e,"zOffset"),b.uniform1f(q,(h+1)/(a.length+5)),w=
b.getAttribLocation(e,"aVertexPosition"),b.disableVertexAttribArray(0),b.disableVertexAttribArray(1),b.disableVertexAttribArray(2),b.enableVertexAttribArray(w),b.activeTexture(b.TEXTURE0),b.texParameteri(b.TEXTURE_2D,b.TEXTURE_MAG_FILTER,b.LINEAR),b.texParameteri(b.TEXTURE_2D,b.TEXTURE_MIN_FILTER,b.LINEAR),b.texParameteri(b.TEXTURE_2D,b.TEXTURE_WRAP_S,b.CLAMP_TO_EDGE),b.texParameteri(b.TEXTURE_2D,b.TEXTURE_WRAP_T,b.CLAMP_TO_EDGE),b.bindBuffer(b.ARRAY_BUFFER,this.eq),b.vertexAttribPointer(w,2,b.FLOAT,
!1,0,0),b.bufferData(b.ARRAY_BUFFER,new Float32Array(ja.rd),b.DYNAMIC_DRAW),b.bindBuffer(b.ELEMENT_ARRAY_BUFFER,this.cq),b.bufferData(b.ELEMENT_ARRAY_BUFFER,new Uint16Array(ja.Je),b.DYNAMIC_DRAW),b.drawElements(b.TRIANGLES,ja.Fd,b.UNSIGNED_SHORT,0),g++)}h++}b.disable(b.CULL_FACE);b.cullFace(b.FRONT_AND_BACK);d.nd=!1}};m.prototype.jj=function(d,c){var a=this.u.S;r.ka.identity(this.ya);this.Xf(d,-1);a.uniformMatrix4fv(a.getUniformLocation(c,"matRotate"),!1,this.ya)};m.prototype.Nq=function(){var d=
this.u;if(d.S){var c=d.S,a=this.hn;c.useProgram(a);this.jj(0,a);c.uniform2f(c.getUniformLocation(a,"uCanvasDimensions"),d.D.width,d.D.height);var b=c.getUniformLocation(a,"srcOffset");c.uniform2f(b,.5,.5);1==d.F.format&&(b=c.getUniformLocation(a,"srcScale"),d.Jd?(c.uniform2f(b,-.5/Math.PI,(d.F.flipY?-.5:.5)/Math.PI),b=c.getUniformLocation(a,"srcOffset"),d.yh?c.uniform2f(b,.5,.75):c.uniform2f(b,.5,.25)):c.uniform2f(b,-.5/Math.PI,(d.F.flipY?-1:1)/Math.PI));14==d.F.format&&(b=c.getUniformLocation(a,
"srcScale"),c.uniform2f(b,1-2*d.F.kf/(d.F.width/3),1-2*d.F.kf/(d.F.height/2)));this.Uk(a);b=c.getUniformLocation(a,"cubeTexture");c.uniform1i(b,0);b=c.getAttribLocation(a,"aVertexPosition");c.disableVertexAttribArray(0);c.disableVertexAttribArray(1);c.disableVertexAttribArray(2);c.enableVertexAttribArray(b);c.bindBuffer(c.ARRAY_BUFFER,this.Oi);c.vertexAttribPointer(b,2,c.FLOAT,!1,0,0);c.activeTexture(c.TEXTURE0);c.bindTexture(c.TEXTURE_2D,d.F.texture);c.texParameteri(c.TEXTURE_2D,c.TEXTURE_WRAP_S,
c.CLAMP_TO_EDGE);c.texParameteri(c.TEXTURE_2D,c.TEXTURE_WRAP_T,c.CLAMP_TO_EDGE);c.texParameteri(c.TEXTURE_2D,c.TEXTURE_MIN_FILTER,c.LINEAR);c.texParameteri(c.TEXTURE_2D,c.TEXTURE_MAG_FILTER,c.LINEAR);c.bindBuffer(c.ELEMENT_ARRAY_BUFFER,this.md);c.drawElements(c.TRIANGLES,6,c.UNSIGNED_SHORT,0)}};m.prototype.Uk=function(d){var c=this.u,a=c.S,b=this.u.D,e=b.width/b.height;switch(c.fov.mode){case 1:e=1;break;case 2:e=b.width/Math.sqrt(b.width*b.width+b.height*b.height);break;case 3:4*b.height/3<b.width&&
(e=4/3)}b=a.getUniformLocation(d,"rectDstDistance");this.Ak=Math.tan(Math.min(c.fov.m,179)/2*Math.PI/180)*e;a.uniform1f(b,this.Ak);b=a.getUniformLocation(d,"fisheyeDistance");this.Sj=180/(c.fov.m*Math.PI*e);a.uniform1f(b,this.Sj);b=a.getUniformLocation(d,"stereoDistance");this.Ok=Math.tan(Math.min(c.fov.m,359)/4*Math.PI/180)*e;a.uniform1f(b,this.Ok);b=a.getUniformLocation(d,"directionBlend");a.uniform1f(b,c.kh)};m.prototype.Mq=function(){var d=this.u,c=d.S,a=this.fn;c.useProgram(a);c.enable(c.DEPTH_TEST);
this.jj(0,a);c.uniform2f(c.getUniformLocation(a,"uCanvasDimensions"),d.D.width,d.D.height);d=c.getUniformLocation(a,"srcScale");c.uniform2f(d,1,1);d=c.getUniformLocation(a,"srcOffset");c.uniform2f(d,0,0);d=c.getUniformLocation(a,"zOffset");c.uniform1f(d,.9999);this.Uk(a);this.jj(0,a);d=c.getUniformLocation(a,"cubeTexture");c.uniform1i(d,0);a=c.getAttribLocation(a,"aVertexPosition");c.disableVertexAttribArray(0);c.disableVertexAttribArray(1);c.disableVertexAttribArray(2);c.enableVertexAttribArray(a);
c.bindBuffer(c.ARRAY_BUFFER,this.Oi);c.vertexAttribPointer(a,2,c.FLOAT,!1,0,0);c.activeTexture(c.TEXTURE0);c.bindTexture(c.TEXTURE_CUBE_MAP,this.Hc);c.texParameteri(c.TEXTURE_CUBE_MAP,c.TEXTURE_WRAP_S,c.CLAMP_TO_EDGE);c.texParameteri(c.TEXTURE_CUBE_MAP,c.TEXTURE_WRAP_T,c.CLAMP_TO_EDGE);c.texParameteri(c.TEXTURE_CUBE_MAP,c.TEXTURE_MIN_FILTER,c.LINEAR);c.texParameteri(c.TEXTURE_CUBE_MAP,c.TEXTURE_MAG_FILTER,c.LINEAR);c.bindBuffer(c.ELEMENT_ARRAY_BUFFER,this.md);c.drawElements(c.TRIANGLES,6,c.UNSIGNED_SHORT,
0)};m.prototype.Yo=function(){for(var d=this.u,c=d.S,a=[1,3,5,4,0,2],b=!0,e=!0,f=!1,g=0;6>g;g++)this.ib[g].Ne.complete?this.Xh[g]||(f=!0):b=!1,this.ib[g].Of.complete||(e=!1);if(e||b)if(!e||b||!this.Hc||f){g=Math.round(d.Dc/d.bf);e=(d.Dc-g)/2;d.O("paint cube single - isMain: "+b+" overlap: "+e);this.pf=0;this.Hc||(this.Hc=c.createTexture());d.qd++;c.bindTexture(c.TEXTURE_CUBE_MAP,this.Hc);c.texParameteri(c.TEXTURE_CUBE_MAP,c.TEXTURE_WRAP_S,c.CLAMP_TO_EDGE);c.texParameteri(c.TEXTURE_CUBE_MAP,c.TEXTURE_WRAP_T,
c.CLAMP_TO_EDGE);c.pixelStorei(c.UNPACK_FLIP_Y_WEBGL,1);f=document.createElement("canvas");f.width=g;f.height=g;var h=f.getContext("2d");for(g=0;6>g;g++){var l=a[g];this.ib[l].Ne.complete?this.Xh[l]||(h.drawImage(this.ib[l].Ne,-e,-e),c.texImage2D(c.TEXTURE_CUBE_MAP_POSITIVE_X+g,0,c.RGBA,c.RGBA,c.UNSIGNED_BYTE,f),this.Xh[l]=!0):(h.drawImage(this.ib[l].Of,-e,-e,d.Dc,d.Dc),c.texImage2D(c.TEXTURE_CUBE_MAP_POSITIVE_X+g,0,c.RGBA,c.RGBA,c.UNSIGNED_BYTE,f))}this.Tg=!b}};m.prototype.Xo=function(){var d=this.u,
c=this.u.v,a=d.v.levels,b=d.S,e;var f=a.length-1;if(!(0>f)){a[f].Se&&f--;var g=512;d.Sg&&(g=256);!d.Sf&&2<=d.devicePixelRatio&&(g=512);for((e=b.getParameter(b.MAX_CUBE_MAP_TEXTURE_SIZE))&&e<g&&(g=e);0<f&&a[f-1].width<=g;)f--;g=a[f];if(0!=g.U){e=f;var h=this.Qo(f);this.Tg&&h&&(this.Tg=!1);h||(f=a.length-1,g=a[f],h||(g.Se?(h=g.loaded,this.nk(f-1)&&(--f,h=!0)):h=this.nk(f)),this.Tg=!0);this.nk(e);if(h&&this.pf>f){g=a[f];d.O("paint cube level "+f);this.pf=f;a=d.v.Ea;f=0<a||1<g.U||1<g.ea;h=e=void 0;f&&
(h=document.createElement("canvas"),h.width=g.width,h.height=g.height,2048>g.width&&(1500<g.width?(h.width=2048,h.height=2048):700<g.width?(h.width=1024,h.height=1024):(h.width=512,h.height=512)),e=h.getContext("2d"));this.Hc=b.createTexture();d.qd++;b.bindTexture(b.TEXTURE_CUBE_MAP,this.Hc);b.texParameteri(b.TEXTURE_CUBE_MAP,b.TEXTURE_WRAP_S,b.CLAMP_TO_EDGE);b.texParameteri(b.TEXTURE_CUBE_MAP,b.TEXTURE_WRAP_T,b.CLAMP_TO_EDGE);b.pixelStorei(b.UNPACK_FLIP_Y_WEBGL,1);var l=[1,3,5,4,0,2];c=c.N;for(var k=
0;6>k;k++){for(var q=0;q<g.ea;q++)for(var p=0;p<g.U;p++){var w=p+q*g.U+l[k]*g.U*g.ea,x=g.ba[w],y=x.v;x.W&&(y=x.W);y?f?(w=h.width/g.width,e.drawImage(y,w*(p*c-a),w*(q*c-a),w*y.width,w*y.height)):b.texImage2D(b.TEXTURE_CUBE_MAP_POSITIVE_X+k,0,b.RGBA,b.RGBA,b.UNSIGNED_BYTE,y):(d.O("WTF?!"),d.O(w),d.O(x))}f&&b.texImage2D(b.TEXTURE_CUBE_MAP_POSITIVE_X+k,0,b.RGBA,b.RGBA,b.UNSIGNED_BYTE,h)}}}}};m.prototype.nk=function(d){var c=this.u,a=c.v.levels[d];if(0==a.U)return!1;var b=!0;a.cache=!0;for(var e=0;6>e;e++)for(var f=
0;f<a.ea;f++)for(var g=0;g<a.U;g++){var h=g+f*a.U+e*a.U*a.ea,l=a.ba[h];l||(l=a.ba[h]=new r.Sd);this.ai()?l.v||(l.ie?l.ie--:(this.Ai(l,a,c.ne(e,d,g,f)),c.Na=!0)):this.u.Cc++;l.rb||(b=!1,c.Na=!0)}b&&(a.loaded=!0);return b};m.prototype.Qo=function(d){d=this.u.v.levels[d];if(0==d.U)return!1;for(var c=0;6>c;c++)for(var a=0;a<d.ea;a++)for(var b=0;b<d.U;b++){var e=d.ba[b+a*d.U+c*d.U*d.ea];if(!e||!e.rb)return!1}return d.loaded=!0};m.prototype.ready=function(){return null!=this.Hc};m.prototype.Ck=function(){for(var d=
this.u,c=d.v.levels,a=d.S,b=Date.now(),e=c.length-1;0<=e;e--){var f=c[e];if(!f.cache)for(var g in f.ba)if(f.ba.hasOwnProperty(g)){var h=f.ba[g];0<h.vi&&h.vi--;h.visible||0<h.vi?(h.visible&&(h.Xg=b),h=this.Yd.indexOf(h),-1!==h&&this.Yd.splice(h,1)):-1===this.Yd.indexOf(h)&&(h.level=f,this.Yd.push(h))}}if(this.Yd.length>1.1*d.Kn)for(this.Yd.sort(function(l,k){return k.Xg-l.Xg});this.Yd.length>d.Kn;)h=this.Yd.pop(),h.rb&&(a.deleteTexture(h.rb),d.qd--,h.rb=0),h.v=null,h.yf&&(a.deleteBuffer(h.yf),h.yf=
0),g=h.level.ba.indexOf(h),d.O("delete "+g+" "+(b-h.Xg)),delete h.level.ba[g]};m.prototype.ks=function(){var d=this.u;if(d.S){var c=this.u.S;c.disable(c.DEPTH_TEST);var a;for(a=0;a<d.T.length;a++){var b=d.T[a];if(!b.cd){r.ka.identity(this.ya);r.ka.rotate(this.ya,-d.V.m*Math.PI/180,[0,0,1]);r.ka.rotate(this.ya,-d.A.m*Math.PI/180,[1,0,0]);r.ka.rotate(this.ya,(180-d.pan.m)*Math.PI/180,[0,1,0]);r.ka.rotate(this.ya,b.pan*Math.PI/180,[0,1,0]);r.ka.rotate(this.ya,-b.A*Math.PI/180,[1,0,0]);r.ka.translate(this.ya,
[0,0,1]);r.ka.rotate(this.ya,b.lb*Math.PI/180,[0,0,1]);r.ka.rotate(this.ya,-b.La*Math.PI/180,[0,1,0]);r.ka.rotate(this.ya,b.Ga*Math.PI/180,[1,0,0]);var e=Math.tan(b.fov/2*Math.PI/180),f=b.aspect;f||(f=16/9);r.ka.scale(this.ya,[e,e/f,1]);r.ka.translate(this.ya,[0,0,-1]);c.bindBuffer(c.ARRAY_BUFFER,this.Gj);c.vertexAttribPointer(this.P.ja,3,c.FLOAT,!1,0,0);c.bindBuffer(c.ARRAY_BUFFER,this.ze);c.vertexAttribPointer(this.P.Ma,2,c.FLOAT,!1,0,0);c.activeTexture(c.TEXTURE0);c.bindTexture(c.TEXTURE_2D,b.texture);
c.texParameteri(c.TEXTURE_2D,c.TEXTURE_MAG_FILTER,c.LINEAR);c.texParameteri(c.TEXTURE_2D,c.TEXTURE_MIN_FILTER,c.LINEAR);c.texParameteri(c.TEXTURE_2D,c.TEXTURE_WRAP_S,c.CLAMP_TO_EDGE);c.texParameteri(c.TEXTURE_2D,c.TEXTURE_WRAP_T,c.CLAMP_TO_EDGE);c.bindBuffer(c.ELEMENT_ARRAY_BUFFER,this.md);c.uniform1i(this.P.Tf,0);c.uniformMatrix4fv(this.P.jh,!1,this.ya);c.uniformMatrix4fv(this.P.ee,!1,this.Ab);c.drawElements(c.TRIANGLES,6,c.UNSIGNED_SHORT,0)}}c.enable(c.DEPTH_TEST)}};m.prototype.js=function(){var d=
this.u,c;if(d.D.width!=d.L.offsetWidth||d.D.height!=d.L.offsetHeight)d.D.width=d.L.offsetWidth,d.D.height=d.L.offsetHeight;d.Ee&&(d.ad(0),d.Pc());if(d.S){var a=d.S;a.useProgram(this.P);r.ka.identity(this.Ab);r.ka.perspective(d.Tb(),d.zb.width/d.zb.height,.1,100,this.Ab);a.uniformMatrix4fv(this.P.ee,!1,this.Ab);this.Xf(0);a.uniform1i(this.P.Tf,0);a.uniformMatrix4fv(this.P.ee,!1,this.Ab);a.uniformMatrix4fv(this.P.jh,!1,this.ya);a.enableVertexAttribArray(this.P.ja);a.enableVertexAttribArray(this.P.Ma);
a.bindBuffer(a.ARRAY_BUFFER,this.ze);a.vertexAttribPointer(this.P.Ma,2,a.FLOAT,!1,0,0);a.activeTexture(a.TEXTURE0);a.bindBuffer(a.ELEMENT_ARRAY_BUFFER,this.md);a.uniform1f(this.P.oj,1E-4);a.vertexAttribPointer(this.P.ja,3,a.FLOAT,!1,0,0);a.bindTexture(a.TEXTURE_2D,d.F.texture);for(c=0;1>c;c++)this.Xf(0),a.bindBuffer(a.ARRAY_BUFFER,d.F.Zk),a.vertexAttribPointer(this.P.ja,3,a.FLOAT,!1,0,0),a.bindBuffer(a.ARRAY_BUFFER,d.F.aj),a.vertexAttribPointer(this.P.Ma,2,a.FLOAT,!1,0,0),a.activeTexture(a.TEXTURE0),
a.bindBuffer(a.ELEMENT_ARRAY_BUFFER,d.F.fk),a.uniform1i(this.P.Tf,0),a.uniformMatrix4fv(this.P.jh,!1,this.ya),a.uniformMatrix4fv(this.P.ee,!1,this.Ab),a.drawElements(a.TRIANGLES,36,a.UNSIGNED_SHORT,0)}};m.prototype.hs=function(){var d=this.u,c=d.S,a=d.F;if(0<d.T.length)for(var b=0;b<d.T.length;b++){var e=d.T[b];if(!e.cd&&e.isRunning&&e.ji!=e.j.currentTime&&(e.ji=e.j.currentTime,!e.aspect&&0<e.j.videoHeight&&(e.aspect=e.j.videoWidth/e.j.videoHeight),d.Hh))try{e.texture&&(c.bindTexture(c.TEXTURE_2D,
e.texture),c.texImage2D(c.TEXTURE_2D,0,c.RGB,c.RGB,c.UNSIGNED_BYTE,e.j),d.update())}catch(g){d.O(g)}}if(a.j&&(b=Number(a.j.currentTime),a.ji!=b)){a.ji=b;try{var f=0<a.j.readyState;d.si&&a.td&&(f=f&&0<a.j.currentTime);a.texture&&a.ui&&f&&(a.td=!0,a.width=a.j.videoWidth,a.height=a.j.videoHeight,c.pixelStorei(c.UNPACK_FLIP_Y_WEBGL,d.F.flipY),c.bindTexture(c.TEXTURE_2D,a.texture),c.texImage2D(c.TEXTURE_2D,0,c.RGB,c.RGB,c.UNSIGNED_BYTE,a.j),a.Jn=!0,d.update())}catch(g){d.O(g)}}};m.prototype.Xm=function(){var d,
c,a=this.u,b=this.u.S;a.Ja.style.visibility="hidden";a.I.Vg!=a.I.mode&&(a.I.Vg=a.I.mode);if((0<=a.I.mode||0<a.I.ub.length)&&!a.K.Bh){var e=1;0>=a.I.mode&&(e=0);3==a.I.mode&&(e=a.I.Ba);for(d=0;d<a.X.length;d++){var f=a.X[d];if("poly"==f.type){var g=f.ge,h=e;2==a.I.mode&&(h=f.Ba);var l=a.I.ub.indexOf(f.id);-1!=l&&(h=a.I.Zb[l]);if(0<g.length){l=[];for(c=0;c<g.length;c++)l.push(g[c].Xb),l.push(g[c].Cb),l.push(0);b.useProgram(this.Md);b.enable(b.BLEND);b.blendFuncSeparate(b.SRC_ALPHA,b.ONE_MINUS_SRC_ALPHA,
b.SRC_ALPHA,b.ONE);b.disable(b.DEPTH_TEST);g=b.createBuffer();b.bindBuffer(b.ARRAY_BUFFER,g);b.bufferData(b.ARRAY_BUFFER,new Float32Array(l),b.STATIC_DRAW);b.uniform2f(b.getUniformLocation(this.Md,"uCanvasDimensions"),a.D.width,a.D.height);g=b.getUniformLocation(this.Md,"uColor");c=f.ec;b.uniform3f(g,(c>>16&255)/255,(c>>8&255)/255,(c&255)/255);var k=b.getUniformLocation(this.Md,"uAlpha");b.uniform1f(k,f.dc*h);b.vertexAttribPointer(this.Md.ja,3,b.FLOAT,!1,0,0);b.drawArrays(b.LINE_LOOP,0,l.length/3);
c=f.cc;b.uniform3f(g,(c>>16&255)/255,(c>>8&255)/255,(c&255)/255);b.uniform1f(k,f.bc*h);b.enable(b.STENCIL_TEST);b.clearStencil(0);b.clear(b.STENCIL_BUFFER_BIT);b.colorMask(!1,!1,!1,!1);b.stencilFunc(b.ALWAYS,1,1);b.stencilOp(b.INCR,b.INCR,b.INCR);b.drawArrays(b.TRIANGLE_FAN,0,l.length/3);b.colorMask(!0,!0,!0,!0);b.stencilFunc(b.EQUAL,1,1);b.stencilOp(b.ZERO,b.ZERO,b.ZERO);b.drawArrays(b.TRIANGLE_FAN,0,l.length/3);b.disable(b.BLEND);b.enable(b.DEPTH_TEST);b.disable(b.STENCIL_TEST);b.useProgram(this.P)}}}}};
m.prototype.Tk=function(){var d=this.u,c=d.v;if(d.D.width!=d.L.offsetWidth||d.D.height!=d.L.offsetHeight)d.D.width=d.L.offsetWidth,d.D.height=d.L.offsetHeight;d.Ee&&(d.ad(0),d.Pc());if(d.S){var a=d.S;this.ij();a.clear(a.COLOR_BUFFER_BIT|a.DEPTH_BUFFER_BIT);a.disable(a.DEPTH_TEST);a.disable(a.CULL_FACE);a.useProgram(this.zg);var b=a.getUniformLocation(this.zg,"uRect");a.uniform2f(a.getUniformLocation(this.zg,"uCanvasDimensions"),d.D.width,d.D.height);a.activeTexture(a.TEXTURE0);a.bindBuffer(a.ELEMENT_ARRAY_BUFFER,
this.md);var e=a.getAttribLocation(this.zg,"aVertexPosition");a.disableVertexAttribArray(0);a.disableVertexAttribArray(1);a.disableVertexAttribArray(2);a.enableVertexAttribArray(e);a.bindBuffer(a.ARRAY_BUFFER,this.ze);a.vertexAttribPointer(e,2,a.FLOAT,!1,0,0);d.Cc=0;var f=100/d.fov.m;var g=c.width/c.height;e=d.D.height*f*g;f*=d.D.height;g=(d.pan.m/100/g-.5)*e+d.D.width/2;for(var h=(d.A.m/100-.5)*f+d.D.height/2,l,k,q,p=0;c.levels.length>=p+2&&c.levels[p+1].width>e;)p++;var w;var x=[];for(w=c.levels.length-
1;w>=p;){var y=c.levels[w];if(y.cache){var z={jb:0,Gb:0};z.Ib=y.U-1;z.Jb=y.ea-1}else{z={};l=-h/f*(y.height/d.v.N);k=(-g+d.D.width)/e*(y.width/d.v.N);var fa=(-h+d.D.height)/f*(y.height/d.v.N);z.jb=Math.min(Math.max(0,Math.floor(-g/e*(y.width/d.v.N))),y.U-1);z.Gb=Math.min(Math.max(0,Math.floor(l)),y.ea-1);z.Ib=Math.min(Math.max(0,Math.floor(k)),y.U-1);z.Jb=Math.min(Math.max(0,Math.floor(fa)),y.ea-1)}x[w]=z;var la=!0;for(k=z.Gb;k<=z.Jb;k++)for(l=z.jb;l<=z.Ib;l++)q=l+k*y.U,fa=y.ba[q],fa||(fa=new r.Sd,
y.ba[q]=fa),this.ai()?fa.v||(this.Ai(fa,y,d.ne(0,w,l,k)),d.Na=!0):this.u.Cc++,fa.v&&fa.v.complete||(la=!1),fa.visible=!0;z.lk=la;w--}for(w=c.levels.length-1;w>=p;){y=c.levels[w];if(x[w]&&0<=x[w].jb)for(z=x[w],k=z.Gb;k<=z.Jb;k++)for(l=z.jb;l<=z.Ib;l++)q=l+k*y.U,(fa=y.ba[q])&&fa.v&&fa.v.complete&&(d=g+(-c.Ea+c.N*l)*e/y.width,a.uniform4f(b,d,h+(-c.Ea+c.N*k)*f/y.height,fa.v.width*e/y.width,fa.v.height*f/y.height),fa&&fa.rb&&(a.bindBuffer(a.ELEMENT_ARRAY_BUFFER,this.md),a.bindTexture(a.TEXTURE_2D,fa.rb),
a.texParameteri(a.TEXTURE_2D,a.TEXTURE_MAG_FILTER,a.LINEAR),a.texParameteri(a.TEXTURE_2D,a.TEXTURE_MIN_FILTER,a.LINEAR),a.texParameteri(a.TEXTURE_2D,a.TEXTURE_WRAP_S,a.CLAMP_TO_EDGE),a.texParameteri(a.TEXTURE_2D,a.TEXTURE_WRAP_T,a.CLAMP_TO_EDGE),a.drawElements(a.TRIANGLES,6,a.UNSIGNED_SHORT,0)));w--}this.Ck()}};m.prototype.je=function(){var d=this.u.S;if(d&&this.ib)for(;0<this.ib.length;){var c=this.ib.pop();c.Cq=!0;d.deleteTexture(c)}this.Hc&&(d.deleteTexture(this.Hc),this.Hc=null);this.pf=1E6;this.Xh=
[!1,!1,!1,!1,!1,!1]};return m}();r.so=n})(ggP2VR||(ggP2VR={}));
(function(r){var n=function(){return function(){this.Mf={Bg:1,Cg:1,dh:0,eh:0,fg:0,Kh:0,scale:1};this.qb=!0;this.bounds=[]}}(),m=function(){function d(){var c;this.faces=Array(6);for(c=0;6>c;c++)this.faces[c]=new n}d.prototype.Ro=function(c,a,b,e){for(var f=0;6>f;f++){var g;if(g=this.faces[f]){var h=[];h.push(new r.Ha(-1,-1,-1,0,0));h.push(new r.Ha(1,-1,-1,1,0));h.push(new r.Ha(1,1,-1,1,1));h.push(new r.Ha(-1,1,-1,0,1));for(var l=0;l<h.length;l++)4>f?h[l].La(-Math.PI/2*f):h[l].Ga(Math.PI/2*(4===f?
-1:1)),e&&(h[l].lb(e.V*Math.PI/180),h[l].Ga(-e.pitch*Math.PI/180)),h[l].La(-c*Math.PI/180),h[l].Ga(a*Math.PI/180),h[l].lb(b*Math.PI/180);g.qb=0<h.length}}};return d}();r.oo=m})(ggP2VR||(ggP2VR={}));
(function(r){r.no=function(){return function(){this.levels=[];this.Pf="0x000000";this.an=!1;this.Mm=this.Lm=.4;this.N=512;this.Ea=1;this.kk=0;this.mk="";this.kn=this.height=this.width=0}}();r.el=function(){return function(){this.height=this.width=0;this.Se=this.cache=!1;this.ea=this.U=0;this.loaded=!1;this.ba=[]}}();r.Sd=function(){return function(){this.loaded=this.visible=!1;this.ie=this.Bk=0;this.rd=[];this.ki=0;this.Je=[];this.vi=this.Xg=this.Fd=0}}()})(ggP2VR||(ggP2VR={}));
(function(r){r.jo=function(){return function(n,m){this.u=n;this.Da=m;var d=this.__div=document.createElement("div");var c=document.createElement("img");if(m.Wc){var a=m.Wc;c.setAttribute("style","position: absolute;width: "+m.Ae+"px; height: "+m.Bd+"px;top: -"+m.Bd/2+"px;left: -"+m.Ae/2+"px; "+n.Pa+"user-select: none; max-width: none;")}else a="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAA5xJREFUeNqclmlIVFEUx997TjrplFQW2WKBBSYtRFlpWUILSSsRZRQIBdGHCFqIoKIvQRsUFRJC9LEgaSFbMMpcWi1pLzOLsjItKms0U5t5/c/wH7nc5o2jF374xrv87z33nHOPaRsRtbFgDpgJxoD+wATfwDNQDK6CyrCr5OcbhgiGIRsUAZt4QTWoIFXgp9JfAhY7rgdBl8NeBoLDYBloA+dBOagFTcDHcVEgDgwBGWA+OAcugvXgvb5wKMGJoAAMp9BpUA96EBf/Btsf8BI8AWfAErAcpHHDZeriliY2AVwDg8AucAQ0Ag+I4XhTm2Oxz8PT46KMbTx5EZjuJDgAnAVusJUm9DhYwalFcc59sIXXIaceFkowDySBPTRPL20xm+b7zYXa+N3CPrWJ6GuwGySA40HLBHc/GywFhbS5R1lEBrZy7FQwiSaX9pmnqeAYt+KUcew7BVZw/QKTq0ocpYPVvDOXItZCk2xgDIZqL8BR8Ab0VDbr4yZOgLeIwzQx6WiQxcCt1+6sld66L4yYtFSwF4yg2dU7/cEwGW9YVkAwmycp1dzdpvgm0DcCh4kHmxWzBls0uBX4qqmZJ4KzePm1IeJLgjmlC16aDKZpp5Q168B3o6wsSwTHgU+MIUs74RSj6y1d+212HKimJlUE+tFRfJpYtOKNXWmJTASqWf2Bu/R6+4TKHOrOzG4IhptjWgHbGkZvepQ6SQK7oRuCXzjX1DJavBEX1ygfT8FgBqpfm1zRDcEKbR2bsZlkJCdXieB1ZhZ5YtqVgXIPN+m9kbY6hpdb+d9fPncJRmZmqQheZkemJmgxyxykl3XWJEkcAl7N21s7PDcl5ZJ0PAa3wVwmWtVbZafPwQ7wLozYB7ATPNJO56d/LAikP9u+66KNJS1d4IOZp7wU0hfLukUyzgwm70T2N/DOxIy/eFdqawa5DL2NEGwP5k15Ja4woz9glvcomd9NzyvkFcQo5gomaLfm5c0svnKZ2k7q7+FauvR2MJKZR3+sY5WgtvkdG6JyELGhNHMTXyGfLviRJ5Tcd4Dlhle7086Sgp8CqVxDkn4OqHaqacr5ekjy3Q/W0FRNNGmoMtamdzdxsytZC0lqXKhEgWPVVgImg2NgFT1MHOoOk3yLEtgWN5TEOYvoIFI1rGM19//2wpAD7imF7lfwENwAxaASNCj90pcLLKdC2Iyw1M9gnEplMEp5kOU1f8WwKGJm8oUr9f8JMAAVMDM6HSDa9QAAAABJRU5ErkJggg%3D%3D",
c.setAttribute("style","position: absolute;width: 28px; height: 28px;top: -14px;left: -14px; "+n.Pa+"user-select: none; max-width: none;");c.setAttribute("src",a);c.ondragstart=function(){return!1};d.appendChild(c);a="position:absolute;"+(n.Pa+"user-select: none;");a+=n.Pa+"touch-callout: none;";a+=n.Pa+"tap-highlight-color: rgba(0,0,0,0);";n.yc&&!n.ia&&(a+=n.Pa+"transform: translateZ(9999999px);");d.setAttribute("style",a);d.onclick=function(){n.Uf(m);n.uk(m.url,m.target);n.la&&n.la.hotspotProxyClick&&
n.la.hotspotProxyClick(m.id,m.url)};d.ondblclick=function(){n.la&&n.la.hotspotProxyDoubleClick&&n.la.hotspotProxyDoubleClick(m.id,m.url)};var b=n.I.cj;if(b.enabled&&""!=m.title){var e=document.createElement("div");a="position:absolute;";a=m.Wc?a+("top:\t "+m.Bd/2+"px;"):a+"top:\t 20px;";a=b.nj?a+"white-space: pre-wrap;":a+"white-space: nowrap;";a+=n.Pa+"transform-origin: 50% 50%;";e.setAttribute("style",a+"visibility: hidden;overflow: hidden;padding: 0px 1px 0px 1px;");e.style.color=this.u.fa(b.dj,
b.bj);e.style.backgroundColor=b.background?this.u.fa(b.cc,b.bc):"transparent";e.style.border="solid "+this.u.fa(b.ec,b.dc)+" "+b.Uh+"px";e.style.borderRadius=b.tj+"px";e.style.textAlign="center";0<b.width?(e.style.left=-b.width/2+"px",e.style.width=b.width+"px"):e.style.width="auto";e.style.height=0<b.height?b.height+"px":"auto";e.style.overflow="hidden";e.innerHTML=m.title;e.classList.add("ggskin");e.classList.add("ggdefaulthotspot");d.onmouseover=function(){0==b.width&&(e.style.left=-e.offsetWidth/
2+"px");e.style.visibility="inherit";n.la&&n.la.hotspotProxyOver&&n.la.hotspotProxyOver(m.id,m.url)};d.onmouseout=function(){e.style.visibility="hidden";n.la&&n.la.hotspotProxyOut&&n.la.hotspotProxyOut(m.id,m.url)};d.appendChild(e)}}}()})(ggP2VR||(ggP2VR={}));
(function(r){r.Uc=function(){return function(){this.value=this.time=0;this.Yk="";this.ye=this.xe=this.we=this.ve=this.tb=this.type=this.Eb=0;this.Qh=""}}();r.bl=function(){return function(){this.$r=this.Bo=this.length=0}}();r.al=function(){return function(){}}()})(ggP2VR||(ggP2VR={}));
(function(r){var n=function(){function m(d){this.u=d;this.enabled=!1;this.lg=1;this.lf=0;this.type="crossdissolve";this.sc=this.sa=this.Oc=0;this.gg=5;this.te=1;this.hg=!1;this.af=this.$e=this.Nk=0;this.Rd=70;this.ho=0;this.Fb=this.fo=1;this.Nh=this.Mh=.5;this.ue=!1;this.Jj=1}m.prototype.Pg=function(){var d=this.u.S,c=d.createShader(d.VERTEX_SHADER);d.shaderSource(c,"attribute vec3 aVertexPosition;\nattribute vec2 aTextureCoord;\nvarying vec2 vTextureCoord;\nuniform bool uZoomIn;\nuniform float uZoomFactor;\nuniform vec2 uZoomCenter;\nvoid main(void) {\n\t gl_Position = vec4(aVertexPosition, 1.0);\n\t if(!uZoomIn) {\n\t \n\t   vTextureCoord = aTextureCoord;\n\t }\n\t else {\n\t   vTextureCoord = (aTextureCoord - vec2(0.5, 0.5)) * (1.0/uZoomFactor) + uZoomCenter;\n\t }\n}\n");
d.compileShader(c);d.getShaderParameter(c,d.COMPILE_STATUS)||(alert(d.getShaderInfoLog(c)),c=null);var a=d.createShader(d.FRAGMENT_SHADER);d.shaderSource(a,"#ifdef GL_FRAGMENT_PRECISION_HIGH\nprecision highp float;\n#else\nprecision mediump float;\n#endif\nvarying vec2 vTextureCoord;\nuniform float uAlpha;\nuniform sampler2D uSampler;\nvoid main(void) {\n vec4 textureColor = texture2D(uSampler, vec2(vTextureCoord.s, vTextureCoord.t));\n gl_FragColor = vec4(textureColor.x, textureColor.y, textureColor.z, uAlpha);\n}\n");
d.compileShader(a);d.getShaderParameter(a,d.COMPILE_STATUS)||(alert(d.getShaderInfoLog(a)),a=null);this.Aa=d.createProgram();d.attachShader(this.Aa,c);d.attachShader(this.Aa,a);d.linkProgram(this.Aa);d.getProgramParameter(this.Aa,d.LINK_STATUS)||alert("Could not initialise shaders");this.Aa.ja=d.getAttribLocation(this.Aa,"aVertexPosition");d.enableVertexAttribArray(this.Aa.ja);this.Aa.Ma=d.getAttribLocation(this.Aa,"aTextureCoord");d.enableVertexAttribArray(this.Aa.Ma);a=d.createShader(d.FRAGMENT_SHADER);
d.shaderSource(a,"#ifdef GL_FRAGMENT_PRECISION_HIGH\nprecision highp float;\n#else\nprecision mediump float;\n#endif\nvarying vec2 vTextureCoord;\nuniform float uColorPercent;\nuniform float uAlpha;\nuniform vec3 uDipColor;\nuniform sampler2D uSampler;\nvoid main(void) {\n vec4 textureColor = texture2D(uSampler, vec2(vTextureCoord.s, vTextureCoord.t));\n gl_FragColor = vec4(textureColor.x * (1.0 - uColorPercent) + uDipColor.x * uColorPercent, textureColor.y * (1.0 - uColorPercent) + uDipColor.y * uColorPercent, textureColor.z * (1.0 - uColorPercent) + uDipColor.z * uColorPercent, uAlpha);\n}\n");
d.compileShader(a);d.getShaderParameter(a,d.COMPILE_STATUS)||(alert(d.getShaderInfoLog(a)),a=null);this.gb=d.createProgram();d.attachShader(this.gb,c);d.attachShader(this.gb,a);d.linkProgram(this.gb);d.getProgramParameter(this.gb,d.LINK_STATUS)||alert("Could not initialise shaders");this.gb.ja=d.getAttribLocation(this.gb,"aVertexPosition");d.enableVertexAttribArray(this.gb.ja);this.gb.Ma=d.getAttribLocation(this.gb,"aTextureCoord");d.enableVertexAttribArray(this.gb.Ma);a=d.createShader(d.FRAGMENT_SHADER);
d.shaderSource(a,"#ifdef GL_FRAGMENT_PRECISION_HIGH\nprecision highp float;\n#else\nprecision mediump float;\n#endif\nvarying vec2 vTextureCoord;\nuniform bool uRound;\nuniform float uRadius;\nuniform vec2 uRectDim;\nuniform vec2 uIrisCenter;\nuniform float uSoftEdge;\nuniform sampler2D uSampler;\nvoid main(void) {\n float alpha = 0.0;\n vec4 textureColor = texture2D(uSampler, vec2(vTextureCoord.s, vTextureCoord.t));\n if (uRound) {\n\t  vec2 diff = uIrisCenter - gl_FragCoord.xy;\n\t   float distFromCenter = sqrt( (diff.x * diff.x) + (diff.y * diff.y) );\n\t   if (distFromCenter > uRadius) {\n      alpha = 1.0;\n    } else {\n      alpha = 1.0 - ((uRadius - distFromCenter) / uSoftEdge);\n    };\n }\n else {\n    float alphaFromLeft = 1.0 - ((gl_FragCoord.x -(uIrisCenter.x - uRectDim.x)) / uSoftEdge);\n    float alphaFromRight = 1.0 - (((uIrisCenter.x + uRectDim.x) - gl_FragCoord.x) / uSoftEdge);\n    float alphaFromTop = 1.0 - ((gl_FragCoord.y -(uIrisCenter.y - uRectDim.y)) / uSoftEdge);\n    float alphaFromBottom = 1.0 - (((uIrisCenter.y + uRectDim.y) - gl_FragCoord.y) / uSoftEdge);\n    alpha = max(max(alphaFromLeft, alphaFromRight), max(alphaFromTop, alphaFromBottom));\n }\n gl_FragColor = vec4(textureColor.x, textureColor.y, textureColor.z, alpha);\n}\n");
d.compileShader(a);d.getShaderParameter(a,d.COMPILE_STATUS)||(alert(d.getShaderInfoLog(a)),a=null);this.Ua=d.createProgram();d.attachShader(this.Ua,c);d.attachShader(this.Ua,a);d.linkProgram(this.Ua);d.getProgramParameter(this.Ua,d.LINK_STATUS)||alert("Could not initialise shaders");this.Ua.ja=d.getAttribLocation(this.Ua,"aVertexPosition");d.enableVertexAttribArray(this.Ua.ja);this.Ua.Ma=d.getAttribLocation(this.Ua,"aTextureCoord");d.enableVertexAttribArray(this.Ua.Ma);a=d.createShader(d.FRAGMENT_SHADER);
d.shaderSource(a,"#ifdef GL_FRAGMENT_PRECISION_HIGH\nprecision highp float;\n#else\nprecision mediump float;\n#endif\nvarying vec2 vTextureCoord;\nuniform float uPercent;\nuniform int uDirection;\nuniform vec2 uCanvasDimensions;\nuniform float uSoftEdge;\nuniform sampler2D uSampler;\nvoid main(void) {\n vec4 textureColor = texture2D(uSampler, vec2(vTextureCoord.s, vTextureCoord.t));\n float alpha = 0.0;\n if (uDirection == 1) {\n\t if (gl_FragCoord.x > uPercent) {\n    alpha = 1.0; \n  } else {\n    alpha = 1.0 - ((uPercent - gl_FragCoord.x) / uSoftEdge);\n  }\n }\n if (uDirection == 2) {\n\t if (gl_FragCoord.x < uCanvasDimensions.x - uPercent) {\n    alpha = 1.0; \n  } else {\n    alpha = 1.0 - ((gl_FragCoord.x - (uCanvasDimensions.x - uPercent)) / uSoftEdge);\n  }\n }\n if (uDirection == 3) {\n\t if (gl_FragCoord.y < uCanvasDimensions.y - uPercent) {\n    alpha = 1.0; \n  } else {\n    alpha = 1.0 - ((gl_FragCoord.y - (uCanvasDimensions.y - uPercent)) / uSoftEdge);\n  }\n }\n if (uDirection == 4) {\n\t if (gl_FragCoord.y > uPercent) {\n    alpha = 1.0; \n  } else {\n    alpha = 1.0 - ((uPercent - gl_FragCoord.y) / uSoftEdge);\n  }\n }\n gl_FragColor = vec4(textureColor.x, textureColor.y, textureColor.z, alpha);\n}\n");
d.compileShader(a);d.getShaderParameter(a,d.COMPILE_STATUS)||(alert(d.getShaderInfoLog(a)),a=null);this.$a=d.createProgram();d.attachShader(this.$a,c);d.attachShader(this.$a,a);d.linkProgram(this.$a);d.getProgramParameter(this.$a,d.LINK_STATUS)||alert("Could not initialise shaders");this.$a.ja=d.getAttribLocation(this.$a,"aVertexPosition");d.enableVertexAttribArray(this.$a.ja);this.$a.Ma=d.getAttribLocation(this.$a,"aTextureCoord");d.enableVertexAttribArray(this.$a.Ma)};m.prototype.ad=function(){var d=
this.u.S;if(!d)return!1;if(this.rc=d.createFramebuffer()){d.bindFramebuffer(d.FRAMEBUFFER,this.rc);this.rc.width=1024;this.rc.height=1024;this.cf=d.createTexture();d.bindTexture(d.TEXTURE_2D,this.cf);d.texParameteri(d.TEXTURE_2D,d.TEXTURE_MIN_FILTER,d.LINEAR);d.texParameteri(d.TEXTURE_2D,d.TEXTURE_MAG_FILTER,d.LINEAR);d.texImage2D(d.TEXTURE_2D,0,d.RGBA,this.rc.width,this.rc.height,0,d.RGBA,d.UNSIGNED_BYTE,null);var c=d.createRenderbuffer();d.bindRenderbuffer(d.RENDERBUFFER,c);d.renderbufferStorage(d.RENDERBUFFER,
d.DEPTH_COMPONENT16,this.rc.width,this.rc.height);d.framebufferTexture2D(d.FRAMEBUFFER,d.COLOR_ATTACHMENT0,d.TEXTURE_2D,this.cf,0);d.framebufferRenderbuffer(d.FRAMEBUFFER,d.DEPTH_ATTACHMENT,d.RENDERBUFFER,c);d.bindTexture(d.TEXTURE_2D,null);d.bindRenderbuffer(d.RENDERBUFFER,null);d.bindFramebuffer(d.FRAMEBUFFER,null);this.sb=d.createBuffer();d.bindBuffer(d.ARRAY_BUFFER,this.sb);d.bufferData(d.ARRAY_BUFFER,new Float32Array([-1,-1,0,1,-1,0,-1,1,0,1,1,0]),d.STATIC_DRAW);this.sb.itemSize=3;this.sb.de=
4;this.Qf=d.createBuffer();d.bindBuffer(d.ARRAY_BUFFER,this.Qf);d.bufferData(d.ARRAY_BUFFER,new Float32Array([0,0,1,0,0,1,1,1]),d.STATIC_DRAW);return!0}return!1};m.prototype.Ym=function(d){var c=this.u.S,a=this.u.zb;if(this.xd){c.useProgram(this.Aa);c.bindBuffer(c.ARRAY_BUFFER,this.sb);c.vertexAttribPointer(this.Aa.ja,this.sb.itemSize,c.FLOAT,!1,0,0);c.bindBuffer(c.ARRAY_BUFFER,this.Qf);c.vertexAttribPointer(this.Aa.Ma,2,c.FLOAT,!1,0,0);c.enableVertexAttribArray(this.Aa.ja);c.enableVertexAttribArray(this.Aa.Ma);
c.activeTexture(c.TEXTURE0);c.bindTexture(c.TEXTURE_2D,this.cf);a=1+(this.Fb-1)*d;var b=c.getUniformLocation(this.Aa,"uAlpha");c.uniform1f(b,1);b=c.getUniformLocation(this.Aa,"uZoomIn");c.uniform1i(b,1);b=c.getUniformLocation(this.Aa,"uZoomCenter");var e=.5+(this.Mh-.5)*Math.sqrt(d),f=.5+(this.Nh-.5)*Math.sqrt(d);0>e-.5/a&&(e=.5/a);0>f-.5/a&&(f=.5/a);1<e+.5/a&&(e=1-.5/a);1<f+.5/a&&(f=1-.5/a);c.uniform2f(b,e,f);e=c.getUniformLocation(this.Aa,"uZoomFactor");c.uniform1f(e,a);c.uniform1i(c.getUniformLocation(this.Aa,
"uSampler"),0);c.drawArrays(c.TRIANGLE_STRIP,0,this.sb.de);c.useProgram(this.u.za.P)}else{this.u.Eh();c.blendFuncSeparate(c.SRC_ALPHA,c.ONE_MINUS_SRC_ALPHA,c.SRC_ALPHA,c.ONE);c.enable(c.BLEND);c.disable(c.DEPTH_TEST);e=.5+(this.Mh-.5);f=.5+(this.Nh-.5);0>e-.5/this.Fb&&(e=.5/this.Fb);0>f-.5/this.Fb&&(f=.5/this.Fb);1<e+.5/this.Fb&&(e=1-.5/this.Fb);1<f+.5/this.Fb&&(f=1-.5/this.Fb);if("crossdissolve"==this.type)c.useProgram(this.Aa),c.bindBuffer(c.ARRAY_BUFFER,this.sb),c.vertexAttribPointer(this.Aa.ja,
this.sb.itemSize,c.FLOAT,!1,0,0),c.bindBuffer(c.ARRAY_BUFFER,this.Qf),c.vertexAttribPointer(this.Aa.Ma,2,c.FLOAT,!1,0,0),c.activeTexture(c.TEXTURE0),c.bindTexture(c.TEXTURE_2D,this.cf),b=c.getUniformLocation(this.Aa,"uAlpha"),c.uniform1f(b,1-d),b=c.getUniformLocation(this.Aa,"uZoomIn"),c.uniform1i(b,1==this.sa||2==this.sa||6==this.sa?1:0),b=c.getUniformLocation(this.Aa,"uZoomCenter"),c.uniform2f(b,e,f),e=c.getUniformLocation(this.Aa,"uZoomFactor"),c.uniform1f(e,this.Fb),c.uniform1i(c.getUniformLocation(this.Aa,
"uSampler"),0);else if("diptocolor"==this.type)c.useProgram(this.gb),c.bindBuffer(c.ARRAY_BUFFER,this.sb),c.vertexAttribPointer(this.gb.ja,this.sb.itemSize,c.FLOAT,!1,0,0),c.bindBuffer(c.ARRAY_BUFFER,this.Qf),c.vertexAttribPointer(this.gb.Ma,2,c.FLOAT,!1,0,0),c.activeTexture(c.TEXTURE0),c.bindTexture(c.TEXTURE_2D,this.cf),c.uniform1f(c.getUniformLocation(this.gb,"uColorPercent"),Math.min(2*d,1)),b=c.getUniformLocation(this.gb,"uAlpha"),c.uniform1f(b,1-Math.max(2*(d-.5),0)),c.uniform3f(c.getUniformLocation(this.gb,
"uDipColor"),(this.lf>>16&255)/255,(this.lf>>8&255)/255,(this.lf&255)/255),b=c.getUniformLocation(this.gb,"uZoomIn"),c.uniform1i(b,1==this.sa||2==this.sa||6==this.sa?1:0),b=c.getUniformLocation(this.gb,"uZoomCenter"),c.uniform2f(b,e,f),e=c.getUniformLocation(this.gb,"uZoomFactor"),c.uniform1f(e,this.Fb),c.uniform1i(c.getUniformLocation(this.gb,"uSampler"),0);else if("irisround"==this.type||"irisroundcenter"==this.type||"irisrectangular"==this.type||"irisrectangularcenter"==this.type){c.useProgram(this.Ua);
c.bindBuffer(c.ARRAY_BUFFER,this.sb);c.vertexAttribPointer(this.Ua.ja,this.sb.itemSize,c.FLOAT,!1,0,0);c.bindBuffer(c.ARRAY_BUFFER,this.Qf);c.vertexAttribPointer(this.Ua.Ma,2,c.FLOAT,!1,0,0);c.activeTexture(c.TEXTURE0);c.bindTexture(c.TEXTURE_2D,this.cf);if(1==this.sa||2==this.sa||6==this.sa||"irisroundcenter"==this.type||"irisrectangularcenter"==this.type)var g=b=.5;else b=this.Mh,g=this.Nh;var h=b*a.width,l=g*a.height;h=Math.max(h,a.width-h);l=Math.max(l,a.height-l);"irisround"==this.type||"irisroundcenter"==
this.type?c.uniform1f(c.getUniformLocation(this.Ua,"uRadius"),(Math.sqrt(h*h+l*l)+this.Oc)*d):(h>l?(l=a.height/a.width*h+this.Oc,h+=this.Oc):(h=a.width/a.height*l+this.Oc,l+=this.Oc),c.uniform2f(c.getUniformLocation(this.Ua,"uRectDim"),h*d,l*d));d=c.getUniformLocation(this.Ua,"uSoftEdge");c.uniform1f(d,this.Oc);c.uniform1i(c.getUniformLocation(this.Ua,"uRound"),"irisround"==this.type||"irisroundcenter"==this.type?1:0);c.uniform2f(c.getUniformLocation(this.Ua,"uIrisCenter"),b*a.width,g*a.height);b=
c.getUniformLocation(this.Ua,"uZoomIn");c.uniform1i(b,1==this.sa||2==this.sa||6==this.sa?1:0);b=c.getUniformLocation(this.Ua,"uZoomCenter");c.uniform2f(b,e,f);e=c.getUniformLocation(this.Ua,"uZoomFactor");c.uniform1f(e,this.Fb);c.uniform1i(c.getUniformLocation(this.Ua,"uSampler"),0)}else if("wipeleftright"==this.type||"wiperightleft"==this.type||"wipetopbottom"==this.type||"wipebottomtop"==this.type||"wiperandom"==this.type)c.useProgram(this.$a),c.bindBuffer(c.ARRAY_BUFFER,this.sb),c.vertexAttribPointer(this.$a.ja,
this.sb.itemSize,c.FLOAT,!1,0,0),c.bindBuffer(c.ARRAY_BUFFER,this.Qf),c.vertexAttribPointer(this.$a.Ma,2,c.FLOAT,!1,0,0),c.activeTexture(c.TEXTURE0),c.bindTexture(c.TEXTURE_2D,this.cf),c.uniform1f(c.getUniformLocation(this.$a,"uPercent"),3>this.Jj?d*(a.width+this.Oc):d*(a.height+this.Oc)),d=c.getUniformLocation(this.$a,"uSoftEdge"),c.uniform1f(d,this.Oc),c.uniform1i(c.getUniformLocation(this.$a,"uDirection"),this.Jj),c.uniform2f(c.getUniformLocation(this.$a,"uCanvasDimensions"),a.width,a.height),
b=c.getUniformLocation(this.$a,"uZoomIn"),c.uniform1i(b,1==this.sa||2==this.sa||6==this.sa?1:0),b=c.getUniformLocation(this.$a,"uZoomCenter"),c.uniform2f(b,e,f),e=c.getUniformLocation(this.$a,"uZoomFactor"),c.uniform1f(e,this.Fb),c.uniform1i(c.getUniformLocation(this.$a,"uSampler"),0);c.drawArrays(c.TRIANGLE_STRIP,0,this.sb.de);c.useProgram(this.u.za.P);c.disable(c.BLEND);c.enable(c.DEPTH_TEST)}};return m}();r.lo=n})(ggP2VR||(ggP2VR={}));
(function(r){var n=function(){function m(d){this.Ch=[];this.u=d;this.enabled=!1;this.Eb=2;this.yl=!1}m.prototype.Il=function(d){if(2==d.mode||3==d.mode||5==d.mode){var c=this.u.wa.currentTime;if(d.Hb&&d.Hb.gain&&d.Sb&&d.Qb&&d.Rb){var a=d.Sb.gain.value,b=d.Qb.gain.value,e=d.Rb.gain.value;d.Hb.gain.linearRampToValueAtTime(d.Hb.gain.value,c);d.Hb.gain.linearRampToValueAtTime(0,c+this.Eb);d.Sb.gain.linearRampToValueAtTime(a,c);d.Sb.gain.linearRampToValueAtTime(0,c+this.Eb);d.Qb.gain.linearRampToValueAtTime(b,
c);d.Qb.gain.linearRampToValueAtTime(0,c+this.Eb);d.Rb.gain.linearRampToValueAtTime(e,c);d.Rb.gain.linearRampToValueAtTime(0,c+this.Eb)}}else c=this.u.wa.currentTime,d.ic&&d.ic.gain&&(d.ic.gain.linearRampToValueAtTime(d.ic.gain.value,c),d.ic.gain.linearRampToValueAtTime(0,c+this.Eb));d.Pj=!0;setTimeout(function(){d.Te()},1E3*this.Eb+5)};m.prototype.Nr=function(){for(var d=0;d<this.u.Y.length;d++){var c=this.u.Y[d];-1==this.u.gd.indexOf(c.id)&&(-1==this.u.gd.indexOf("_main")||-1!=this.u.re.indexOf(c.id))&&
!this.u.isPlaying(c.id)&&-1<c.loop&&4!=c.mode&&6!=c.mode&&(c.va?c.Wd():(c.j.play(),c.j.currentTime=0))}};m.prototype.cp=function(){var d=(this.u.wa.currentTime-this.Jr)/this.Eb;d=Math.min(1,d);for(var c=0;c<this.u.Y.length;c++){var a=this.u.Y[c];this.u.isPlaying(a.id)&&1>a.ua&&(a.ua=d)}1==d&&clearInterval(this.Ir)};return m}();r.mo=n})(ggP2VR||(ggP2VR={}));
(function(r){var n=function(){function m(d){this.ah=[];this.kd=null;this.pc=[];this.hc=[];this.qc=[];this.Ik=!0;this.u=d;this.Vo()}m.prototype.Pg=function(){var d=this.u.S,c=d.createShader(d.VERTEX_SHADER);d.shaderSource(c,"attribute vec3 aVertexPosition;\nvoid main(void) {\n gl_Position = vec4(aVertexPosition, 1.0);\n}\n");d.compileShader(c);d.getShaderParameter(c,d.COMPILE_STATUS)||(alert(d.getShaderInfoLog(c)),c=null);var a=d.createShader(d.FRAGMENT_SHADER);d.shaderSource(a,"#ifdef GL_FRAGMENT_PRECISION_HIGH\nprecision highp float;\n#else\nprecision mediump float;\n#endif\nvarying vec4 vColor;\nuniform vec2 uCanvasDimensions;\nuniform vec2 uFlareCenterPosition;\nuniform float uBlindingValue;\nuniform float uAspectRatio;\nvoid main(void) {\n float canvasDiag = sqrt( (uCanvasDimensions.x * uCanvasDimensions.x) + (uCanvasDimensions.y * uCanvasDimensions.y) );\n vec2 diff = uFlareCenterPosition - gl_FragCoord.xy;\n diff.y = diff.y * uAspectRatio;\n float distFromFlarePoint = sqrt( (diff.x * diff.x) + (diff.y * diff.y) );\n float factor = (distFromFlarePoint / canvasDiag) / 10.0;\n gl_FragColor = vec4(1.0, 1.0, 1.0, pow(((1.0 - factor) * 0.8) * uBlindingValue, 2.0));\n}\n");
d.compileShader(a);d.getShaderParameter(a,d.COMPILE_STATUS)||(alert(d.getShaderInfoLog(a)),a=null);this.uc=d.createProgram();d.attachShader(this.uc,c);d.attachShader(this.uc,a);d.linkProgram(this.uc);d.getProgramParameter(this.uc,d.LINK_STATUS)||alert("Could not initialise shaders");this.uc.ja=d.getAttribLocation(this.uc,"aVertexPosition");d.enableVertexAttribArray(this.uc.ja);a=d.createShader(d.VERTEX_SHADER);c=d.createShader(d.VERTEX_SHADER);d.shaderSource(a,"#ifdef GL_FRAGMENT_PRECISION_HIGH\nprecision highp float;\n#else\nprecision mediump float;\n#endif\nattribute vec3 aVertexPosition;\nvarying vec4 vColor;\nuniform vec2 uCirclePosition;\nuniform float uCircleRadius;\nuniform vec2 uCanvasDimensions2;\nuniform float uAspectRatio;\nvoid main(void) {\n vec2 circleOnScreen = aVertexPosition.xy * uCircleRadius + uCirclePosition;\n circleOnScreen.y = circleOnScreen.y / uAspectRatio;\n vec2 circleNorm = (circleOnScreen / uCanvasDimensions2) * 2.0 - vec2(1.0, 1.0);\n gl_Position = vec4(circleNorm.x, circleNorm.y, 0.0, 1.0);\n}\n");
d.compileShader(a);d.getShaderParameter(a,d.COMPILE_STATUS)||(alert(d.getShaderInfoLog(a)),a=null);d.shaderSource(c,"#ifdef GL_FRAGMENT_PRECISION_HIGH\nprecision highp float;\n#else\nprecision mediump float;\n#endif\nattribute vec3 aVertexPosition;\nvarying vec4 vColor;\nuniform vec2 uCirclePosition;\nuniform float uCircleRadius;\nuniform vec2 uCanvasDimensions2;\nuniform float uAspectRatio;\nvoid main(void) {\n vec2 circleOnScreen = aVertexPosition.xy * uCircleRadius + uCirclePosition;\n circleOnScreen.y = circleOnScreen.y / uAspectRatio;\n vec2 circleNorm = (circleOnScreen / uCanvasDimensions2) * 2.0 - vec2(1.0, 1.0);\n gl_Position = vec4(circleNorm.x, circleNorm.y, 0.0, 1.0);\n}\n");
d.compileShader(c);d.getShaderParameter(c,d.COMPILE_STATUS)||(alert(d.getShaderInfoLog(c)),a=null);var b=d.createShader(d.FRAGMENT_SHADER);d.shaderSource(b,"#ifdef GL_FRAGMENT_PRECISION_HIGH\nprecision highp float;\n#else\nprecision mediump float;\n#endif\nvarying vec4 vColor;\nuniform vec2 uCircleTexturePosition;\nuniform vec3 uCircleColor;\nuniform float uCircleRadius;\nuniform float uCircleAlpha;\nuniform float uCircleSoftness;\nuniform float uAspectRatio;\nvoid main(void) {\n vec2 diff = uCircleTexturePosition - gl_FragCoord.xy;\n diff.y = diff.y * uAspectRatio;\n float distFromCircleCenter = sqrt( (diff.x * diff.x) + (diff.y * diff.y) );\n float softnessDistance = uCircleRadius * (1.0 - uCircleSoftness);\n if (distFromCircleCenter > uCircleRadius)\n {\n\t  gl_FragColor = vec4(uCircleColor, 0.0);\n }\n else if (distFromCircleCenter <= (softnessDistance))\n {\n\t  float factor = distFromCircleCenter / softnessDistance;\n\t  gl_FragColor = vec4(uCircleColor, pow((1.0 - (0.2 * factor)) * uCircleAlpha, 1.8));\n }\n else\n {\n\t  float factor = (distFromCircleCenter - softnessDistance) / (uCircleRadius - softnessDistance);\n\t  gl_FragColor = vec4(uCircleColor, pow((0.8 - (0.8 * factor)) * uCircleAlpha, 1.8));\n }\n}\n");
d.compileShader(b);d.getShaderParameter(b,d.COMPILE_STATUS)||(alert(d.getShaderInfoLog(b)),b=null);this.Ca=d.createProgram();d.attachShader(this.Ca,a);d.attachShader(this.Ca,b);d.linkProgram(this.Ca);d.getProgramParameter(this.Ca,d.LINK_STATUS)||alert("Could not initialise shaders");this.Ca.ja=d.getAttribLocation(this.Ca,"aVertexPosition");d.enableVertexAttribArray(this.Ca.ja);a=d.createShader(d.FRAGMENT_SHADER);d.shaderSource(a,"#ifdef GL_FRAGMENT_PRECISION_HIGH\nprecision highp float;\n#else\nprecision mediump float;\n#endif\nvarying vec4 vColor;\nuniform vec2 uRingTexturePosition;\nuniform float uRingRadius;\nuniform float uRingAlpha;\nuniform float uAspectRatio;\nuniform sampler2D uSampler;\nvoid main(void) {\n vec2 diff = uRingTexturePosition - gl_FragCoord.xy;\n diff.y = diff.y * uAspectRatio;\n float distFromRingCenter = sqrt( (diff.x * diff.x) + (diff.y * diff.y) );\n float factor = distFromRingCenter / uRingRadius;\n if (distFromRingCenter > uRingRadius)\n {\n\t gl_FragColor = vec4(1.0, 1.0, 1.0, 0.0);\n }\n else\n {\n vec4 textureColor = texture2D(uSampler, vec2(factor / uAspectRatio, 0.5));\n gl_FragColor = vec4(textureColor.x, textureColor.y, textureColor.z, uRingAlpha);\n }\n}\n");
d.compileShader(a);d.getShaderParameter(a,d.COMPILE_STATUS)||(alert(d.getShaderInfoLog(a)),a=null);this.Db=d.createProgram();d.attachShader(this.Db,c);d.attachShader(this.Db,a);d.linkProgram(this.Db);d.getProgramParameter(this.Db,d.LINK_STATUS)||alert("Could not initialise shaders");this.Db.ja=d.getAttribLocation(this.Db,"aVertexPosition")};m.prototype.ad=function(){var d=this.u.S;this.Dd=d.createBuffer();d.bindBuffer(d.ARRAY_BUFFER,this.Dd);d.bufferData(d.ARRAY_BUFFER,new Float32Array([-1,-1,0,1,
-1,0,1,1,0,-1,1,0]),d.STATIC_DRAW);this.Dd.itemSize=3;this.Dd.de=4;this.wf=d.createBuffer();d.bindBuffer(d.ARRAY_BUFFER,this.wf);for(var c=[0,0,0],a=2*Math.PI/6,b=Math.PI/180*35,e=1,f=b;f<=b+2*Math.PI;f+=a)c.push(Math.sin(f)),c.push(-Math.cos(f)),c.push(0),e++;d.bufferData(d.ARRAY_BUFFER,new Float32Array(c),d.STATIC_DRAW);this.wf.itemSize=3;this.wf.de=e;this.mn=d.createTexture();d.bindTexture(d.TEXTURE_2D,this.mn);d.texParameteri(d.TEXTURE_2D,d.TEXTURE_MIN_FILTER,d.LINEAR);d.texParameteri(d.TEXTURE_2D,
d.TEXTURE_MAG_FILTER,d.LINEAR);d.texParameteri(d.TEXTURE_2D,d.TEXTURE_WRAP_S,d.CLAMP_TO_EDGE);d.texParameteri(d.TEXTURE_2D,d.TEXTURE_WRAP_T,d.CLAMP_TO_EDGE);c=document.createElement("canvas");c.width=100;c.height=1;a=c.getContext("2d");a.width=100;a.height=1;b=a.createLinearGradient(0,0,100,0);b.addColorStop(0,this.u.fa(16777215,0));b.addColorStop(.88,this.u.fa(0,0));b.addColorStop(.9,this.u.fa(16654848,1));b.addColorStop(.92,this.u.fa(16776448,1));b.addColorStop(.94,this.u.fa(4849466,1));b.addColorStop(.96,
this.u.fa(131071,1));b.addColorStop(.98,this.u.fa(8190,1));b.addColorStop(1,this.u.fa(0,0));a.fillStyle=b;a.fillRect(0,0,100,1);d.texImage2D(d.TEXTURE_2D,0,d.RGBA,d.RGBA,d.UNSIGNED_BYTE,c)};m.prototype.Yq=function(){for(;0<this.ah.length;)this.ah.pop()};m.prototype.Vo=function(){var d=[],c=[],a=[];var b={radius:14,alpha:.2,color:11390415,B:.27};d.push(b);b={radius:20,alpha:.25,color:11390415,B:.4};d.push(b);b={radius:10,alpha:.2,color:12442332,B:.6};d.push(b);b={radius:15,alpha:.2,color:11390415,
B:.8};d.push(b);b={radius:10,alpha:.2,color:12442332,B:1.5};d.push(b);b={radius:15,alpha:.2,color:11390415,B:1.8};d.push(b);b={radius:8,alpha:.2,color:12575203,H:.8,B:.7};c.push(b);b={radius:7,alpha:.4,color:12575203,H:.5,B:1.6};c.push(b);b={radius:5,alpha:.4,color:12575203,H:.6,B:.9};c.push(b);b={radius:8,alpha:.3,color:12575203,H:.4,B:1.1};c.push(b);this.pc.push(d);this.hc.push(c);this.qc.push(a);d=[];c=[];a=[];b={radius:30,alpha:.3,color:11390415,B:.5};d.push(b);b={radius:10,alpha:.3,color:11390415,
B:1};d.push(b);b={radius:20,alpha:.3,color:11390415,B:1.3};d.push(b);b={radius:10,alpha:.3,color:11390415,B:1.5};d.push(b);b={radius:15,alpha:.3,color:11390415,B:1.8};d.push(b);b={radius:10,alpha:.3,color:15506856,H:.8,B:.7};c.push(b);b={radius:20,alpha:.5,color:15506856,H:.5,B:1.6};c.push(b);b={radius:5,alpha:.5,color:15506856,H:.6,B:.9};c.push(b);b={radius:60,alpha:.4,color:15506856,H:.2,B:1.1};c.push(b);a.push({radius:220,alpha:.035,B:2});this.pc.push(d);this.hc.push(c);this.qc.push(a);d=[];c=
[];a=[];b={radius:30,alpha:.5,color:15465727,B:.5};d.push(b);b={radius:40,alpha:.28,color:15726842,B:.8};d.push(b);b={radius:25,alpha:.32,color:15726842,B:1.1};d.push(b);b={radius:15,alpha:.25,color:15726842,B:1.35};d.push(b);b={radius:10,alpha:.28,color:15465727,B:1.65};d.push(b);b={radius:10,alpha:.45,color:15465727,H:.8,B:.7};c.push(b);b={radius:7,alpha:.5,color:15465727,H:.4,B:.9};c.push(b);b={radius:40,alpha:.4,color:15465727,H:.3,B:.38};c.push(b);b={radius:50,alpha:.4,color:15465727,H:.5,B:1.25};
c.push(b);b={radius:18,alpha:.2,color:15465727,H:.5,B:1.25};c.push(b);b={radius:10,alpha:.34,color:15726842,H:.8,B:1.5};c.push(b);b={radius:38,alpha:.37,color:15465727,H:.3,B:-.5};c.push(b);this.pc.push(d);this.hc.push(c);this.qc.push(a);d=[];c=[];a=[];b={radius:16,alpha:.5,color:16363159,B:.1};d.push(b);b={radius:26,alpha:.3,color:16091819,B:.32};d.push(b);b={radius:29,alpha:.2,color:16091819,B:1.32};d.push(b);b={radius:20,alpha:.18,color:16363159,B:1.53};d.push(b);b={radius:27,alpha:.13,color:16425092,
B:1.6};d.push(b);b={radius:20,alpha:.1,color:16091819,B:1.75};d.push(b);b={radius:12,alpha:.45,color:16312238,H:.45,B:.2};c.push(b);b={radius:8,alpha:.25,color:16434209,H:.7,B:.33};c.push(b);b={radius:9,alpha:.25,color:16091819,H:.4,B:.7};c.push(b);b={radius:7,alpha:.2,color:16091819,H:.4,B:.85};c.push(b);b={radius:60,alpha:.23,color:16091819,H:.55,B:1.05};c.push(b);b={radius:37,alpha:.1,color:16091819,H:.55,B:1.22};c.push(b);b={radius:10,alpha:.25,color:16363159,H:.65,B:1.38};c.push(b);b={radius:7,
alpha:.2,color:16434209,H:.5,B:1.45};c.push(b);b={radius:3,alpha:.2,color:16416033,H:.5,B:1.78};c.push(b);b={radius:6,alpha:.18,color:16434209,H:.45,B:1.9};c.push(b);b={radius:4,alpha:.14,color:16766514,H:.45,B:2.04};c.push(b);b={radius:30,alpha:.14,color:16766514,H:.8,B:.04};c.push(b);this.pc.push(d);this.hc.push(c);this.qc.push(a);d=[];c=[];a=[];b={radius:9,alpha:.3,color:14346999,H:.3,B:.3};c.push(b);b={radius:5,alpha:.5,color:14148072,H:.8,B:.6};c.push(b);b={radius:3,alpha:.37,color:14346999,
H:.66,B:.8};c.push(b);b={radius:45,alpha:.2,color:14346999,H:.36,B:1.2};c.push(b);b={radius:13,alpha:.2,color:14346999,H:.36,B:1.23};c.push(b);b={radius:11,alpha:.2,color:14148072,H:.36,B:1.28};c.push(b);b={radius:27,alpha:.16,color:14346999,H:.36,B:1.55};c.push(b);b={radius:6,alpha:.36,color:14148072,H:.8,B:1.7};c.push(b);this.pc.push(d);this.hc.push(c);this.qc.push(a);d=[];c=[];a=[];b={radius:24,alpha:.2,color:15186464,B:.2};d.push(b);b={radius:7,alpha:.26,color:15186464,B:.35};d.push(b);b={radius:23,
alpha:.18,color:15186464,B:.65};d.push(b);b={radius:13,alpha:.2,color:15186464,B:.8};d.push(b);b={radius:11,alpha:.15,color:15186464,B:1.4};d.push(b);b={radius:15,alpha:.11,color:15451904,B:1.6};d.push(b);b={radius:6,alpha:.45,color:15579138,H:.45,B:.22};c.push(b);b={radius:3,alpha:.3,color:15451904,H:.25,B:.4};c.push(b);b={radius:4,alpha:.2,color:15451904,H:.25,B:.45};c.push(b);b={radius:65,alpha:.17,color:15186464,H:.25,B:.5};c.push(b);b={radius:5,alpha:.45,color:15579138,H:.45,B:.88};c.push(b);
b={radius:140,alpha:.18,color:15579138,H:.32,B:.95};c.push(b);b={radius:12,alpha:.22,color:15579138,H:.32,B:1.1};c.push(b);b={radius:8,alpha:.32,color:15451904,H:.72,B:1.2};c.push(b);b={radius:55,alpha:.2,color:15451904,H:.45,B:1.33};c.push(b);b={radius:4,alpha:.3,color:15451904,H:.25,B:1.42};c.push(b);this.pc.push(d);this.hc.push(c);this.qc.push(a);d=[];c=[];a=[];b={radius:16,alpha:.4,color:10933495,B:.32};d.push(b);b={radius:14,alpha:.3,color:11007484,B:.36};d.push(b);b={radius:10,alpha:.3,color:4037331,
B:.58};d.push(b);b={radius:14,alpha:.22,color:8835068,B:.68};d.push(b);b={radius:10,alpha:.27,color:11007484,B:.82};d.push(b);b={radius:11,alpha:.27,color:10867450,B:1};d.push(b);b={radius:9,alpha:.2,color:6158332,B:1.05};d.push(b);b={radius:10,alpha:.17,color:10867450,B:1.78};d.push(b);b={radius:10,alpha:.3,color:4037331,B:-.23};d.push(b);b={radius:8,alpha:.45,color:8835068,H:.45,B:.175};c.push(b);b={radius:7,alpha:.4,color:12574715,H:.55,B:.46};c.push(b);b={radius:3,alpha:.3,color:10867450,H:.35,
B:.5};c.push(b);b={radius:60,alpha:.37,color:4031699,H:.75,B:.75};c.push(b);b={radius:3,alpha:.25,color:4031699,H:.25,B:.75};c.push(b);b={radius:3,alpha:.2,color:6158332,H:.25,B:.9};c.push(b);b={radius:7,alpha:.45,color:8835068,H:.45,B:1.3};c.push(b);b={radius:32,alpha:.22,color:8835068,H:.75,B:1.62};c.push(b);b={radius:9,alpha:.45,color:4031699,H:.65,B:1.6};c.push(b);b={radius:8,alpha:.25,color:4031699,H:.65,B:1.83};c.push(b);b={radius:7,alpha:.4,color:12574715,H:.55,B:-.18};c.push(b);this.pc.push(d);
this.hc.push(c);this.qc.push(a);d=[];c=[];a=[];b={radius:16,alpha:.4,color:16389120,B:.32};d.push(b);b={radius:26,alpha:.22,color:16389120,B:.4};d.push(b);b={radius:26,alpha:.25,color:16389120,B:.65};d.push(b);b={radius:18,alpha:.3,color:16389120,B:1.23};d.push(b);b={radius:14,alpha:.26,color:16389120,B:1.33};d.push(b);b={radius:17,alpha:.18,color:16389120,B:1.7};d.push(b);b={radius:30,alpha:.16,color:16389120,B:2.15};d.push(b);b={radius:100,alpha:.25,color:16389120,H:.22,B:1.45};c.push(b);b={radius:7,
alpha:.5,color:15628151,H:.3,B:1.5};c.push(b);b={radius:3,alpha:.5,color:15628151,H:.3,B:1.52};c.push(b);b={radius:4,alpha:.5,color:16389120,H:.3,B:1.745};c.push(b);b={radius:9,alpha:.22,color:16389120,H:.3,B:1.8};c.push(b);this.pc.push(d);this.hc.push(c);this.qc.push(a);d=[];c=[];a=[];b={radius:16,alpha:.4,color:10933495,B:.32};d.push(b);b={radius:14,alpha:.3,color:11007484,B:.36};d.push(b);b={radius:10,alpha:.3,color:4037331,B:.58};d.push(b);b={radius:14,alpha:.22,color:8835068,B:.68};d.push(b);
b={radius:10,alpha:.27,color:11007484,B:.82};d.push(b);b={radius:11,alpha:.27,color:10867450,B:1};d.push(b);b={radius:9,alpha:.2,color:6158332,B:1.05};d.push(b);b={radius:10,alpha:.17,color:10867450,B:1.78};d.push(b);b={radius:10,alpha:.3,color:4037331,B:-.23};d.push(b);b={radius:8,alpha:.45,color:8835068,H:.45,B:.175};c.push(b);b={radius:7,alpha:.4,color:12574715,H:.55,B:.46};c.push(b);b={radius:3,alpha:.3,color:10867450,H:.35,B:.5};c.push(b);b={radius:60,alpha:.37,color:4031699,H:.75,B:.75};c.push(b);
b={radius:3,alpha:.25,color:4031699,H:.25,B:.75};c.push(b);b={radius:3,alpha:.2,color:6158332,H:.25,B:.9};c.push(b);b={radius:7,alpha:.45,color:8835068,H:.45,B:1.3};c.push(b);b={radius:32,alpha:.22,color:8835068,H:.75,B:1.62};c.push(b);b={radius:9,alpha:.45,color:4031699,H:.65,B:1.6};c.push(b);b={radius:8,alpha:.25,color:4031699,H:.65,B:1.83};c.push(b);b={radius:7,alpha:.4,color:12574715,H:.55,B:-.18};c.push(b);this.pc.push(d);this.hc.push(c);this.qc.push(a);d=[];c=[];a=[];b={radius:16,alpha:.4,color:16389120,
B:.32};d.push(b);b={radius:26,alpha:.22,color:16389120,B:.4};d.push(b);b={radius:26,alpha:.25,color:16389120,B:.65};d.push(b);b={radius:18,alpha:.3,color:16389120,B:1.23};d.push(b);b={radius:14,alpha:.26,color:16389120,B:1.33};d.push(b);b={radius:17,alpha:.18,color:16389120,B:1.7};d.push(b);b={radius:30,alpha:.16,color:16389120,B:2.15};d.push(b);b={radius:100,alpha:.25,color:16389120,H:.22,B:1.45};c.push(b);b={radius:7,alpha:.5,color:15628151,H:.3,B:1.5};c.push(b);b={radius:3,alpha:.5,color:15628151,
H:.3,B:1.52};c.push(b);b={radius:4,alpha:.5,color:16389120,H:.3,B:1.745};c.push(b);b={radius:9,alpha:.22,color:16389120,H:.3,B:1.8};c.push(b);this.pc.push(d);this.hc.push(c);this.qc.push(a);d=[];c=[];a=[];b={radius:24,alpha:.2,color:15186464,B:.2};d.push(b);b={radius:7,alpha:.26,color:15186464,B:.35};d.push(b);b={radius:23,alpha:.18,color:15186464,B:.65};d.push(b);b={radius:13,alpha:.2,color:15186464,B:.8};d.push(b);b={radius:11,alpha:.15,color:15186464,B:1.4};d.push(b);b={radius:15,alpha:.11,color:15451904,
B:1.6};d.push(b);b={radius:6,alpha:.45,color:15579138,H:.45,B:.22};c.push(b);b={radius:3,alpha:.3,color:15451904,H:.25,B:.4};c.push(b);b={radius:4,alpha:.2,color:15451904,H:.25,B:.45};c.push(b);b={radius:65,alpha:.17,color:15186464,H:.25,B:.5};c.push(b);b={radius:5,alpha:.45,color:15579138,H:.45,B:.88};c.push(b);b={radius:140,alpha:.18,color:15579138,H:.32,B:.95};c.push(b);b={radius:12,alpha:.22,color:15579138,H:.32,B:1.1};c.push(b);b={radius:8,alpha:.32,color:15451904,H:.72,B:1.2};c.push(b);b={radius:55,
alpha:.2,color:15451904,H:.45,B:1.33};c.push(b);b={radius:4,alpha:.3,color:15451904,H:.25,B:1.42};c.push(b);this.pc.push(d);this.hc.push(c);this.qc.push(a)};m.prototype.Kq=function(){if(this.Ik){var d=this.u.S,c,a=new r.Ha(0,0,-100),b=this.u.pd(),e=0,f=0,g=!1;if(this.u.ia){var h=this.u.zb.width;var l=this.u.zb.height;this.u.K.Bh&&(h=this.u.K.rc.width,l=this.u.K.rc.height)}else{this.$||(this.$=this.kd.getContext("2d"));if(this.$.width!==this.u.D.width||this.$.height!==this.u.D.height)this.$.width=
this.u.D.width,this.$.height=this.u.D.height;this.$.clear?this.$.clear():this.$.clearRect(0,0,this.kd.width,this.kd.height);h=this.$.width;l=this.$.height}var k=Math.sqrt(h*h+l*l),q=k/800;for(c=0;c<this.ah.length;c++){var p=this.ah[c];a.init(0,0,-100);a.Ga(-p.A*Math.PI/180);a.La(p.pan*Math.PI/180);a.La(-this.u.pan.m*Math.PI/180);a.Ga(this.u.A.m*Math.PI/180);a.lb(this.u.V.m*Math.PI/180);if(-.01>a.z){f=-b/a.z;e=a.x*f;f*=a.y;var w=Math.max(h,l);Math.abs(e)<w/2+100&&Math.abs(f)<w/2+100&&(g=!0,e+=h/2,
f+=l/2)}if(g){this.u.ia&&(d.blendFunc(d.SRC_ALPHA,d.DST_ALPHA),d.enable(d.BLEND),d.disable(d.DEPTH_TEST));w=h/2;var x=l/2;var y=Math.sqrt((w-e)*(w-e)+(x-f)*(x-f));var z=k/2;x=h>l?h:l;w=p.nl/100*((z-y)/z);0>w&&(w=0);if(this.u.ia){d.useProgram(this.uc);d.bindBuffer(d.ARRAY_BUFFER,this.u.K.sb);d.vertexAttribPointer(this.uc.ja,this.u.K.sb.itemSize,d.FLOAT,!1,0,0);var fa=d.getUniformLocation(this.uc,"uCanvasDimensions");d.uniform2f(fa,d.drawingBufferWidth,d.drawingBufferHeight);d.uniform2f(d.getUniformLocation(this.uc,
"uFlareCenterPosition"),d.drawingBufferWidth/h*e,l-d.drawingBufferHeight/l*f);d.uniform1f(d.getUniformLocation(this.uc,"uBlindingValue"),w);fa=d.getUniformLocation(this.uc,"uAspectRatio");d.uniform1f(fa,this.u.K.Bh?d.drawingBufferWidth/d.drawingBufferHeight:d.drawingBufferWidth/d.drawingBufferHeight/(h/l));d.drawArrays(d.TRIANGLE_STRIP,0,this.u.K.sb.de)}else fa=this.$.createRadialGradient(e,f,1,e,f,x),fa.addColorStop(0,"rgba(255, 255, 255, "+w+")"),fa.addColorStop(.5,"rgba(255, 255, 255, "+.8*w+")"),
fa.addColorStop(1,"rgba(255, 255, 255, "+.6*w+")"),this.$.fillStyle=fa,this.$.fillRect(0,0,this.$.width,this.$.height);if(0!=Number(p.type)&&!this.u.K.Bh){w=h/2-e;x=l/2-f;var la=1,B=Number(p.type)-1;y<.35*z&&(la=y/(.35*z),la*=la);y>.7*z&&(la=(z-y)/(.3*z));la*=p.alpha/100;if(0<this.pc[B].length)for(y=0;y<this.pc[B].length;y++){var db=this.pc[B][y];z=db.radius*q;var ja=db.alpha*la;0>ja&&(ja=0);var id=db.color;if(8==B||9==B||10==B)id=p.color;if(this.u.ia)d.useProgram(this.Ca),d.bindBuffer(d.ARRAY_BUFFER,
this.wf),d.vertexAttribPointer(this.Ca.ja,this.wf.itemSize,d.FLOAT,!1,0,0),fa=d.getUniformLocation(this.Ca,"uCanvasDimensions2"),d.uniform2f(fa,d.drawingBufferWidth,d.drawingBufferHeight),d.uniform2f(d.getUniformLocation(this.Ca,"uCirclePosition"),d.drawingBufferWidth/h*(e+w*db.B),d.drawingBufferWidth/h*(l-(f+x*db.B))),d.uniform2f(d.getUniformLocation(this.Ca,"uCircleTexturePosition"),d.drawingBufferWidth/h*(e+w*db.B),l-(f+x*db.B)),d.uniform1f(d.getUniformLocation(this.Ca,"uCircleRadius"),z),d.uniform3f(d.getUniformLocation(this.Ca,
"uCircleColor"),(id>>16&255)/255,(id>>8&255)/255,(id&255)/255),d.uniform1f(d.getUniformLocation(this.Ca,"uCircleAlpha"),ja),d.uniform1f(d.getUniformLocation(this.Ca,"uCircleSoftness"),.1),fa=d.getUniformLocation(this.Ca,"uAspectRatio"),d.uniform1f(fa,d.drawingBufferWidth/d.drawingBufferHeight/(h/l)),d.drawArrays(d.TRIANGLE_FAN,0,this.wf.de);else{this.$.save();this.$.translate(e+w*db.B,f+x*db.B);fa=this.$.createRadialGradient(0,0,1,0,0,1.1*z);fa.addColorStop(0,this.u.fa(id,ja));fa.addColorStop(.65,
this.u.fa(id,.9*ja));fa.addColorStop(.8,this.u.fa(id,.7*ja));fa.addColorStop(1,this.u.fa(id,.2*ja));this.$.beginPath();id=2*Math.PI/6;db=Math.PI/180*35;var tf=!0;for(ja=db;ja<=db+2*Math.PI;ja+=id)tf?(this.$.moveTo(z*Math.sin(ja),z*Math.cos(ja)),tf=!1):this.$.lineTo(z*Math.sin(ja),z*Math.cos(ja));this.$.closePath();this.$.fillStyle=fa;this.$.fill();this.$.restore()}}if(0<this.hc[B].length)for(y=0;y<this.hc[B].length;y++){db=this.hc[B][y];z=db.radius*q;ja=db.alpha*la;0>ja&&(ja=0);id=db.color;if(8==
B||9==B||10==B)id=p.color;this.u.ia?(d.useProgram(this.Ca),d.bindBuffer(d.ARRAY_BUFFER,this.Dd),d.vertexAttribPointer(this.Ca.ja,this.Dd.itemSize,d.FLOAT,!1,0,0),fa=d.getUniformLocation(this.Ca,"uCanvasDimensions2"),d.uniform2f(fa,d.drawingBufferWidth,d.drawingBufferHeight),fa=d.getUniformLocation(this.Ca,"uCirclePosition"),d.uniform2f(fa,d.drawingBufferWidth/h*(e+w*db.B),d.drawingBufferWidth/h*(l-(f+x*db.B))),fa=d.getUniformLocation(this.Ca,"uCircleTexturePosition"),d.uniform2f(fa,d.drawingBufferWidth/
h*(e+w*db.B),l-(f+x*db.B)),fa=d.getUniformLocation(this.Ca,"uCircleRadius"),d.uniform1f(fa,z),d.uniform3f(d.getUniformLocation(this.Ca,"uCircleColor"),(id>>16&255)/255,(id>>8&255)/255,(id&255)/255),d.uniform1f(d.getUniformLocation(this.Ca,"uCircleAlpha"),ja),d.uniform1f(d.getUniformLocation(this.Ca,"uCircleSoftness"),db.H),fa=d.getUniformLocation(this.Ca,"uAspectRatio"),d.uniform1f(fa,d.drawingBufferWidth/d.drawingBufferHeight/(h/l)),d.drawArrays(d.TRIANGLE_FAN,0,this.Dd.de)):(this.$.save(),this.$.translate(e+
w*db.B,f+x*db.B),fa=this.$.createRadialGradient(0,0,1,0,0,z),fa.addColorStop(0,this.u.fa(id,ja)),fa.addColorStop(1-db.H,this.u.fa(id,.8*ja)),fa.addColorStop(1,this.u.fa(id,0)),this.$.beginPath(),this.$.arc(0,0,z,0,2*Math.PI,!1),this.$.closePath(),this.$.fillStyle=fa,this.$.fill(),this.$.restore())}if(0<this.qc[B].length)for(y=0;y<this.qc[B].length;y++)p=this.qc[B][y],z=p.radius*q,ja=p.alpha*la,0>ja&&(ja=0),this.u.ia?(d.useProgram(this.Db),d.activeTexture(d.TEXTURE0),d.bindTexture(d.TEXTURE_2D,this.mn),
d.bindBuffer(d.ARRAY_BUFFER,this.Dd),d.vertexAttribPointer(this.Db.ja,this.Dd.itemSize,d.FLOAT,!1,0,0),fa=d.getUniformLocation(this.Db,"uCanvasDimensions2"),d.uniform2f(fa,h,l),fa=d.getUniformLocation(this.Db,"uCirclePosition"),d.uniform2f(fa,e+w*p.B,l-(f+x*p.B)),fa=d.getUniformLocation(this.Db,"uRingTexturePosition"),d.uniform2f(fa,d.drawingBufferWidth/h*(e+w*p.B),l-(f+x*p.B)),fa=d.getUniformLocation(this.Db,"uCircleRadius"),d.uniform1f(fa,z),d.uniform2f(d.getUniformLocation(this.Db,"uRingPosition"),
e+w*p.B,l-(f+x*p.B)),d.uniform1f(d.getUniformLocation(this.Db,"uRingRadius"),z),d.uniform1f(d.getUniformLocation(this.Db,"uRingAlpha"),ja),fa=d.getUniformLocation(this.Db,"uAspectRatio"),d.uniform1f(fa,d.drawingBufferWidth/d.drawingBufferHeight/(h/l)),d.uniform1i(d.getUniformLocation(this.Db,"uSampler"),0),d.drawArrays(d.TRIANGLE_FAN,0,this.Dd.de)):(this.$.save(),this.$.translate(e+w*p.B,f+x*p.B),fa=this.$.createRadialGradient(0,0,0,0,0,z),fa.addColorStop(0,this.u.fa(16777215,0)),fa.addColorStop(.88,
this.u.fa(0,0)),fa.addColorStop(.9,this.u.fa(16654848,ja)),fa.addColorStop(.92,this.u.fa(16776448,ja)),fa.addColorStop(.94,this.u.fa(4849466,ja)),fa.addColorStop(.96,this.u.fa(131071,ja)),fa.addColorStop(.98,this.u.fa(8190,ja)),fa.addColorStop(1,this.u.fa(0,0)),this.$.beginPath(),this.$.arc(0,0,z,0,2*Math.PI,!1),this.$.closePath(),this.$.fillStyle=fa,this.$.fill(),this.$.restore())}this.u.ia&&(d.useProgram(this.u.za.P),d.disable(d.BLEND),d.enable(d.DEPTH_TEST))}}}};return m}();r.ko=n})(ggP2VR||(ggP2VR=
{}));var THREE;
(function(r){var n=function(){function m(d){this.sd=[];this.pa={x:0,y:0};this.Lc={x:0,y:0};this.hh=0;this.ci=!1;this.$k=this.Qe=0;this.Xk=!1;this.u=null;this.Dk=!0;this.Ed=1;this.mi=[];this.vj=this.ao=this.frustumCulled=!1;this.Hf=[-1,-1,-1,-1];this.xi=[];this.Me=[];this.rm=180;this.u=d;var c=this;setTimeout(function(){if(window.WebVRPolyfill&&window.Promise){var a={BUFFER_SCALE:1};try{new window.WebVRPolyfill(a),d.O("WebVR Polyfill loaded!")}catch(b){}}c.gq()},0);THREE?this.ml():console.log("Three.js not available!")}m.prototype.Wo=
function(){this.init();this.animate()};m.prototype.ml=function(){this.Rk=new THREE.Matrix4;this.Um=new THREE.Euler};m.prototype.init=function(){"getVRDisplays"in navigator||console.log("no vr support");if(THREE)if(this.renderer)console.log("already set up!");else{this.Rk||this.ml();var d=this,c=this.ld=this.u.ld,a=this.dr=new THREE.Scene,b=this.camera=new THREE.PerspectiveCamera(100,window.innerWidth/window.innerHeight,.001,2E4);108>THREE.REVISION&&(this.frustumCulled=!0);b.position.z=-.01;b.position.y=
0;b.position.x=0;this.renderer=b=new THREE.WebGLRenderer({depth:!0,logarithmicDepthBuffer:!0,alpha:!0,antialias:!0,stencil:!0});b.setClearColor(new THREE.Color(0),1);b.setPixelRatio(window.devicePixelRatio);b.setSize(window.innerWidth,window.innerHeight);b.gammaInput=!0;b.gammaOutput=!0;b.shadowMap.enabled=!1;c.appendChild(b.domElement);"getVRDisplays"in navigator&&(b.vr.enabled=!0,b.vr.setFrameOfReferenceType("head-model"));var e=this.ul=new THREE.Group;c=this.Cj=b.vr.getController(0);c.addEventListener("selectstart",
function(g){d.Vm(g)});c.addEventListener("selectend",function(){});c.visible=!1;e.add(c);b=this.Dj=b.vr.getController(1);b.addEventListener("selectstart",function(g){d.Vm(g)});b.addEventListener("selectend",function(){});b.visible=!1;e.add(b);e.visible=!1;a.add(e);e=(new THREE.BufferGeometry).setFromPoints([new THREE.Vector3(0,0,0),new THREE.Vector3(0,0,-1)]);var f=new THREE.LineBasicMaterial({color:14737632});e=new THREE.Line(e,f);e.name="line";e.scale.z=5;c.add(e.clone());b.add(e.clone());this.qh=
new THREE.Raycaster;this.pa=new THREE.Vector2;this.Lf=new THREE.Group;this.Df=new THREE.Group;this.Ke=new THREE.Group;this.Oj=new THREE.Group;this.wj=new THREE.Group;this.Lf.add(this.Ke);this.Lf.add(this.Oj);this.Lf.add(this.Df);a.add(this.Lf);a.add(this.wj);a=document.createElement("canvas");a.width=64;a.height=64;c=a.getContext("2d");c.fillStyle="black";c.lineWidth=3;c.beginPath();c.arc(32,32,10,0,2*Math.PI);c.stroke();a=new THREE.Texture(a);a.needsUpdate=!0;e=new THREE.PlaneBufferGeometry(2,2,
8);a=new THREE.MeshBasicMaterial({map:a});a.transparent=!0;a=new THREE.Mesh(e,a);a.position.z=-50;this.wj.add(a);window.addEventListener("resize",function(){d.Iq()},!1);document.addEventListener("mouseup",function(){d.Gq()},!1);document.addEventListener("mousedown",function(g){d.Eq(g)},!1);document.addEventListener("mousemove",function(g){d.Fq(g)},!1);this.display||this.ig()}else console.log("Three.js not available!")};m.prototype.Jk=function(){var d=this.u;this.display=null;d.O("VR not found");d.R("vrchanged",
{});d.R("playerstatechanged",{})};m.prototype.An=function(d){var c=this.u;this.display=d;this.renderer&&this.renderer.vr.setDevice(d);c.O("VR found");c.R("vrchanged",{});c.R("playerstatechanged",{})};m.prototype.gq=function(){if(!this.ao){this.ao=!0;var d=this;"getVRDisplays"in navigator?(window.addEventListener("vrdisplayconnect",function(c){d.An(c.display)},!1),window.addEventListener("vrdisplaydisconnect",function(){d.Jk()},!1),window.addEventListener("vrdisplaypresentchange",function(){d.ci=d.display?
d.display.isPresenting:!1;d.u.O("VR Presenting: "+d.ci);d.ci?(d.Wm(),d.ig()):(d.tl(),d.je())},!1),window.addEventListener("vrdisplayactivate",function(c){d.renderer&&d.renderer.domElement&&c.display.requestPresent([{source:d.renderer.domElement}])},!1),navigator.getVRDisplays().then(function(c){0<c.length?d.An(c[0]):d.Jk()})["catch"](d.Jk)):this.display=null}};m.prototype.Rg=function(){var d=this.display;return d?d.isPresenting:!1};m.prototype.dk=function(){return null!=this.display&&THREE};m.prototype.wg=
function(){var d=this.display,c=this.u;d?(1==this.Ed&&("Oculus Go"==d.displayName&&(this.Ed=1.7),"Oculus Quest"==d.displayName&&(this.Ed=1.5),"Gear VR"==d.displayName&&(this.Ed=2),"Lenovo Mirage Solo"==d.displayName&&(this.Ed=2)),c.Jc("Enter VR on '"+d.displayName+"' x"+this.Ed),this.renderer.vr.setFramebufferScaleFactor(this.Ed),d.isPresenting||(this.renderer.vr.setDevice(d),d.requestPresent([{source:this.renderer.domElement}]))):this.ig()};m.prototype.Wm=function(){if(THREE&&this.renderer){var d=
this.u;d.ef=!0;d.aa.style.display="none";d.ab.style.display="none";this.renderer.domElement.style.display="inline";d.R("vrchanged",{});d.R("playerstatechanged",{})}};m.prototype.tl=function(){if(THREE&&this.renderer){var d=this.u;d.ef=!1;d.aa.style.display="inline";d.ab.style.display="inline";this.renderer.domElement.style.display="none";d.Ui(0);d.Pc();d.update();d.R("vrchanged",{});d.R("playerstatechanged",{})}};m.prototype.sf=function(){var d=this.display;d&&d.isPresenting&&d.ys()};m.prototype.Nn=
function(){this.Rg()?this.sf():this.wg()};m.prototype.Ll=function(){var d=0,c=this.u;var a=1536;if(this.renderer){var b=this.display;if(b){var e=b.getEyeParameters("left");e&&(c.O(e),b=e.renderWidth*this.Ed,e.Kl&&(e=Math.abs(e.Kl.zs+e.Kl.Cs),90>e&&(b/=Math.tan(e/2*Math.PI/180))),10<b&&(a=b))}c.O("Canvas: "+a)}a*=Math.pow(2,0);if(0<c.v.levels.length){for(;c.v.levels.length>=d+2&&!c.v.levels[d+1].Se&&c.v.levels[d+1].width>a;)d++;c.O("Level "+d+" - width: "+c.v.levels[d].width);c.O(c.v.levels)}return d};
m.prototype.gm=function(d){var c=this.u,a=c.pe[d];d="";if(a){a=a.firstChild;for(var b;a;)"input"==a.nodeName&&(b=a)&&(b=0<c.v.levels.length?b.getAttributeNode("leveltileurl"):b.getAttributeNode("tilevrurl"))&&(d=b.nodeValue),a=a.nextSibling}else d=0<c.v.levels.length?c.v.mk:c.zl;for(a=0;3>a;a++)d=c.Mb(d,"c","vr"),d=c.Mb(d,"s","vr"),d=c.Mb(d,"r",0),d=c.Mb(d,"l",0),d=c.Mb(d,"x",0),d=c.Mb(d,"y",0),d=c.Mb(d,"v",0),d=c.Mb(d,"h",0);return c.Pb(d)};m.prototype.ceilPowerOfTwo=function(d){return Math.pow(2,
Math.ceil(Math.log(d)/Math.LN2))};m.prototype.loadTexture=function(d,c,a){var b=new THREE.ImageLoader;b.setCrossOrigin(this.u.crossOrigin);var e=this;b.load(c,function(f){var g=e.ceilPowerOfTwo(f.width),h=e.ceilPowerOfTwo(f.height);d.format=THREE.RGBFormat;d.needsUpdate=!0;if(g==f.width&&h==f.height||!a)d.image=f;else{e.u.O("resizing "+f.width+"/"+f.height+" -> "+g+"/"+h);var l=document.createElement("canvas");l.width=g;l.height=h;l.getContext("2d").drawImage(f,0,0,g,h);d.image=l}d.pm=!0;d.ae&&d.ae.pm&&
(d.Jg.visible=!0,d.ae.Jg.visible=!0)});this.mi.push(d)};m.prototype.ig=function(){if(THREE){var d=this.u;if(this.vj)d.O("vr panorama aleady added!");else{this.Ll();var c=this.Df,a=this;d.O("add vr panorama");this.je();this.camera.layers.enable(1);c.setRotationFromEuler(this.Um);c.rotateX(d.Oa.pitch*Math.PI/180);c.rotateZ(-d.Oa.V*Math.PI/180);var b=new THREE.SphereBufferGeometry(2E4/3*1.5,16,16),e=(new THREE.TextureLoader).load(this.gm(d.Uj()));e=new THREE.MeshBasicMaterial({map:e,side:THREE.DoubleSide});
b=new THREE.Mesh(b,e);b.scale.x=-1;b.rotateZ(d.Oa.V*Math.PI/180);b.rotateX(-d.Oa.pitch*Math.PI/180);b.rotateY(-90*Math.PI/180);c.add(b);a.Li=b;a.vj=!0;setTimeout(function(){d.O("Adding Main Pano");a.vj=!1;a.xo();d.F.j?a.Ao():a.yo();a.vo()});this.$q();this.Dk=!0}}};m.prototype.Ao=function(){var d=this.u,c=this.Df,a=2E4/3;if(d.Jd){var b=new THREE.VideoTexture(d.F.j);b.wrapS=THREE.ClampToEdgeWrapping;b.wrapT=THREE.ClampToEdgeWrapping;b.minFilter=THREE.LinearFilter;var e=new THREE.SphereBufferGeometry(a,
60,40);e.scale(-1,1,1);for(var f=e.attributes.uv.array,g=1;g<f.length;g+=2)f[g]*=.5;f=new THREE.MeshBasicMaterial({map:b});e=new THREE.Mesh(e,f);e.rotateY(-90*Math.PI/180);e.layers.set(d.yh?1:2);c.add(e);e=new THREE.SphereBufferGeometry(a,60,40);e.scale(-1,1,1);f=e.attributes.uv.array;for(g=1;g<f.length;g+=2)f[g]*=.5,f[g]+=.5;f=new THREE.MeshBasicMaterial({map:b});e=new THREE.Mesh(e,f);e.rotateY(-90*Math.PI/180);e.layers.set(d.yh?2:1)}else e=new THREE.SphereBufferGeometry(a,60,40),e.scale(-1,1,1),
b=new THREE.VideoTexture(d.F.j),b.wrapS=THREE.ClampToEdgeWrapping,b.wrapT=THREE.ClampToEdgeWrapping,b.minFilter=THREE.LinearFilter,f=new THREE.MeshBasicMaterial({map:b}),e=new THREE.Mesh(e,f),e.rotateY(-90*Math.PI/180);c.add(e);try{d.F.j.play()}catch(h){}};m.prototype.yo=function(){var d=this.u,c=[],a=this.Ll(),b=this.Df,e=2E4/3,f=d.Jd?2:1;if(d.v.levels.length>a)for(var g=d.v.levels[a],h=0;6>h;h++){c[h]=new THREE.Group;for(var l=0;l<g.ea;l++)for(var k=0;k<g.U;k++)for(var q=0;q<f;q++){var p=new THREE.Texture;
this.loadTexture(p,d.ne(h,a,k,l,1==q),!0);p.wrapS=THREE.ClampToEdgeWrapping;p.wrapT=THREE.ClampToEdgeWrapping;p.minFilter=THREE.LinearMipMapLinearFilter;p.anisotropy=1;var w=d.v.N+2*d.v.Ea,x=d.v.N+2*d.v.Ea;k==g.U-1&&(w=g.width-d.v.N*(g.U-1)+2*d.v.Ea);l==g.ea-1&&(x=g.width-d.v.N*(g.ea-1)+2*d.v.Ea);var y=new THREE.PlaneBufferGeometry(e*w/g.width,e*x/g.width,8),z=new THREE.MeshBasicMaterial({map:p});y=new THREE.Mesh(y,z);z.transparent=!0;z.side=THREE.FrontSide;z=1*d.v.N;y.position.x=e*(k*z+w/2-d.v.Ea-
g.width/2)/g.width;y.position.y=e*-(l*z+x/2-d.v.Ea-g.width/2)/g.width;y.position.z=-.5*e;if(d.Jd)if(y.visible=!1,y.layers.set(1==q?1:2),p.Jg=y,0==q)var fa=y;else w=fa.material.map,p.ae=w,w.ae=p;c[h].add(y);y.frustumCulled=this.frustumCulled}4>h?c[h].rotation.y=-h*Math.PI/2:c[h].rotation.x=(4==h?1:-1)*Math.PI/2;b.add(c[h])}else for(a=d.bf,h=0;6>h;h++)for(c[h]=new THREE.Group,q=0;q<f;q++)g=h,d.Jd&&(g=h+(1==q?6:0)),p=new THREE.Texture,this.loadTexture(p,d.Pb(d.sg[g]),!1),p.wrapS=THREE.ClampToEdgeWrapping,
p.wrapT=THREE.ClampToEdgeWrapping,p.minFilter=THREE.LinearFilter,y=new THREE.PlaneBufferGeometry(a*e/2,a*e/2,64),z=new THREE.MeshBasicMaterial({map:p}),y=new THREE.Mesh(y,z),z.transparent=!0,z.side=THREE.FrontSide,y.position.x=0,y.position.y=0,y.position.z=-.25*e,d.Jd&&(y.layers.set(1==q?1:2),y.visible=!1,p.Jg=y,0==q?fa=y:(w=fa.material.map,p.ae=w,w.ae=p)),c[h].add(y),4>h?c[h].rotation.y=-h*Math.PI/2:c[h].rotation.x=(4==h?1:-1)*Math.PI/2,b.add(c[h])};m.prototype.xo=function(){var d=this.u,c=this.Ke;
new r.Ha(0,0,-100);for(var a=d.I.cj,b=0;b<d.X.length;b++){var e=d.X[b],f=e.Qr(),g=.2;if(!1!==f){var h=!e.distance||0>=e.distance?5:1>e.distance?1:5>e.distance?e.distance:5;if(e.Wc){var l=.005,k=(new THREE.TextureLoader).load(e.Wc),q=new THREE.MeshBasicMaterial({map:k});if(e.bg){h=100;g=2*h*Math.tan(e.fov/2*Math.PI/180);var p=new THREE.PlaneBufferGeometry(g,g*e.Bd/e.Ae,1,1);q.transparent=!0;q.opacity=1}else p=new THREE.PlaneBufferGeometry(l*e.Ae,l*e.Bd,1,1),q.transparent=!0,q.opacity=.25;g=l*e.Bd/
2;q.side=THREE.DoubleSide}else p=new THREE.SphereBufferGeometry(.2,16,16),k=(new THREE.TextureLoader).load(this.gm(f)),q=new THREE.MeshBasicMaterial({map:k}),q.transparent=!0,q.opacity=.25;f=new THREE.Mesh(p,q);l=e.title;if(a.enabled&&""!=l){p=document.createElement("canvas");p.width=256;p.height=32;k=p.getContext("2d");this.Ah||(this.Ah=document.createElement("canvas"),this.Ah.width=p.width,this.Ah.height=p.height);var w=this.Ah.getContext("2d");w.clearRect(0,0,p.width,p.height);w.font="16px Helvetica";
w.textAlign="center";w.textBaseline="top";q=w.measureText(l);var x=q.width;0<a.height&&(x=Math.min(a.width,p.width-6),x=Math.max(x,q.width));q=x+6;a.background&&(w.fillStyle=this.u.fa(a.cc,a.bc),w.fillRect((p.width-x)/2-3,2,x+6,24));0<a.Uh&&(w.strokeStyle=this.u.fa(a.ec,a.dc),w.strokeRect((p.width-x)/2-3,2,x+6,24));w.fillStyle=this.u.fa(a.dj,a.bj);w.fillText(l,p.width/2,5,p.width-6);k.drawImage(this.Ah,(p.width-q)/2,2,q,24,0,0,p.width,p.height);k=new THREE.Texture(p);k.needsUpdate=!0;l=1.5;p=new THREE.PlaneBufferGeometry(1*
l*q/p.width,3*l/p.height,1,1);q=new THREE.MeshBasicMaterial({map:k,side:THREE.DoubleSide});p=new THREE.Mesh(p,q);p.translateY(-g-.125*l/2);p.frustumCulled=this.frustumCulled;f.add(p);q.transparent=!0;q.opacity=.5}f.rotateY(e.pan*Math.PI/180);f.rotateX(e.A*Math.PI/180);f.translateY(-0);f.translateZ(-h);f.userData=e;f.castShadow=!1;f.receiveShadow=!1;f.frustumCulled=this.frustumCulled;c.add(f)}}};m.prototype.vo=function(){for(var d=this.u,c=this.Oj,a=0;a<d.T.length;a++){var b=d.T[a];if(b.j&&"_videopanorama"!=
b.id&&!b.cd){b.j.play();var e=new THREE.VideoTexture(b.j);e.wrapS=THREE.ClampToEdgeWrapping;e.wrapT=THREE.ClampToEdgeWrapping;e.minFilter=THREE.LinearFilter;var f=5E3*Math.tan(b.fov*Math.PI/360);var g=0<b.xc?f*b.$c/b.xc:f;b.Gc&&1!=b.Gc&&(g*=b.Gc);f=new THREE.PlaneBufferGeometry(f,g,5,5);e=new THREE.MeshBasicMaterial({map:e,side:THREE.DoubleSide});e=new THREE.Mesh(f,e);e.rotateY(b.pan*Math.PI/180);e.rotateX(b.A*Math.PI/180);e.translateY(-0);e.translateZ(-2500);e.rotateZ(-b.lb*Math.PI/180);e.rotateY(-b.La*
Math.PI/180);e.rotateX(-b.Ga*Math.PI/180);e.userData=b;e.castShadow=!1;e.receiveShadow=!1;c.add(e)}}};m.prototype.vg=function(d){for(var c=d.children.length-1;0<=c;c--){var a=d.children[c];this.vg(a);d.remove(a)}d.geometry&&d.geometry.dispose();d.material&&(d.material.texture&&(d.material.texture.dispose(),d.material.texture.ae=null,d.material.texture.Jg=null),d.material.map&&(d.material.map.dispose(),d.material.map.ae=null,d.material.map.Jg=null),d.material.dispose())};m.prototype.je=function(){THREE&&
(this.mi=[],this.vg(this.Df),this.vg(this.Ke),this.vg(this.Oj),10<this.renderer.info.memory.textures&&this.u.qs(this.renderer.info.memory))};m.prototype.Iq=function(){if(THREE){var d=this.camera;d.aspect=window.innerWidth/window.innerHeight;d.updateProjectionMatrix();this.renderer.setSize(window.innerWidth,window.innerHeight)}};m.prototype.Vm=function(d){THREE&&(d=this.Zl(d.target),0<d.length&&(d=d[0].object.userData,this.u.dd(d.url,d.target)))};m.prototype.Zl=function(d){this.Rk.identity().extractRotation(d.matrixWorld);
this.qh.ray.origin.setFromMatrixPosition(d.matrixWorld);this.qh.ray.direction.set(0,0,-1).applyMatrix4(this.Rk);return this.qh.intersectObjects(this.Ke.children)};m.prototype.intersectObjects=function(d){var c=d.getObjectByName("line");d=this.Zl(d);if(0<d.length){d=d[0];var a=d.object;a.selected=!0;this.sd.push(a);c.scale.z=d.distance}else c.scale.z=5};m.prototype.So=function(){for(;this.sd.length;)this.sd.pop().selected=!1};m.prototype.Fq=function(d){d.preventDefault();var c=this.pa,a=this.renderer;
c.x=d.clientX/a.domElement.clientWidth*2-1;c.y=2*-(d.clientY/a.domElement.clientHeight)+1;1==d.buttons&&(this.hh=this.Lc.x-c.x)};m.prototype.hq=function(){var d=this.qh;d.setFromCamera(this.pa,this.camera);d=d.intersectObjects(this.Ke.children);0<d.length&&(d=d[0].object,d.selected=!0,this.sd.push(d))};m.prototype.iq=function(){var d=this.qh;d.setFromCamera({x:0,y:0},this.camera);d=d.intersectObjects(this.Ke.children);0<d.length&&(d=d[0].object,d.selected=!0,this.sd.push(d))};m.prototype.Gq=function(){this.hh=
0};m.prototype.Eq=function(d){50>d.clientX&&50>d.clientY&&this.u.sf();0<this.sd.length?this.u.dd(this.sd[0].userData.url):(this.Lc.x=this.pa.x,this.Lc.y=this.pa.y)};m.prototype.animate=function(){var d=this.rq=this;this.renderer&&this.renderer.setAnimationLoop(function(){d.render()})};m.prototype.render=function(){if(THREE){var d=this.rq,c=d.u;d.So();if(c.ef){d.Xk=d.Cj.visible||d.Dj.visible?!1:!0;d.Cj.visible&&d.intersectObjects(d.Cj);d.Dj.visible&&d.intersectObjects(d.Dj);d.ci||d.hq();if(d.Xk)if(d.iq(),
0<this.sd.length)if(this.ik!=this.sd[0])this.ik=this.sd[0],this.mq=Date.now();else{if(Date.now()>this.mq+1E3){var a=this.ik.userData;a&&a.url&&this.u.dd(a.url,a.target)}}else this.ik=null;var b=navigator.getGamepads&&navigator.getGamepads();a=!1;if(!d.ul.visible&&0<b.length){var e=b[0];e&&e.id&&""!=e.id&&(0<this.rm?d.ul.visible=!0:this.rm--)}for(var f=0;f<b.length;f++)if((e=b[f])&&0<e.buttons.length){var g="Oculus Touch (Left)"==e.id||"Oculus Touch (Right)"==e.id;e.buttons[0].touched&&2<=e.axes.length&&
!g?(a=!0,e=e.axes[0],-1==this.Hf[f]?this.Hf[f]=e:(g=this.Hf[f]-e,-.3>g&&(this.sh(20),this.Hf[f]=e),.3<g&&(this.sh(-20),this.Hf[f]=e))):(this.Hf[f]=-1,2<=e.axes.length&&(e=e.axes[0],.8<e?(a=!0,1!=this.Me[f]&&(this.Me[f]=1,this.xi[f]=Date.now()-1E4)):-.8>e?(a=!0,-1!=this.Me[f]&&(this.Me[f]=-1,this.xi[f]=Date.now()-1E4)):this.Me[f]=0,0!=this.Me[f]&&(e=Date.now()-this.xi[f],console.log(e),400<e&&(this.xi[f]=Date.now(),this.sh(20*this.Me[f])))))}this.Li&&0<this.mi.length&&this.mi.every(function(k){return k.pm})&&
(this.vg(this.Li),this.Df.remove(this.Li),this.Li=null,c.O("unload Preview Sphere"));b=this.Ke;for(f=b.children.length-1;0<=f;f--){e=b.children[f];var h=g=1;e.selected?(g=1.5,h=1):a?(g=.6,h=.7):(g=.4,h=.5);var l=e.scale.x;l+=.1*(g-l);e.material.opacity+=.1*(h-e.material.opacity);e.userData&&e.userData.Wc?(e.userData.bg&&(l=1,e.material.opacity=1),0<e.children.length&&(e.children[0].material.opacity=e.material.opacity)):(e.rotateY(1*Math.PI/180),0<e.children.length&&(e.children[0].rotateY(-1*Math.PI/
180),e.children[0].material.opacity=e.material.opacity));e.scale.x=e.scale.y=e.scale.z=l}a=d.camera.rotation.clone();a.reorder("YXZ");this.$k=180*a.y/Math.PI;this.Dk&&(this.sh(this.$k-c.pan.m),this.Dk=!1);c.mr(this.$k-this.Qe,180*a.x/Math.PI,180*a.z/Math.PI);c=this.wj;d.Xk?(c.setRotationFromEuler(d.camera.rotation),c.visible=!0):c.visible=!1;d.renderer.render(d.dr,d.camera);0==this.hh||isNaN(this.hh)||this.sh(this.hh)}}};m.prototype.$q=function(){this.Qe=0;this.Lf.setRotationFromEuler(this.Um)};m.prototype.sh=
function(d){this.Qe+=d;this.Lf.rotateY(d*Math.PI/180)};return m}();r.to=n})(ggP2VR||(ggP2VR={}));var Gh=!1;
(function(r){var n=function(){return function(){this.fov=this.A=this.pan=0}}(),m=function(){return function(){this.Ej=-1E7}}(),d=function(){function c(a,b){this.oq="TGljZW5zZTogQktZTS5DT00=";this.pan={m:0,eb:0,min:0,max:360,d:0,tk:0,Vc:0,open:0};this.A={m:0,eb:0,min:-90,max:90,d:0,Vc:0,open:0};this.V={m:0,eb:0,min:-180,max:180,d:0,open:0};this.Fc={pan:0,A:-90,V:0,fov:170,Lb:9};this.fov={m:70,eb:70,min:1,gh:0,max:170,qk:360,rk:270,prev:0,d:0,mode:0,En:0,Bl:0,open:0};this.Oa={V:0,pitch:0};this.D={width:10,height:10};
this.Xa=0;this.Hj=new r.Ha;this.crossOrigin="anonymous";this.Wa=this.Ki=4;this.qd=this.Lh=this.kh=this.Bc=0;this.bo={};this.yh=this.Jd=!1;this.ga={start:{x:0,y:0},oa:{x:0,y:0},Ld:{x:0,y:0},m:{x:0,y:0},na:{x:0,y:0}};this.Z={Lc:!1,Yc:!1,ri:function(){return this.Yc||this.Lc},Ml:0,startTime:0,start:{x:0,y:0},oa:{x:0,y:0},Ld:{x:0,y:0},m:{x:0,y:0},na:{x:0,y:0},nh:!1};this.vf=this.uf=!0;this.Ka={enabled:!0,oa:{x:0,y:0},na:{x:0,y:0},Ek:0,fov:{active:!1,wc:0}};this.kb={alpha:0,beta:0,gamma:0,orientation:0,
Qe:0,rh:!0,fadeIn:0};this.Mg={alpha:0,beta:0,gamma:0,orientation:0};this.F={src:[],kf:4,width:640,height:480,td:!1,ui:!1,Mk:!0,Fn:!1,De:"loop",Qk:"",j:HTMLVideoElement=null,Jn:!1,texture:WebGLTexture=null,Zk:WebGLBuffer=null,aj:WebGLBuffer=null,fk:WebGLBuffer=null,format:1,ji:0,flipY:1,wb:function(){return 0},rn:function(){},loop:function(){return!1}};this.wi=0;this.ra=this.Ja=this.Ra=this.aa=this.vc=this.ab=this.L=null;this.Fe="pano";this.Tj="flashcontainer";this.Ij="";this.control=null;this.gc=
[];this.Na=!1;this.ug=1;this.ta=null;this.Td=this.gf=this.Af=!1;this.jg=0;this.zd=.02;this.qj=0;this.rj=!1;this.pj=this.Rh=this.kg=this.ff=this.ll=0;this.kl=-1;this.Wb="";this.Rf=this.Mc=!1;this.mh=0;this.sg=[];this.zl="";this.qf=[];this.bf=this.Dc=1;this.mg=1024;this.Sf=!1;this.Oe=200;this.$b=0;this.zh=5;this.Cc=0;this.Kn=50;this.ek=this.Ln=0;this.C={enabled:!1,timeout:5,active:!1,xh:!1,speed:.4,fj:0,Hi:0,Tm:!0,Kf:"",Sm:!1,Ih:!1,dg:!1,Sh:"",Ud:"Animation01",jf:!1,Di:!1,Pk:!1,startTime:0,ud:0,Ag:!1,
Yh:!1,zi:0,Kd:0,Zg:0,$g:0,Yg:0,Jm:0};this.G={active:!1,aborted:!1,speed:.1,pan:0,A:0,V:0,fov:70,Rd:70,Zg:0,$g:0,Km:0,Yg:0,Lb:0,ph:0,jk:0,Wk:!1,ih:!1,jl:0,il:0,ni:!1};this.Gf={pan:-1,A:-1,fov:-1};this.Hm=0;this.la=null;this.eg={};this.Jh={};this.Xd=[];this.Ci={};this.Kc={};this.Jf={};this.I={mode:1,Vg:-1,Ba:0,nb:0,jd:.05,ec:255,dc:1,cc:255,bc:.3,zf:!0,cj:{enabled:!0,width:180,height:20,dj:0,bj:1,background:!0,cc:16777215,bc:1,ec:0,dc:1,tj:3,Uh:1,nj:!0},ub:[],Zb:[],fd:[],Yi:[]};this.Ia=null;this.X=
[];this.Y=[];this.T=[];this.fb=[];this.pe={};this.Za=[];this.xa=[];this.gd=[];this.re=[];this.Ze=[];this.ca=1;this.za=this.he=this.Ob=this.ld=null;this.xg={};this.vd={};this.v=new r.no;this.Jq={target:0,current:0,jd:.01,delay:2,Mj:0,Zh:!1,Fo:!1};this.margin={left:0,top:0,right:0,bottom:0};this.M={bh:!1,pq:!1,jc:!1,be:!1,Hd:!0,xm:!1,Dn:1,pn:!1,Kj:!0,rg:!0,Wh:!1,Bf:!1,qn:!0,sensitivity:8};this.fh=[];this.nd=!0;this.pa={x:0,y:0};this.Hh=this.Nb=this.Fh=this.hd=this.ef=this.ia=!1;this.lj=this.Wn=!0;this.bk=
!1;this.Ee=!0;this.cg=this.Zj=this.ak=!1;this.Xn=!0;this.li=!1;this.Pa=this.Vd="";this.Xc="transition";this.Va="transform";this.Cd="perspective";this.Fl="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAAICAIAAABLbSncAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAA5JREFUeNpiYBgeACDAAADIAAE3iTbkAAAAAElFTkSuQmCC";this.zb={width:0,height:0};this.Ql=new r.Ha;this.Pl=new r.Ha;this.Rl=new r.Ha;this.Sl=new r.Ha;this.Ol=new r.Ha;this.Ef=!1;this.Im=this.Qa="";this.mj=[];this.sk=[];this.Yj=!1;this.hj=
[];this.Sg=this.ym=this.Qg=this.zm=this.Id=this.gk=this.Fk=this.yc=this.si=this.Le=this.hk=this.Am=this.Bm=this.Dm=!1;this.Gh=!0;this.Pi=this.pi=!1;this.Og=[];this.devicePixelRatio=1;this.qa=this.K=null;this.ng=!1;this.Ya=null;this.yb={enabled:!1,speed:1,running:!1,Rj:!0};this.Qm=!1;this.Bi="<<LOG>>";this.cube=new r.oo;this.Vk=!1;this.qg=function(f,g){if(0==f.length)return f;var h;var l=[];var k=g.Mi(f[0])-0;for(h=0;h<f.length;h++){var q=h;var p=h+1;p==f.length&&(p=0);var w=g.Mi(f[p])-0;if(0<=k&&
0<=w)l.push(f[q]);else if(0<=k||0<=w){var x=w/(w-k);0>x&&(x=0);1<x&&(x=1);var y=new r.Ha;y.Gd(f[q],f[p],x);0>k||l.push(f[q]);l.push(y)}k=w}return l};this.bn=new n;this.Lk=0;this.oc=!1;this.yi=-1;this.Fg=function(f){return f?f.pageX||f.pageY?{x:f.pageX,y:f.pageY}:f.clientX||f.clientY?{x:f.clientX+document.body.scrollLeft+document.documentElement.scrollLeft,y:f.clientY+document.body.scrollTop+document.documentElement.scrollTop}:f.touches&&f.touches[0]?{x:f.touches[0].pageX,y:f.touches[0].pageY}:{x:0,
y:0}:{x:0,y:0}};this.Fi=1;this.ep=this.fi=this.Fm=this.Nj=this.zk=this.Ni=0;this.Gm=!1;this.Zd=!0;this.ob=new r.Oh(this);this.ob.zf=!1;this.El();if(7<this.Bi.length){var e=c.tg("bG9n");window[c.tg("Y29uc29sZQ==")][e](c.Cl(this.Bi))}this.Uf(this.ob);this.checkLoaded=this.gc;this.isLoaded=!1;b&&b.hasOwnProperty("useFlash")&&b.useFlash&&(this.Nb=!0,this.ia=this.hd=!1,b.hasOwnProperty("flashPlayerId")?this.Fe=b.flashPlayerId:this.Fe="pano",b.hasOwnProperty("flashContainerId")?this.Tj=b.flashContainerId:
this.Tj=a+"flash");b&&b.hasOwnProperty("webGLFlags")&&b.webGLFlags&&(this.bo=b.webGLFlags);this.Fa();this.Nb||(this.Ta=new r.ko(this));this.xl(a);this.Eo();this.userdata=this.eg=this.yg();this.emptyHotspot=this.ob;this.mouse=this.pa;this.K=new r.lo(this);this.Ya=new r.mo(this);this.za=new r.so(this);this.mb=new r.to(this);this.Pc()}c.prototype.mm=function(a){return-99991===a?this.oq:"6.1.2/17873"};c.prototype.Fj=function(){this.K.enabled=this.qa.enabled;this.K.type=this.qa.type;this.K.sa=
this.qa.zoomin;this.K.sc=this.qa.zoomout;this.K.lg=this.qa.blendtime;this.K.hg=this.qa.zoomoutpause;this.K.gg=this.qa.zoomfov;this.K.te=this.qa.zoomspeed;this.K.lf=this.qa.blendcolor;this.K.Oc=this.qa.softedge;this.qa=null};c.prototype.yr=function(a){this.qa={};this.qa.enabled=!0;this.qa.type=this.K.type;this.qa.zoomin=this.K.sa;this.qa.zoomout=this.K.sc;this.qa.blendtime=this.K.lg;this.qa.zoomoutpause=this.K.hg;this.qa.zoomfov=this.K.gg;this.qa.zoomspeed=this.K.te;this.qa.blendcolor=this.K.lf;this.qa.softedge=
this.K.Oc;if(a.hasOwnProperty("type")){var b=a.type;if("cut"==b||"crossdissolve"==b||"diptocolor"==b||"irisround"==b||"irisrectangular"==b||"wipeleftright"==b||"wiperightleft"==b||"wipetopbottom"==b||"wipebottomtop"==b||"wiperandom"==b)this.qa.type=b}a.hasOwnProperty("before")&&(b=Number(a.before),0==b||2==b)&&(this.qa.zoomin=b);a.hasOwnProperty("after")&&(b=Number(a.after),0==b||2==b||3==b||4==b)&&(this.qa.zoomout=b);a.hasOwnProperty("transitiontime")&&(b=Number(a.transitiontime),0<=b&&50>=b&&(this.qa.blendtime=
b));a.hasOwnProperty("waitfortransition")&&(this.qa.zoomoutpause=1==a.waitfortransition);a.hasOwnProperty("zoomedfov")&&(b=Number(a.zoomedfov),.01<=b&&50>=b&&(this.qa.zoomfov=b));a.hasOwnProperty("zoomspeed")&&(b=Number(a.zoomspeed),.01<=b&&99>=b&&(this.qa.zoomspeed=b));a.hasOwnProperty("dipcolor")&&(this.qa.blendcolor=a.dipcolor);a.hasOwnProperty("softedge")&&(a=Number(a.softedge),0<=a&&1E3>=a&&(this.qa.softedge=a));this.ng||this.Fj()};c.prototype.Nc=function(a,b,e){var f=b?Number(b):0;if(0!=a&&
4!=a&&12!=a&&9!=a)this.Jc("Unsupported projection type: "+a);else if(b&&0!==f&&4!==f&&12!==f&&9!==f)this.Jc("Unsupported projection2 type: "+f);else if(a==f&&(f=0),this.kh=e?Number(e):1,this.Wa!=a||this.Bc!=f)this.Wa=a,this.Bc=f,this.za.oi()};c.prototype.Sa=function(){return 0==this.Wa?4:this.Wa};c.prototype.zj=function(a,b){if(0!=a&&4!=a&&12!=a&&9!=a)this.Jc("Unsupported projection type: "+a);else if(this.ia||0==a||4==a||this.Jc("Projection changes require WebGL!"),this.Sa()!=a){var e={};e.pan=this.pan.m;
e.tilt=this.A.m;e.fov=this.fov.m;e.projection=a;e.timingFunction=3;e.speed=b;a=this.Eg(a);e.fov=Math.min(a,e.fov);this.Ei(e)}};c.prototype.addListener=function(a,b){(this.xg[a]=this.xg[a]||[]).push(b)};c.prototype.R=function(a,b){if(a=this.xg[a])for(var e=a.length,f=0;f<e;f++)try{a[f].apply(null,[b])}catch(g){this.Jc(g)}};c.prototype.removeEventListener=function(a,b){var e=this.xg[a];if(e){var f;var g=0;for(f=e.length;g<f;g++)if(e[g]===b){1===f?delete this.xg[a]:e.splice(g,1);break}}};c.prototype.Zq=
function(){this.Na=!0};c.prototype.$p=function(){return this.S};c.prototype.zo=function(a,b,e,f){if(!this.vd.hasOwnProperty(a)){var g=new m;this.vd[a]=g;g.type=b;"undefined"!==typeof e&&this.ke(a,e);"object"===typeof f&&this.yn(a,f);return!0}return!1};c.prototype.yn=function(a,b){if(this.vd.hasOwnProperty(a)&&"object"===typeof b){var e=this.vd[a];b.hasOwnProperty("cookiePath")&&(e.vl=String(b.cookiePath));b.hasOwnProperty("cookieExpireDays")&&(e.Ej=parseFloat(b.cookieExpireDays));if(b.hasOwnProperty("keep")&&
(e.Em=!!b.keep,e.Em)){var f="ggvar_"+a;0<document.cookie.length&&(b=document.cookie.indexOf(f+"="),-1!=b&&(b=b+f.length+1,f=document.cookie.indexOf(";",b),-1==f&&(f=document.cookie.length),b=decodeURIComponent(document.cookie.substring(b,f)),0==e.type&&this.ke(a,b),1==e.type&&this.ke(a,parseFloat(b)),2==e.type&&this.ke(a,"true"==b)))}return!0}return!1};c.prototype.ke=function(a,b){if(this.vd.hasOwnProperty(a)){var e=this.vd[a];if(0==e.type&&"string"===typeof b||1==e.type&&"number"===typeof b||2==
e.type&&"boolean"===typeof b){if(e.Em){var f="ggvar_"+a+"="+encodeURIComponent(b.toString());-1<=e.Ej&&(f+="; max-age="+86400*e.Ej);e.vl&&(f+="; path="+e.vl);document.cookie=f}e.value!=b&&(e.value=b,this.R("varchanged_"+a,{value:b}));return!0}}return!1};c.prototype.Up=function(a){if(this.vd.hasOwnProperty(a))return this.vd[a].value};c.tg=function(a){var b="",e=0;a=a.replace(/[^A-Za-z0-9\+\/=]/g,"");do{var f="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(a.charAt(e++));
var g="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(a.charAt(e++));var h="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(a.charAt(e++));var l="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(a.charAt(e++));f=f<<2|g>>4;g=(g&15)<<4|h>>2;var k=(h&3)<<6|l;b+=String.fromCharCode(f);64!=h&&(b+=String.fromCharCode(g));64!=l&&(b+=String.fromCharCode(k))}while(e<a.length);return b};c.Pr=function(a){for(var b=[1,1,1,1,2,2,
3,0],e=a.length,f="",g=0;g<e;){var h=a.charCodeAt(g++);if(h&128){var l=b[h>>3&7];if(!(h&64&&l)||g+l>e)return null;for(h&=63>>l;0<l;--l){var k=a.charCodeAt(g++);if(128!=(k&192))return null;h=h<<6|k&63}}f+=String.fromCharCode(h)}return f};c.Cl=function(a){return c.Pr(c.tg(a))};c.prototype.El=function(){this.devicePixelRatio=window.devicePixelRatio||1;this.Dm=!!navigator.userAgent.match(/(Windows|Win)/g);this.Bm=!!navigator.userAgent.match(/(Mac|Macintosh|Mac_powerpc)/g);this.Am=!!navigator.userAgent.match(/(Linux|Ubuntu)/g);
this.hk=!!navigator.userAgent.match(/(MSIE)/g);this.Le=!!navigator.userAgent.match(/(Edge|EdgA)/g);this.si=!!navigator.userAgent.match(/(Firefox)/g);if(this.yc=!!navigator.userAgent.match(/(Safari)/g)){var a=navigator.userAgent.indexOf("Safari");this.ed=navigator.userAgent.substring(a+7);a=navigator.userAgent.indexOf("Version");-1!=a&&(this.ed=navigator.userAgent.substring(a+8));this.ed=this.ed.substring(0,this.ed.indexOf(" "));this.ed=this.ed.substring(0,this.ed.indexOf("."));this.Fk=!0}if(this.gk=
!!navigator.userAgent.match(/(Chrome)/g))this.yc=!1;this.Id=!!navigator.userAgent.match(/(iPad|iPhone|iPod)/g);this.zm=!!navigator.userAgent.match(/(iPhone|iPod)/g);this.Qg=!!navigator.userAgent.match(/(android)/i);this.ym=!!navigator.userAgent.match(/(IEMobile)/i);this.Sg=this.Id||this.Qg||this.ym;/iP(hone|od|ad)/.test(navigator.platform)&&(a=navigator.appVersion.match(/OS (\d+)_(\d+)_?(\d+)?/),this.Og=[parseInt(a[1],10),parseInt(a[2],10),parseInt(a[3]||"0",10)]);this.pi=!window.requestAnimationFrame;
a=["Webkit","Moz","O","ms","Ms"];this.Pa="";this.Xc="transition";this.Va="transform";this.Cd="perspective";for(var b=0;b<a.length;b++)"undefined"!==typeof document.documentElement.style[a[b]+"Transform"]&&(this.Pa="-"+a[b].toLowerCase()+"-",this.Xc=a[b]+"Transition",this.Va=a[b]+"Transform",this.Cd=a[b]+"Perspective");this.bk=Eh();this.ia=Fh();this.hd=this.bk;this.ia&&(this.hd=!1);this.Mc=!0;this.Rf=!1;if(this.Id||this.Qg)this.xn(80),this.zh=2;this.Jc("Pano2VR player "+this.mm()+" - Prefix:"+this.Pa+
", "+(this.bk?"CSS 3D available":"CSS 3D not available")+", "+(this.ia?"WebGL available":"WebGL not available"));Gh&&this.O("Pano2VR Debug version!");try{window.AudioContext=window.AudioContext||window.webkitAudioContext,this.wa=new AudioContext}catch(e){this.wa=null}this.yc&&(!this.Fk||9>Number(this.ed))&&(this.wa=null);this.yc&&!this.Id&&12<=Number(this.ed)&&13>Number(this.ed)&&(this.wa=null);this.yc&&this.Id&&13==Number(this.Og[0])&&(1==Number(this.Og[1])||2<=Number(this.Og[1]))&&(this.wa=null);
this.Gh=this.zm?this.yc&&this.Fk&&10<=Number(this.ed)?!0:!1:!0};c.prototype.O=function(a){if(Gh){var b=document.getElementById("gg_debug");b&&(b.innerHTML=a.toString()+"<br />");window.console&&window.console.log(a)}};c.prototype.qs=function(a){if(Gh){var b=document.getElementById("gg_debug");b&&(b.innerHTML=a.toString()+"<br />");window.console&&window.console.warn(a)}};c.prototype.Jc=function(a){var b=document.getElementById("gg_debug");b&&(b.innerHTML=a+"<br />");window.console&&window.console.log(a)};
c.prototype.xn=function(a){this.Oe=a};c.prototype.setCrossOrigin=function(a){this.crossOrigin=a};c.prototype.hr=function(a){this.Cf=a};c.prototype.Lp=function(){return this.mh};c.prototype.fr=function(a){this.Vd=a};c.prototype.Xl=function(){return this.Vd};c.prototype.sp=function(){return this.Sg};c.prototype.np=function(){return this.li};c.prototype.tp=function(){return this.Ef};c.prototype.pp=function(){return this.C.active};c.prototype.ir=function(a){this.Sg=!!a};c.prototype.gi=function(){return this.isLoaded};
c.prototype.rp=function(){return!this.isLoaded};c.prototype.pd=function(){return Number(this.D.height)/(2*Math.tan(Math.PI/180*(this.Tb()/2)))};c.prototype.zn=function(a,b){this.isFullscreen&&(a=window.innerWidth,b=window.innerHeight);var e=a-this.margin.left-this.margin.right,f=b-this.margin.top-this.margin.bottom;if(!(10>e||10>f)){var g=window.devicePixelRatio||1;this.Sf&&(g=1);this.L.style.width=e+"px";this.L.style.height=f+"px";this.L.style.left=this.margin.left+"px";this.L.style.top=this.margin.top+
"px";if(this.ia)try{this.ab&&(this.ab.style.position="absolute",this.ab.style.display="inline",this.ab.style.width=e+"px",this.ab.style.height=f+"px",this.ab.width=e*g,this.ab.height=f*g),this.S&&(this.zb.width=e*g,this.zb.height=f*g,this.S.viewport(0,0,this.S.drawingBufferWidth,this.S.drawingBufferHeight))}catch(h){alert(h)}this.vc&&(this.vc.style.width=a+"px",this.vc.style.height=b+"px",this.vc.width=a,this.vc.height=b);this.Ra&&(this.Ra.style.width=a+"px",this.Ra.style.height=b+"px",this.Ja.style.width=
a+"px",this.Ja.style.height=b+"px",this.Ja.width=a,this.Ja.height=b,this.Ja.style.left=this.margin.left+"px",this.Ja.style.top=this.margin.top+"px",this.ta&&this.ta!=this.Ra&&(this.ta.style.width=a+"px",this.ta.style.height=b+"px"));this.Ta&&(e=this.Ta.kd,e.style.width=a+"px",e.style.height=b+"px",e.width=a,e.height=b,e.style.left=this.margin.left+"px",e.style.top=this.margin.top+"px");this.Af&&(this.Na=!0);e=this.L.offsetWidth;f=this.L.offsetHeight;if(this.D.width!=e||this.D.height!=f)this.D.width=
e,this.D.height=f;this.ls();this.ta&&this.ta.ggUpdateSize&&this.ta.ggUpdateSize(a,b);this.R("sizechanged",{w:a,h:b});this.R("playerstatechanged",{})}};c.prototype.df=function(){this.Vk=!0};c.prototype.Pc=function(){this.zn(this.ld.offsetWidth,this.ld.offsetHeight)};c.prototype.Zp=function(){var a={width:0,height:0};a.width=this.D.width;a.height=this.D.height;return a};c.prototype.He=function(){var a={x:0,y:0},b=this.L;if(b.offsetParent){do a.x+=b.offsetLeft,a.y+=b.offsetTop,b=b.offsetParent;while(b)
}return a};c.prototype.wr=function(a){this.la=a};c.prototype.jr=function(a,b,e,f){this.margin.left=a;this.margin.top=b;this.margin.right=e;this.margin.bottom=f;this.la=this.skinObj;this.df()};c.prototype.No=function(a){0==a&&(this.M.Hd=!1);1==a&&(this.M.Hd=!0);2==a&&(this.M.Hd=!this.M.Hd);this.R("viewmodechanged",{});this.R("playerstatechanged",{})};c.prototype.Xp=function(){return 1==this.M.Hd?1:0};c.prototype.rl=function(a,b){this.I.mode=1==b&&0<this.I.mode?0:Math.round(a);this.update();this.ra&&
(this.ra.changePolygonMode(a,b),this.ra.update());this.R("polymodechanged",{})};c.prototype.Bn=function(a){var b=this.I.ub.indexOf(a);-1==b?(this.I.ub.push(a),this.I.Zb.push(0),this.I.fd.push(1)):this.I.fd[b]=1;this.update()};c.prototype.sm=function(a){var b=this.I.ub.indexOf(a);-1!=b&&(this.I.fd[b]=0,this.I.Yi.push(a),this.update())};c.prototype.Vr=function(a){var b=this.I.ub.indexOf(a);-1==b||-1!=b&&0==this.I.fd[b]?this.Bn(a):this.sm(a);this.update()};c.prototype.Lo=function(a,b,e,f,g){for(var h=
0;h<this.X.length;h++){var l=this.X[h];"poly"!=l.type||l.id!=a&&""!=a||(l.cc=b,l.bc=e,l.ec=f,l.dc=g)}""==a&&(this.I.cc=b,this.I.bc=e,this.I.ec=f,this.I.dc=g);this.update()};c.prototype.Jo=function(a){this.Ta&&(this.Ta.Ik=0==a?!0:1==a?!1:!this.Ta.Ik,this.update())};c.prototype.Np=function(){return this.I.mode};c.prototype.Oo=function(){this.R("viewstatechanged",{})};c.prototype.Yp=function(){return 0};c.prototype.Ap=function(a){return(a=this.Ci[a])?a.type:"web"};c.prototype.zp=function(a){return(a=
this.Ci[a])?a:{}};c.prototype.Gp=function(a,b){var e=[];a||(a=this.Qa);var f=this.Xd[a];f&&(a=f);""===a&&0<Object.keys(this.Kc).length&&(a=Object.keys(this.Kc)[0]);this.Kc[a]&&this.Kc[a][b]&&(e.push(this.Kc[a][b].y),e.push(this.Kc[a][b].x));return e};c.prototype.Hp=function(a,b){var e=[];a||(a=this.Qa);var f=this.Xd[a];f&&(a=f);""===a&&0<Object.keys(this.Kc).length&&(a=Object.keys(this.Kc)[0]);this.Jf[a]&&this.Jf[a][b]&&(e.push(this.Jf[a][b].x),e.push(this.Jf[a][b].y));return e};c.prototype.bm=function(a){var b=
this.Xd[a];b&&(a=b);b=this.am();for(var e=[],f=0;f<b.length;f++)this.Kc[a][b[f]]&&e.push(b[f]);return e};c.prototype.yp=function(a){a=this.bm(a);return 0<a.length?a[0]:""};c.prototype.am=function(){var a=[],b;for(b in this.Ci)a.push(b);return a};c.prototype.um=function(a,b,e){a=Math.atan2(a+1,e);var f=Math.atan2(b+1,e);b=Math.sin(a);e=Math.sin(f);a=Math.cos(a);f=Math.cos(f);this.Ql.init(0,0,-1);this.Pl.init(a,0,-b);this.Rl.init(-a,0,-b);this.Sl.init(0,f,-e);this.Ol.init(0,-f,-e)};c.prototype.Bj=function(a){a=
this.qg(a,this.Ql);a=this.qg(a,this.Pl);a=this.qg(a,this.Rl);a=this.qg(a,this.Sl);return a=this.qg(a,this.Ol)};c.prototype.Qn=function(a){if(!this.Mc&&this.nq!=a){this.nq=a;var b=this.margin.left+this.D.width/2+"px ";b+=this.margin.top+this.D.height/2+"px ";this.Ra.style[this.Cd]=a+"px";this.Ra.style[this.Cd+"Origin"]=b;this.L.style[this.Cd]=a+"px";this.L.style[this.Cd+"Origin"]=b}};c.prototype.Yl=function(){return this.K.qe||this.K.xd||this.ia&&(4!=this.Wa||0!=this.Bc)?!1:!0};c.prototype.Dh=function(){var a=
new r.Ha(0,0,-100),b=this.pd();var e=100/this.fov.m;var f=this.v.width/this.v.height;var g=this.D.height*e*f;e*=this.D.height;for(var h=this.Yl(),l=0;l<this.X.length;l++){var k=this.X[l];if("point"==k.type){var q=!1;if(2==this.Xa){var p=(this.pan.m-k.pan)/100/f*g;var w=(this.A.m-k.A)/100*e;Math.abs(p)<this.D.width/2+500&&Math.abs(w)<this.D.height/2+500&&(q=!0)}else a.init(0,0,-100),a.Ga(-k.A*Math.PI/180),a.La(k.pan*Math.PI/180),a.La(-this.pan.m*Math.PI/180),a.Ga(this.A.m*Math.PI/180),a.lb(this.V.m*
Math.PI/180),.01>a.z?(w=-b/a.z,p=a.x*w,w*=a.y,Math.abs(p)<this.D.width/2+5E3&&Math.abs(w)<this.D.height/2+5E3&&(q=!0)):w=p=0;k.Xb=p+this.D.width/2;k.Cb=w+this.D.height/2;k.visible=q;k.px=k.Xb;k.py=k.Cb;k.visible=k.visible;if(k.j&&k.j.onUpdatePosition)k.j.onUpdatePosition(this,k);else k.j&&k.j.__div&&("none"!=k.j.__div.style[this.Xc]&&(k.j.__div.style[this.Xc]="none"),q&&h?k.j.ggUse3d?(this.Mc||this.Qn(b),2==this.Xa?(k.j.__div.style[this.Va]="scale("+(100/this.fov.m*500/k.j.gg3dDistance).toFixed(10)+
")",k.j.__div.style.left=this.margin.left+p+this.D.width/2+"px",k.j.__div.style.top=this.margin.top+w+this.D.height/2+"px"):(k.j.__div.style.width="1px",k.j.__div.style.height="1px",p="",this.Mc&&(p+="perspective("+b+"px) "),p+="translate3d(0px,0px,"+b+"px) ",p+="rotateZ("+this.V.m.toFixed(10)+"deg) ",p+="rotateX("+this.A.m.toFixed(10)+"deg) ",p+="rotateY("+(-this.pan.m).toFixed(10)+"deg) ",p+="rotateY("+k.pan.toFixed(10)+"deg) ",p+="rotateX("+(-k.A).toFixed(10)+"deg) ",p+="translate3d(0px,0px,"+
(-1*k.j.gg3dDistance).toFixed(10)+"px) ",k.j.__div.style[this.Va+"Origin"]="0% 0%",k.j.__div.style[this.Va]=p,k.j.__div.style.left=this.margin.left+this.D.width/2+"px",k.j.__div.style.top=this.margin.top+this.D.height/2+"px")):(k.j.__div.style.left=this.margin.left+p+this.D.width/2+"px",k.j.__div.style.top=this.margin.top+w+this.D.height/2+"px"):(k.j.ggUse3d&&(k.j.__div.style[this.Va]=""),k.j.__div.style.left="-1000px",k.j.__div.style.top="-1000px"))}if("poly"==k.type){var x=[];if(2==this.Xa)for(k.ge=
[],q=0;q<k.vertices.length;q++)w=k.vertices[q],p=(this.pan.m-w.pan)/100/f*g,w=(this.A.m-w.A)/100*e,p+=this.margin.left+this.D.width/2,w+=this.margin.top+this.D.height/2,k.ge.push({Xb:p,Cb:w});else{for(q=0;q<k.vertices.length;q++)w=k.vertices[q],a.init(0,0,-100),a.Ga(-w.A*Math.PI/180),a.La(w.pan*Math.PI/180),a.La(-this.pan.m*Math.PI/180),a.Ga(this.A.m*Math.PI/180),a.lb(this.V.m*Math.PI/180),x.push(a.clone());x=this.Bj(x);if(0<x.length)for(q=0;q<x.length;q++)a=x[q],.1>a.z?(w=-b/a.z,p=this.D.width/2+
a.x*w,w=this.D.height/2+a.y*w):w=p=0,a.Xb=p,a.Cb=w;k.ge=x}}}};c.prototype.jp=function(){for(var a=[],b=0;b<this.X.length;b++){var e=this.X[b];"point"==e.type&&e.j&&e.j.__div&&a.push(e.j.__div)}return a};c.prototype.fa=function(a,b){a=Number(a);isNaN(b)&&(b=0);0>b&&(b=0);1<b&&(b=1);return"rgba("+(a>>16&255)+","+(a>>8&255)+","+(a&255)+","+b+")"};c.prototype.Lq=function(){var a;if(this.Ja&&(this.I.Vg!=this.I.mode&&(this.I.Vg=this.I.mode,this.Ja.style.visibility=0<this.I.mode?"inherit":"hidden"),0<=this.I.mode||
0<this.I.ub.length)){this.ma||(this.ma=this.Ja.getContext("2d"));if(this.ma.width!=this.D.width||this.ma.height!=this.D.height)this.ma.width=this.D.width,this.ma.height=this.D.height;this.ma.clear?this.ma.clear():this.ma.clearRect(0,0,this.Ja.width,this.Ja.height);var b=1;0>=this.I.mode&&(b=0);3==this.I.mode&&(b=this.I.Ba);for(a=0;a<this.X.length;a++){var e=this.X[a];var f=b;if("poly"==e.type){var g=e.ge;2==this.I.mode&&(f=e.Ba);var h=this.I.ub.indexOf(e.id);-1!=h&&(f=this.I.Zb[h]);this.ma.fillStyle=
this.fa(e.cc,e.bc*f);this.ma.strokeStyle=this.fa(e.ec,e.dc*f);if(0<g.length){this.ma.beginPath();for(e=0;e<g.length;e++)f=g[e],0==e?this.ma.moveTo(f.Xb,f.Cb):this.ma.lineTo(f.Xb,f.Cb);this.ma.closePath();this.ma.stroke();this.ma.fill()}}}}};c.prototype.tm=function(a,b,e){var f,g=!1;var h=0;for(f=a.length-1;h<a.length;f=h++){var l=a[h];f=a[f];l.Cb>e!=f.Cb>e&&b<(f.Xb-l.Xb)*(e-l.Cb)/(f.Cb-l.Cb)+l.Xb&&(g=!g)}return g};c.prototype.Vh=function(a,b){var e=-1;if((0<=this.I.mode||0<this.I.ub.length)&&this.jq())for(var f=
0;f<this.X.length;f++){var g=this.X[f];"poly"==g.type&&g.ge&&0<g.ge.length&&(-1!=this.I.mode||-1!=this.I.ub.indexOf(g.id))&&this.tm(g.ge,a,b)&&(e=f,g.Xb=a,g.Cb=b)}return 0<=e?this.X[e]:!1};c.prototype.jq=function(){return 4==this.Sa()&&0==this.Bc};c.prototype.Tb=function(){var a=0,b=this.Sa(),e=this.D;switch(this.fov.mode){case 0:a=this.fov.m/2;break;case 1:a=4==b?180*Math.atan(e.height/e.width*Math.tan(this.fov.m/2*Math.PI/180))/Math.PI:e.height/e.width*this.fov.m/2;break;case 2:a=Math.sqrt(e.width*
e.width+e.height*e.height);a=4==b?180*Math.atan(e.height/a*Math.tan(this.fov.m/2*Math.PI/180))/Math.PI:e.height/a*this.fov.m/2;break;case 3:a=4*e.height/3>e.width?this.fov.m/2:4==b?180*Math.atan(4*e.height/(3*e.width)*Math.tan(this.fov.m/2*Math.PI/180))/Math.PI:4*e.height/(3*e.width)*(this.fov.m/2)}return 2*a};c.prototype.mp=function(a,b){a||(a=this.Tb());b||(b=this.Sa());return 4==b?180*Math.atan(this.aspect()*Math.tan(a/2*Math.PI/180))/Math.PI:a*this.aspect()};c.prototype.aspect=function(){return this.D.width/
this.D.height};c.prototype.ol=function(a){var b=this.fov.m;a/=2;var e=this.Sa();switch(this.fov.mode){case 0:b=2*a;break;case 1:a=4==e?180*Math.atan(this.D.width/this.D.height*Math.tan(a*Math.PI/180))/Math.PI:this.D.width/this.D.height*a;b=2*a;break;case 2:b=Math.sqrt(this.D.width*this.D.width+this.D.height*this.D.height);a=4==e?180*Math.atan(b/this.D.height*Math.tan(a*Math.PI/180))/Math.PI:b/this.D.height*a;b=2*a;break;case 3:4*this.D.height/3>this.D.width?b=2*a:(b=3*this.D.width/(4*this.D.height),
a=4==e?180*Math.atan(b*Math.tan(a*Math.PI/180))/Math.PI:b*a,b=2*a)}return b};c.prototype.Wi=function(a){this.fov.m=this.ol(a)};c.prototype.pg=function(){if(!this.ef){var a=this.bn;a.pan=this.pan.m;a.A=this.A.m;a.fov=this.fov.m;this.nf(a);this.nf(a);this.nf(a);this.pan.m=a.pan;this.A.m=a.A;this.fov.m=a.fov}};c.prototype.nf=function(a){var b=this.D.width/this.D.height;if(2==this.Xa){if(0<this.fov.gh){var e=this.Dc;this.v.levels&&0<this.v.levels.length&&(e=this.v.levels[0].height);this.fov.min=100*this.D.height/
(e*this.fov.gh)}var f=a.fov/2;e=f*b;var g=this.v.width/this.v.height*50;b=this.M.qn?2*Math.min(50,g/b):2*Math.max(50,g/b);a.fov<this.fov.min&&(a.fov=this.fov.min);a.fov>b&&(a.fov=b);50<f?a.A=0:(50<a.A+f&&(a.A=50-f),-50>a.A-f&&(a.A=-50+f));e>g?a.pan=0:(a.pan+e>g&&(a.pan=g-e,this.C.active&&(this.C.speed=-this.C.speed,this.pan.d=0)),a.pan-e<-g&&(a.pan=-g+e,this.C.active&&(this.C.speed=-this.C.speed,this.pan.d=0)))}else{0<this.fov.gh&&(e=this.Dc,this.v.levels&&0<this.v.levels.length&&(e=this.v.levels[0].height),
this.fov.min=360*Math.atan2(this.D.height/2,e/2*this.fov.gh)/Math.PI);a.fov<this.fov.min&&(a.fov=this.fov.min);g=this.fov.max;var h=179;f=this.Tb()/2;e=b*f;4==this.Sa()?e=180*Math.atan(b*Math.tan(f*Math.PI/180))/Math.PI:9==this.Sa()?(g=this.fov.rk,h=355):12==this.Sa()&&(g=this.fov.qk,h=360);this.ia||(g=Math.max(160,g));a.fov>g&&(a.fov=g);12==this.Sa()&&(2*e>h&&(a.fov=h/b),f=this.Tb()/2,2*f>h&&(a.fov=h),f=this.Tb()/2,e=b*f);2*f>this.A.max-this.A.min&&180>this.A.max-this.A.min&&(f=(this.A.max-this.A.min)/
2,a.fov=this.ol(2*f));90>this.A.max?a.A+f>this.A.max&&(a.A=this.A.max-f):a.A>this.A.max&&(a.A=this.A.max);-90<this.A.min?a.A-f<this.A.min&&(a.A=this.A.min+f):a.A<this.A.min&&(a.A=this.A.min);b=this.pan.max-this.pan.min;if(359.99>b){g=90;h=Math.tan(f*Math.PI/180);var l=Math.tan((Math.abs(a.A)+f)*Math.PI/180);l=Math.sqrt(l*l+1)/Math.sqrt(h*h+1);f=180*Math.atan(l*Math.tan(e*Math.PI/180))/Math.PI;2*f>b&&(l=Math.tan(b*Math.PI/360)/Math.tan(e*Math.PI/180),b=l*Math.sqrt(h*h+1),l=Math.sqrt(b*b-1),g=180/Math.PI*
Math.atan(l));a.pan+f>this.pan.max&&(a.pan=this.pan.max-f,this.C.active&&(this.C.speed=-this.C.speed,this.pan.d=0));a.pan-f<this.pan.min&&(a.pan=this.pan.min+f,this.C.active&&(this.C.speed=-this.C.speed,this.pan.d=0));a.A+e>g&&(a.A=g-e);a.A-e<-g&&(a.A=-g+e)}}};c.prototype.update=function(a){void 0===a&&(a=0);this.Na=!0;a&&(this.ug=Math.max(1*a,this.ug))};c.prototype.$l=function(){return this.ra?!!this.ra.isTileLoading:0<this.$b||0<this.Cc};c.prototype.Eh=function(){var a=Date.now();if(this.Nb){if(this.ra)if(this.cs(),
2===this.Xa)this.pg(),this.Dh();else if(0===this.Xa){var b=this.pd();this.um(this.D.width/2,this.D.height/2,b);this.Dh()}}else 2===this.Xa?(this.Dh(),this.ia?(this.za.Tk(),this.za.Xm()):this.Tk()):0===this.Xa&&(!this.ia||4==this.Wa&&0==this.Bc?(b=this.pd(),this.um(this.D.width/2,this.D.height/2,b),this.Dh(),this.Hh?this.za.ks():this.Wn&&this.Vn(),this.Rn(),this.ia?(this.F.td?14==this.F.format?this.za.js():this.za.co():0<this.v.levels.length?this.za.rs():this.za.ts(),this.za.Xm()):(this.hd?0<this.v.levels.length?
this.gs():this.fs():this.Fh&&this.bs(),this.Lq()),this.Ta&&this.Ta.Kq()):(this.za.co(),this.Dh(),this.fq()));b=Date.now();50<b-a?(this.O("Time between frames: "+(b-a)),this.Sf||(2<this.Lk?(this.Sf=!0,this.O("disabling HighDPI rendering"),this.Pc()):this.Lk++)):this.Lk=0;this.Af&&this.v.kn++};c.prototype.fs=function(){var a=!1;if(this.D.width!=this.L.offsetWidth||this.D.height!=this.L.offsetHeight)this.D.width=this.L.offsetWidth,this.D.height=this.L.offsetHeight,this.L.style[this.Va+"OriginX"]=this.D.width/
2+"px",this.L.style[this.Va+"OriginY"]=this.D.height/2+"px",a=!0;var b=Math.round(this.pd());this.Wg==b&&!a||this.Mc||(this.Wg=b,this.L.style[this.Cd]=b+"px");this.cube.Ro(this.pan.m,this.A.m,this.V.m,this.Oa);for(a=0;6>a;a++){var e;if(e=this.cube.faces[a]){var f="";this.Mc?(f+="translate3d("+this.D.width/2+"px,"+this.D.height/2+"px,0px) ",f+="perspective("+b+"px) ",f+="translate3d(0px,0px,"+b+"px) "):f+="translate3d("+this.D.width/2+"px,"+this.D.height/2+"px,"+b+"px) ";f+="rotateZ("+Number(this.V.m).toFixed(10)+
"deg) ";f+="rotateX("+Number(this.A.m).toFixed(10)+"deg) ";f+="rotateY("+Number(-this.pan.m).toFixed(10)+"deg) ";e.nm&&(f+=e.nm,e.qb||(f="translate3d(-10px,-10px,0px) scale(0.001,0.001)"),e.W.style[this.Va]=f)}}};c.prototype.bs=function(){this.pg();var a;this.vc&&(a=this.vc.getContext("2d"));if(this.D.width!==this.L.offsetWidth||this.D.height!==this.L.offsetHeight)this.D.width=this.L.offsetWidth,this.D.height=this.L.offsetHeight;if(a){var b=a.canvas.width/2,e=a.canvas.height/2,f=a.createRadialGradient(b,
e,5,b,e,Math.max(b,e));f.addColorStop(0,"#333");f.addColorStop(1,"#fff");a.rect(0,0,a.canvas.width,a.canvas.height);a.fillStyle=f;a.fill();a.fillStyle="#f00";a.font="20px Helvetica";a.textAlign="center";a.fillText("Pan: "+this.pan.m.toFixed(1),b,e-60);a.fillText("Tilt: "+this.A.m.toFixed(1),b,e-30);a.fillText("Fov: "+this.fov.m.toFixed(1),b,e+0);a.fillText("Node: "+this.Uj(),b,e+30);a.fillText("Title: "+this.eg.title,b,e+60)}};c.prototype.cs=function(){this.pg();if(this.D.width!==this.L.offsetWidth||
this.D.height!==this.L.offsetHeight)this.D.width=this.L.offsetWidth,this.D.height=this.L.offsetHeight;this.ra&&this.ra.setPan&&(this.ra.setPan(this.pan.m),this.ra.setTilt(this.A.m),this.ra.setFov(this.fov.m))};c.prototype.Tk=function(){this.Ja.style.visibility="inherit";this.ma||(this.ma=this.Ja.getContext("2d"));if(this.ma.width!=this.D.width||this.ma.height!=this.D.height)this.ma.width=this.D.width,this.ma.height=this.D.height;this.ma.clear?this.ma.clear():this.ma.clearRect(0,0,this.Ja.width,this.Ja.height);
this.Cc=0;var a=100/this.fov.m;var b=this.v.width/this.v.height;var e=this.D.height*a*b;a*=this.D.height;var f=(this.pan.m/100/b-.5)*e+this.D.width/2;for(var g=(this.A.m/100-.5)*a+this.D.height/2,h,l,k,q,p=0;this.v.levels.length>=p+2&&this.v.levels[p+1].width>e;)p++;var w;var x=[];for(w=this.v.levels.length-1;w>=p;){b=this.v.levels[w];if(b.cache){var y={jb:0,Gb:0};y.Ib=b.U-1;y.Jb=b.ea-1}else{y={};var z=-g/a*(b.height/this.v.N);h=(-f+this.D.width)/e*(b.width/this.v.N);l=(-g+this.D.height)/a*(b.height/
this.v.N);y.jb=Math.min(Math.max(0,Math.floor(-f/e*(b.width/this.v.N))),b.U-1);y.Gb=Math.min(Math.max(0,Math.floor(z)),b.ea-1);y.Ib=Math.min(Math.max(0,Math.floor(h)),b.U-1);y.Jb=Math.min(Math.max(0,Math.floor(l)),b.ea-1)}x[w]=y;var fa=!0;for(l=y.Gb;l<=y.Jb;l++)for(h=y.jb;h<=y.Ib;h++)q=h+l*b.U,z=b.ba[q],z||(z=new r.Sd,b.ba[q]=z),this.$b<this.zh?z.v||(this.ek++,z.v=new Image,z.v.onload=this.Sr(),z.v.onerror=this.ej(z),z.v.onabort=this.ej(z),z.v.crossOrigin=this.crossOrigin,z.v.setAttribute("src",this.ne(0,
w,h,l)),b.cache&&this.gc.push(z.v),this.$b++,this.Na=!0):this.Cc++,z.v&&z.v.complete||(fa=!1),z.visible=!0;y.lk=fa;w--}for(w=this.v.levels.length-1;w>=p;){b=this.v.levels[w];if(x[w]&&0<=x[w].jb)for(y=x[w],l=y.Gb;l<=y.Jb;l++)for(h=y.jb;h<=y.Ib;h++)q=h+l*b.U,(z=b.ba[q])||(z=b.ba[q]=new r.Sd),z.v&&z.v.complete&&(q=f+(-this.v.Ea+this.v.N*h)*e/b.width,this.ma.drawImage(z.v,q,g+(-this.v.Ea+this.v.N*l)*a/b.height,z.v.width*e/b.width,z.v.height*a/b.height)),z.visible=!0;w--}for(e=0;e<this.v.levels.length;e++)if(b=
this.v.levels[e],!b.cache)for(k in b.ba)b.ba.hasOwnProperty(k)&&(z=b.ba[k],z.visible||(z.v=null,delete b.ba[k]));if(0<=this.I.mode||0<this.I.ub.length)for(e=1,0>=this.I.mode&&(e=0),3==this.I.mode&&(e=this.I.Ba),k=0;k<this.X.length;k++)if(b=this.X[k],f=e,"poly"==b.type&&(a=b.ge,2==this.I.mode&&(f=b.Ba),g=this.I.ub.indexOf(b.id),-1!=g&&(f=this.I.Zb[g]),0<a.length)){this.ma.fillStyle=this.fa(b.cc,b.bc*f);this.ma.strokeStyle=this.fa(b.ec,b.dc*f);this.ma.beginPath();for(b=0;b<a.length;b++)f=a[b],0==b?
this.ma.moveTo(f.Xb,f.Cb):this.ma.lineTo(f.Xb,f.Cb);this.ma.closePath();this.ma.stroke();this.ma.fill()}this.nd=!1};c.prototype.Rr=function(a){var b=this;return function(){b.update();b.nd=!0;a.loaded=!0;a.v&&!a.W&&b.L.appendChild(a.v);b.$b&&b.$b--;a.v&&a.cb&&(a.cb.drawImage(a.v,0,0),a.v=null)}};c.prototype.Sr=function(){var a=this;return function(){a.Na=!0;a.nd=!0;a.$b&&a.$b--}};c.prototype.ej=function(a){var b=this;return function(){b.Na=!0;b.nd=!0;b.$b&&b.$b--;a.v=null}};c.prototype.lm=function(a,
b,e){e.jb=a.width/this.v.N*b.Bg;e.Gb=a.height/this.v.N*b.Cg;e.Ib=a.width/this.v.N*b.dh;e.Jb=a.height/this.v.N*b.eh;e.jb=Math.min(Math.max(0,Math.floor(e.jb)),a.U-1);e.Gb=Math.min(Math.max(0,Math.floor(e.Gb)),a.ea-1);e.Ib=Math.min(Math.max(0,Math.floor(e.Ib)),a.U-1);e.Jb=Math.min(Math.max(0,Math.floor(e.Jb)),a.ea-1)};c.prototype.nr=function(a){a=Math.round(a);this.Mc=0<(a&1);this.Rf=0<(a&2);this.lj=0<(a&4);this.Sf=0<(a&8);4096<=a&&(this.hd=0<(a&4096),this.ia=0<(a&8192),this.Fh=0<(a&32768))};c.prototype.Qp=
function(){var a=0;this.Mc&&(a|=1);this.Rf&&(a|=2);this.lj&&(a|=4);this.hd&&(a|=4096);this.ia&&(a|=8192);this.Fh&&(a|=32768);return a};c.prototype.Tn=function(){if(!(6>this.cube.faces.length))for(var a=0;6>a;a++){var b=this.cube.faces[a];var e=[];e.push(new r.Ha(-1,-1,-1,0,0));e.push(new r.Ha(1,-1,-1,1,0));e.push(new r.Ha(1,1,-1,1,1));e.push(new r.Ha(-1,1,-1,0,1));for(var f=0;4>f;f++)4>a?e[f].La(-Math.PI/2*a):e[f].Ga(Math.PI/2*(4==a?-1:1)),this.Oa&&(e[f].lb(this.Oa.V*Math.PI/180),e[f].Ga(-this.Oa.pitch*
Math.PI/180)),e[f].Ue(-this.pan.m),e[f].Od(this.A.m),e[f].Ve(this.V.m);e=this.Bj(e);b.qb=0<e.length;if(b.qb){b=b.Mf;b.Bg=e[0].yd;b.dh=e[0].yd;b.Cg=e[0].ac;b.eh=e[0].ac;for(f=1;f<e.length;f++)b.Bg=Math.min(b.Bg,e[f].yd),b.dh=Math.max(b.dh,e[f].yd),b.Cg=Math.min(b.Cg,e[f].ac),b.eh=Math.max(b.eh,e[f].ac);b.fg=b.dh-b.Bg;b.Kh=b.eh-b.Cg;b.scale=Math.max(b.fg,b.Kh)}else b.Mf.fg=-1,b.Mf.Kh=-1}};c.prototype.pk=function(){for(var a=0;a<this.v.levels.length;a++){var b=this.v.levels[a],e;for(e in b.ba)b.ba.hasOwnProperty(e)&&
(b.ba[e].visible=!1)}};c.prototype.Qj=function(){var a=0,b=Math.tan(Math.min(this.Tb(),175)*Math.PI/360),e=this.D.height/(2*b);e*=1+this.D.width/this.D.height*b/2;for(e*=Math.pow(2,1<this.devicePixelRatio?this.v.Mm:this.v.Lm);this.v.levels.length>=a+2&&!this.v.levels[a+1].Se&&this.v.levels[a+1].width>e;)a++;return a};c.prototype.gs=function(){var a=!1,b,e,f;if(this.D.width!==this.L.offsetWidth||this.D.height!==this.L.offsetHeight)this.D.width=this.L.offsetWidth,this.D.height=this.L.offsetHeight,this.L.style[this.Va+
"OriginX"]=this.D.width/2+"px",this.L.style[this.Va+"OriginY"]=this.D.height/2+"px",a=!0;var g=Math.round(this.pd());if(this.Wg!=g||a)this.Wg=g,this.Mc||(this.L.style[this.Cd]=g+"px",this.L.style[this.Cd+"Origin"]="50% 50%");this.Cc=0;if(0<this.v.levels.length){this.Tn();this.pk();var h="";for(b=0;6>b;b++){var l=this.cube.faces[b];l.qb&&(h=h+b+",")}h=this.Qj();var k;for(k=this.v.levels.length-1;k>=h;){a=this.v.levels[k];var q=1;k==this.v.levels.length-1&&0==this.v.Ea&&(q=this.v.N/(this.v.N-2));for(b=
0;6>b;b++){l=this.cube.faces[b];var p=l.Mf;if(l.qb&&0<p.fg&&0<p.Kh&&0<p.scale||a.cache){l.Na=!1;var w={};a.cache?(w.jb=0,w.Gb=0,w.Ib=a.U-1,w.Jb=a.ea-1):this.lm(a,p,w);for(f=w.Gb;f<=w.Jb;f++)for(e=w.jb;e<=w.Ib;e++){var x=e+f*a.U+b*a.U*a.ea;(p=a.ba[x])||(p=a.ba[x]=new r.Sd);if(!p.W&&this.$b<this.zh){if(0<this.hj.length){p.W=this.hj.shift();for(x=this.L.firstChild;x&&x.$d&&(-1==x.$d||x.$d>=k);)x=x.nextSibling;this.L.insertBefore(p.W,x);p.cb=p.W.getContext("2d")}else if(this.Ln<this.Oe){this.Ln++;p.W=
document.createElement("canvas");p.W.width=this.v.N+2*this.v.Ea;p.W.height=this.v.N+2*this.v.Ea;p.cb=p.W.getContext("2d");p.W.style[this.Va+"Origin"]="0% 0%";p.W.style.overflow="hidden";p.W.style.position="absolute";for(x=this.L.firstChild;x&&x.$d&&(-1==x.$d||x.$d>=k);)x=x.nextSibling;this.L.insertBefore(p.W,x)}p.W&&(this.ek++,p.v=new Image,p.v.crossOrigin=this.crossOrigin,p.v.style[this.Va+"Origin"]="0% 0%",p.v.style.position="absolute",p.v.style.overflow="hidden",p.W.$d=k,p.v.onload=this.Rr(p),
p.v.onerror=this.ej(p),p.v.onabort=this.ej(p),p.v.setAttribute("src",this.ne(b,k,e,f)),a.cache&&this.gc.push(p.v),this.$b++,this.Na=!0)}else this.Cc++;if(p.W){x="";this.Mc?(x+="translate3d("+this.D.width/2+"px,"+this.D.height/2+"px,0px) ",x+=" perspective("+g+"px) ",x+="translate3d(0px,0px,"+g+"px) "):x+="translate3d("+this.D.width/2+"px,"+this.D.height/2+"px,"+g+"px) ";x+="rotateZ("+Number(this.V.m).toFixed(10)+"deg) ";x+="rotateX("+Number(this.A.m).toFixed(10)+"deg) ";x+="rotateY("+Number(-this.pan.m).toFixed(10)+
"deg) ";this.Oa&&(x+="rotateX("+Number(-this.Oa.pitch).toFixed(10)+"deg) ",x+="rotateZ("+Number(this.Oa.V).toFixed(10)+"deg) ");x=4>b?x+("rotateY("+-90*b+"deg) "):x+("rotateX("+(4==b?-90:90)+"deg) ");if(this.Rf){var y=this.v.N/a.width*(2*k+1)*(this.mg/this.v.N);y=this.yc?2/Math.tan(this.fov.m*Math.PI/360)*y:2*y;x+=" scale("+y*q*q+")"}else y=1/(q*q);x+=" translate3d("+(1/q*e*this.v.N-this.v.Ea-a.width/2)+"px,";x+=1/q*f*this.v.N-this.v.Ea-a.width/2+"px,";x+=-a.width*y/2+"px)";l.qb&&(p.visible=!0,p.W?
p.W.style[this.Va]=x:p.v&&(p.v.style[this.Va]=x))}}}}k--}for(g=0;g<this.v.levels.length;g++){a=this.v.levels[g];for(var z in a.ba)a.ba.hasOwnProperty(z)&&(p=a.ba[z],!p.visible&&p.W&&(a.cache?p.W?p.W.style[this.Va]="translate3d(-10px,-10px,0px) scale(0.001,0.001)":p.v&&(p.v.style[this.Va]=""):(p.cb&&p.cb.clearRect(0,0,p.cb.canvas.width,p.cb.canvas.height),this.hj.push(p.W),p.W?(h="translate3d(-10px,-10px,0px) scale(0.001,0.001)",p.W.style[this.Va]=h,p.W.$d=-1):p.loaded&&this.L.removeChild(p.v),p.W=
null,p.v=null,p.cb=null,delete a.ba[z])))}this.nd=!1}};c.prototype.Rn=function(){var a=Math.round(this.pd());this.Mc||this.Qn(a);for(var b=0;b<this.fb.length;b++){var e=this.fb[b];e.Un(a);e.j.hidden=!1}};c.prototype.Vn=function(){for(var a=Math.round(this.pd()),b=0;b<this.T.length;b++){var e=this.T[b];e.cd||(e.Un(a),e.j.hidden=!1)}};c.prototype.fq=function(){for(var a=0;a<this.fb.length;a++){var b=this.fb[a];b.Wf(!1)}for(a=0;a<this.T.length;a++)b=this.T[a],b.cd||b.Wf(!1)};c.prototype.ls=function(){for(var a=
0;a<this.T.length;a++){var b=this.T[a];b.cd||b.df()}for(a=0;a<this.fb.length;a++)b=this.fb[a],b.df()};c.prototype.ad=function(a){this.Ee=!1;try{this.ab=a?a:document.createElement("canvas");var b=this.ld.offsetWidth-this.margin.left-this.margin.right,e=this.ld.offsetHeight-this.margin.top-this.margin.bottom;if(100>b||100>e)e=b=100;var f=window.devicePixelRatio||1;this.Sf&&(f=1);this.L.style.width=b+"px";this.L.style.height=e+"px";this.ab.style.width=b+"px";this.ab.style.height=e+"px";this.ab.width=
b*f;this.ab.height=e*f;this.ab.style.display="none";this.ab.style.touchAction="none";this.L.insertBefore(this.ab,this.L.firstChild);var g=this.bo;g.stencil=!0;g.depth=!0;g.powerPreference="high-performance";g.alpha=this.yc?!0:!1;this.Id&&10<=this.Og[0]&&(g.antialias=!1,g.alpha=!1);a={};a.flags=g;a.canvas=this.ab;this.R("beforewebglcontext",a);this.S=this.ab.getContext("webgl",g);this.S||(this.S=this.ab.getContext("experimental-webgl",g));if(this.S){var h=this.S;this.zb.width=b*f;this.zb.height=e*
f;h.clearColor(0,0,0,0);h.enable(this.S.DEPTH_TEST);h.viewport(0,0,500,500);h.clear(h.COLOR_BUFFER_BIT|h.DEPTH_BUFFER_BIT);4096<=h.getParameter(h.MAX_TEXTURE_SIZE)&&!this.Sg&&(this.Oe=1<f?4*this.Oe:2*this.Oe);this.O("Max tile cnt: "+this.Oe);this.za.Pg();this.za.oi();this.za.vm(this.bf);this.za.wm();this.K&&(this.K.Pg(),this.K.ad());this.Ta&&(this.Ta.Pg(),this.Ta.ad())}}catch(l){this.O(l)}this.S?(this.ia=!0,this.R("webglready",{gl:this.S})):alert("Could not initialise WebGL!")};c.prototype.Pb=function(a){return a?
"{"==a.charAt(0)||"/"==a.charAt(0)||0<a.indexOf("://")||0==a.indexOf("javascript:")?a:this.Vd+a:this.Vd};c.prototype.Mb=function(a,b,e){var f=(new RegExp("%0*"+b,"i")).exec(a.toString());if(f){f=f.toString();var g=e.toString();f.charAt(f.length-1)!=b&&(g=(1+e).toString());if(!isNaN(parseFloat(e)))for(;g.length<f.length-1;)g="0"+g;a=a.replace(f,g)}return a};c.prototype.ne=function(a,b,e,f,g){var h=this.v.kk-1-b,l=this.v.mk,k="x";switch(a){case 0:k="f";break;case 1:k="r";break;case 2:k="b";break;case 3:k=
"l";break;case 4:k="u";break;case 5:k="d";break;case "vr":k="vr"}g&&(a+="l",k+="l");for(g=0;3>g;g++)l=this.Mb(l,"c",a),l=this.Mb(l,"s",k),l=this.Mb(l,"r",b),l=this.Mb(l,"l",h),l=this.Mb(l,"x",e),l=this.Mb(l,"y",f),l=this.Mb(l,"v",f),l=this.Mb(l,"h",e);return this.Pb(l)};c.prototype.Hg=function(){return this.pan.m};c.prototype.Kp=function(){return this.G.pan};c.prototype.em=function(){for(var a=this.pan.m;-180>a;)a+=360;for(;180<a;)a-=360;return a};c.prototype.Ge=function(){for(var a=this.pan.m-this.pan.tk;-180>
a;)a+=360;for(;180<a;)a-=360;return a};c.prototype.Xe=function(a){this.Fa();isNaN(a)||(this.pan.m=Number(a));this.update()};c.prototype.Gk=function(a){this.Fa();isNaN(a)||(this.pan.m=Number(a)+this.pan.tk);this.update()};c.prototype.ql=function(a,b){isNaN(a)||(this.Xe(this.Hg()+a),b&&(this.pan.d=a))};c.prototype.Ko=function(a,b){this.ql(a*this.ei(),b)};c.prototype.ii=function(){return this.A.m};c.prototype.Rp=function(){return this.G.A};c.prototype.Ye=function(a){this.Fa();isNaN(a)||(this.A.m=Number(a));
this.update()};c.prototype.sl=function(a,b){this.Ye(this.ii()+a);b&&(this.A.d=a)};c.prototype.Mo=function(a,b){this.sl(a*this.ei(),b)};c.prototype.Ui=function(a){this.Fa();isNaN(a)||(this.V.m=Number(a));this.update()};c.prototype.im=function(){return this.V.m};c.prototype.Vj=function(){return this.fov.m};c.prototype.kp=function(){return this.G.Rd};c.prototype.We=function(a){this.Fa();switch(this.Sa()){case 4:var b=170;break;case 12:b=360;break;case 9:b=355;break;default:b=170}2==this.Xa&&(b=9999999999);
!isNaN(a)&&0<a&&a<b&&(b=this.fov.m,this.fov.m=1*a,b!=this.fov.m&&this.update())};c.prototype.pl=function(a,b){this.We(this.Vj()+a);b&&(this.fov.d=a)};c.prototype.yj=function(a,b){if(!isNaN(a)){var e=a/90*Math.cos(Math.min(this.fov.m,90)*Math.PI/360);e=this.fov.m*Math.exp(e);this.We(e);b&&(this.fov.d=a)}};c.prototype.lr=function(a,b){this.Fa();isNaN(a)||(this.pan.m=a);isNaN(b)||(this.A.m=b);this.update()};c.prototype.mr=function(a,b,e){this.Fa();!isNaN(a)&&1E7>a&&-1E7<a&&(this.pan.m=a);!isNaN(b)&&
1E7>b&&-1E7<b&&(this.A.m=b);!isNaN(e)&&1E7>e&&-1E7<e&&(this.V.m=e);this.update()};c.prototype.Ti=function(a,b,e){this.Fa();isNaN(a)||(this.pan.m=a);isNaN(b)||(this.A.m=b);isNaN(e)||this.We(e);this.update()};c.prototype.gr=function(){this.Ti(this.pan.eb,this.A.eb,this.fov.eb)};c.prototype.setLocked=function(a){this.vn(a);this.wn(a);this.un(a)};c.prototype.vn=function(a){this.M.jc=a};c.prototype.un=function(a){this.M.bh=a};c.prototype.xp=function(){return this.M.bh};c.prototype.wn=function(a){this.M.be=
a};c.prototype.Ri=function(a){this.oc=a};c.prototype.lp=function(){return this.ck()?!0:this.Zj};c.prototype.zr=function(a,b){void 0===b&&(b=!0);this.Xn=b;this.cg==!a&&(a&&this.ck()?this.ln():((this.cg=!!a)?this.kb.rh=!0:this.V.m=0,this.R("gyrochanged",{}),this.R("playerstatechanged",{})))};c.prototype.ck=function(){return window.hasOwnProperty("DeviceOrientationEvent")&&DeviceOrientationEvent.hasOwnProperty("requestPermission")&&"function"===typeof DeviceMotionEvent.requestPermission?!0:!1};c.prototype.ln=
function(){var a=this;if(this.ck())DeviceOrientationEvent.requestPermission().then(function(b){"granted"===b&&(a.kb.rh=!0,a.cg=!0,a.R("gyrochanged",{}),a.R("playerstatechanged",{}))})["catch"](console.error)};c.prototype.Sp=function(){return this.cg};c.prototype.Jp=function(){return this.Qg?5:this.Id?4:this.Dm?1:this.Bm?2:this.Am?3:0};c.prototype.ip=function(){return this.hk?5:this.Le?4:this.si?2:this.yc?3:this.gk?1:0};c.prototype.moveTo=function(a,b,e,f,g,h){this.Fa();if("_blank"!==a&&""!==a){this.G.active=
!0;this.G.aborted=!1;this.G.Wk=!1;var l=a.toString().split("/");1<l.length&&(a=Number(l[0]),f=Number(b),b=Number(l[1]),2<l.length&&(e=Number(l[2])));this.G.pan=isNaN(a)?this.pan.m:Number(a);this.G.A=isNaN(b)?this.A.m:Number(b);this.G.fov=!isNaN(e)&&0<e&&180>e?Number(e):this.fov.m;this.G.speed=!isNaN(f)&&0<f?Number(f):1;this.G.V=isNaN(g)?this.V.m:Number(g);void 0!==h?!a||4!=h&&12!=h&&9!=h||(this.G.Lb=h):this.G.Lb=this.Wa}};c.prototype.Ei=function(a){this.Fa();var b=0,e=0,f=70,g=4,h=0,l=1;a.hasOwnProperty("pan")&&
(b=Number(a.pan),this.G.pan=b);a.hasOwnProperty("tilt")&&(e=Number(a.tilt),this.G.A=e);a.hasOwnProperty("fov")&&(f=Number(a.fov),this.G.fov=f);a.hasOwnProperty("projection")&&(g=Number(a.projection),this.G.Lb=g);a.hasOwnProperty("timingFunction")&&(h=Number(a.timingFunction));a.hasOwnProperty("speed")&&(l=Number(a.speed));0>=l?(this.Ti(b,e,f),this.Nc(g)):(a=new r.al,a.bb="__AutoMove",a.le=this.em(),a.vh=this.A.m,a.Pd=this.fov.m,a.uh=this.Wa,a.Qd=b,a.me=e,a.Yf=f,a.wd=g,a.rf=!1,a.Be=!1,a.Ce=!1,0==h&&
(a.Be=!0),1==h&&(a.rf=!0,a.Be=!0),2==h&&(a.Ce=!0),a.speed=l,this.G.il=this.J,this.J=this.Tl(a),this.G.jl=(new Date).getTime(),this.G.Wk=!0,this.G.active=!0,this.G.aborted=!1,this.G.pan=b,this.G.A=e,this.G.fov=f,this.Td=!1)};c.prototype.vq=function(a){this.moveTo(this.pan.eb,this.A.eb,this.fov.eb,a)};c.prototype.wq=function(a,b){var e={};e.pan=this.pan.eb;e.tilt=this.A.eb;e.fov=this.fov.eb;e.projection=this.Ki;e.timingFunction=b;e.speed=a;this.Ei(e)};c.prototype.wo=function(a,b,e,f){var g=new r.Oh(this);
g.type="point";g.pan=b;g.A=e;g.id=a;g.j={};g.j.player=this;g.tf();g.j.hotspot=g;g.j.__div=document.createElement("div");g.j.__div.appendChild(f);this.X.push(g);g.j.__div.style.position="absolute";g.j.__div.style.left="-1000px";g.j.__div.style.top="-1000px";this.Ra.insertBefore(g.j.__div,this.Ra.firstChild);this.Na=!0};c.prototype.ds=function(a,b,e){for(var f=0;f<this.X.length;f++){var g=this.X[f];g.id==a&&(g.pan=b,g.A=e,g.tf())}this.Na=!0};c.prototype.Xq=function(a){for(var b=-1,e,f=0;f<this.X.length;f++)e=
this.X[f],e.id==a&&(b=f);-1<b&&(e=this.X.splice(b,1).pop(),e.j&&e.j.__div&&this.Ra.removeChild(e.j.__div))};c.prototype.Mp=function(){for(var a=[],b=0;b<this.X.length;b++){var e=this.X[b];"point"==e.type&&a.push(String(e.id))}return a};c.prototype.op=function(a){for(var b=0;b<this.X.length;b++){var e=this.X[b];if(e.id==a)return b={},b.id=a,b.pan=e.pan,b.tilt=e.A,b.url=e.url,b.target=e.target,b.distance=e.distance,b.title=e.title,b.description=e.description,b.skinid=e.Kk,e.Wc&&(b.customimage=e.Wc,
b.customimagewidth=e.Ae,b.customimageheight=e.Bd,b.use3D=e.bg,b.distance3D=e.$h),e.j&&e.j.__div&&(b.div=e.j.__div),b}};c.prototype.$n=function(a,b){this.ga.start.x=a;this.ga.start.y=b;this.ga.oa.x=a;this.ga.oa.y=b;this.Ka.oa.x=a;this.Ka.oa.y=b;this.zk++;this.pan.Vc=this.pan.m;this.A.Vc=this.A.m};c.prototype.Yn=function(a,b){var e=this.Tb();this.pan.Vc+=a*e/this.D.height;this.A.Vc+=b*e/this.D.height;this.pan.m=this.pan.Vc;this.A.m=this.A.Vc};c.prototype.Zn=function(a,b){this.ga.m.x=a;this.ga.m.y=b;
this.ga.na.x=this.ga.m.x-this.ga.oa.x;this.ga.na.y=this.ga.m.y-this.ga.oa.y;this.M.Hd&&(this.ga.oa.x=this.ga.m.x,this.ga.oa.y=this.ga.m.y,this.update())};c.prototype.Fa=function(){this.C.active&&(this.C.active=!1,this.R("autorotatechanged",{}),this.pan.d=0,this.A.d=0,this.fov.d=0);this.G.active&&(this.G.active=!1,this.pan.d=0,this.A.d=0,this.fov.d=0);this.gf=this.G.aborted=!1;this.C.Di=!1;this.zd=.02;this.jg=0;this.C.dg&&(this.C.enabled=this.C.jf);this.Ff=(new Date).getTime()};c.prototype.vp=function(){return this.Ff};
c.prototype.fm=function(a,b){a||(a=this.pa.x,b=this.pa.y);var e=this.D.height/(2*Math.tan(this.fov.m*Math.PI/360));a-=this.D.width/2;b-=this.D.height/2;var f={};f.pan=180*Math.atan(a/e)/Math.PI;f.tilt=180*Math.atan(-b/Math.sqrt(a*a+e*e))/Math.PI;return f};c.prototype.Op=function(a,b){a||(a=this.pa.x,b=this.pa.y);if(2===this.Xa){var e=this.fov.m/this.D.height;a=-(a-this.D.width/2)*e+this.pan.m;b=-(b-this.D.height/2)*e+this.A.m}else{e=new r.Ha(0,0,1);a=this.fm(a,b);e.Od(-a.tilt);e.Ue(a.pan);e.Od(-this.A.m);
e.Ue(-this.pan.m);e.Od(-this.Oa.pitch);e.Ve(this.Oa.V);for(a=e.Co()-180;-180>a;)a+=360;b=e.Do()}e={};e.pan=a;e.tilt=b;return e};c.prototype.Ic=function(a){return a==this.control||a&&void 0!==a.ggPermeableMap&&1==a.ggPermeableMap?!0:a&&void 0!==a.ggPermeable&&0==a.ggPermeable?!1:a&&a.ggType&&("container"==a.ggType||"cloner"==a.ggType||"timer"==a.ggType)?!0:!1};c.prototype.Aj=function(a,b){var e=this.pd(),f,g;for(f=0;f<this.T.length+this.fb.length;f++){var h=f<this.T.length?this.T[f]:this.fb[f-this.T.length];
if(h.pb)return h}for(f=0;f<this.T.length+this.fb.length;f++)if(h=f<this.T.length?this.T[f]:this.fb[f-this.T.length],!h.cd){var l=[],k=new r.Ha,q;var p=g=void 0;0<h.fov&&(g=Math.tan(h.fov/2*Math.PI/180),p=0<h.xc?g*h.$c/h.xc:g,h.Gc&&1!=h.Gc&&(p*=h.Gc));for(q=0;4>q;q++){switch(q){case 0:k.init(-g,-p,0);break;case 1:k.init(g,-p,0);break;case 2:k.init(g,p,0);break;case 3:k.init(-g,p,0)}k.Ga(h.Ga*Math.PI/180);k.La(-h.La*Math.PI/180);k.lb(h.lb*Math.PI/180);--k.z;k.Ga(-h.A*Math.PI/180);k.La(h.pan*Math.PI/
180);k.La(-this.pan.m*Math.PI/180);k.Ga(this.A.m*Math.PI/180);k.lb(this.V.m*Math.PI/180);l.push(k.clone())}l=this.Bj(l);if(0<l.length){for(q=0;q<l.length;q++)k=l[q],.1>k.z?(p=-e/k.z,g=this.D.width/2+k.x*p,p=this.D.height/2+k.y*p):p=g=0,k.Xb=g,k.Cb=p;if(this.tm(l,a,b))return h}}return null};c.prototype.ti=function(){return document.webkitIsFullScreen||document.mozFullScreen||document.msFullscreenElement&&null!=document.msFullscreenElement||document.fullScreen};c.prototype.uq=function(a){this.Sn(a);
if(this.od)this.od.onclick();(this.uf||this.vf&&this.Le)&&this.di();this.Ob=null;if(!this.M.jc&&!this.oc){a=a?a:window.event;if(a.which||0==a.which||1==a.which){var b=(new Date).getTime();if(this.he){this.Ob=this.he;this.Z.Lc=!0;this.Z.startTime=b;a.stopPropagation();return}if(this.Ic(a.target)){var e;(e=this.Aj(this.pa.x,this.pa.y))&&e.Ie&&(this.Ob=e);this.$n(a.pageX,a.pageY);this.Z.Lc=!0;this.Z.startTime=b;a.preventDefault();this.Fa()}}this.ga.na.x=0;this.ga.na.y=0}};c.prototype.ag=function(a,b){var e=
this.I.cj;e.enabled&&(this.Da!=this.ob&&0<=a&&0<=b&&""!=this.Da.title?(this.Ia.innerHTML=this.Da.title,this.Ia.style.color=this.fa(e.dj,e.bj),this.Ia.style.backgroundColor=e.background?this.fa(e.cc,e.bc):"transparent",this.Ia.style.border="solid "+this.fa(e.ec,e.dc)+" "+e.Uh+"px",this.Ia.style.borderRadius=e.tj+"px",this.Ia.style.textAlign="center",0<e.width?(this.Ia.style.left=a-e.width/2+this.margin.left+"px",this.Ia.style.width=e.width+"px"):(this.Ia.style.width="auto",this.Ia.style.left=a-this.Ia.offsetWidth/
2+this.margin.left+"px"),this.Ia.style.height=0<e.height?e.height+"px":"auto",this.Ia.style.top=b+25+ +this.margin.top+"px",this.Ia.style.visibility="inherit",this.Ia.style.overflow="hidden"):(this.Ia.style.visibility="hidden",this.Ia.innerHTML=""))};c.prototype.Sn=function(a){var b=this.He();this.ti()?(this.pa.x=a.pageX-this.margin.left,this.pa.y=a.pageY-this.margin.top):(this.pa.x=a.pageX-b.x,this.pa.y=a.pageY-b.y);return b};c.prototype.Uf=function(a){this.Da=a&&null!==a&&"object"==typeof a?a:this.ob;
this.Da==this.ob&&(a=this.Vh(this.pa.x,this.pa.y))&&(a.nb=0);this.Da.tf&&this.Da.tf();this.hotspot=this.Da;this.R("activehotspotchanged",{hotspot:this.Da})};c.prototype.tq=function(a){a=a?a:window.event;var b=this.Sn(a);if(!this.M.jc&&!this.oc&&!this.he){this.C.active&&(this.C.zi=(new Date).getTime());0==a.buttons&&(this.Z.Lc=!1);this.Z.Lc&&(a.preventDefault(),(a.which||0==a.which||1==a.which)&&this.Zn(a.pageX,a.pageY),this.Fa());var e=!1;if(this.Da==this.ob||"poly"==this.Da.type){var f=this.ob;0<
this.X.length&&this.Ic(a.target)&&(f=this.Vh(this.pa.x,this.pa.y));this.Qi(f);this.ag(a.pageX-b.x,a.pageY-b.y);0!=f&&f!=this.ob&&(e=!0)}b=null;!e&&this.Ic(a.target)&&(b=this.Aj(this.pa.x,this.pa.y));this.C.Yh&&(this.C.Yh=!1);this.Ra.style.cursor=this.Da!=this.ob&&this.Da.zf&&e||b&&b.Ng?"pointer":"default"}};c.prototype.Qi=function(a){!1===a&&(a=this.ob);this.Da!=a&&(this.Da!=this.ob&&(0<this.I.mode&&(this.Da.nb=0),this.la&&this.la.hotspotProxyOut&&this.la.hotspotProxyOut(this.Da.id,this.Da.url)),
a!=this.ob?(this.Uf(a),this.la&&this.la.hotspotProxyOver&&this.la.hotspotProxyOver(this.Da.id,this.Da.url),0<this.I.mode&&(this.I.nb=1,this.Da.nb=1)):(this.Uf(this.ob),0<this.I.mode&&(this.I.nb=0)),this.ra&&this.ra.changeCurrentHotspot(this.Da.id))};c.prototype.sq=function(a){a=a?a:window.event;this.yi=-1;(this.uf||this.vf&&this.Le)&&this.di();if(!this.M.jc&&!this.oc&&(this.Ob&&(this.Ob.Ie(),this.he=this.Ob.pb?this.Ob:null),this.Z.Lc)){this.Fa();a.preventDefault();this.Z.Lc=!1;a=(new Date).getTime();
var b=Math.abs(this.ga.start.x-this.ga.oa.x)+Math.abs(this.ga.start.y-this.ga.oa.y);if(400>a-this.Z.startTime&&0<=b&&20>b){var e=this.Vh(this.pa.x,this.pa.y);e&&this.On(e);b=Math.abs(this.ga.Ld.x-this.ga.oa.x)+Math.abs(this.ga.Ld.y-this.ga.oa.y);700>a-this.Ug&&0<=b&&20>b?(e?this.Pn(e):this.M.Kj&&this.gj(),this.Ug=0):this.Ug=a;this.ga.Ld.x=this.ga.oa.x;this.ga.Ld.y=this.ga.oa.y}}};c.prototype.Nm=function(a){if(!this.M.be&&!this.oc&&(a=a?a:window.event,this.Ic(a.target))){var b=a.detail?-1*a.detail:
a.wheelDelta/40;this.M.xm&&(b=-b);a.axis&&(-1==this.yi?this.yi=a.axis:this.yi!=a.axis&&(b=0));var e=0<b?1:-1;a.wheelDeltaX&&a.wheelDeltaY&&Math.abs(a.wheelDeltaX)>Math.abs(a.wheelDeltaY)&&(b=0);0!=b&&(this.yj(e*this.M.Dn,!0),this.update());a.preventDefault();this.Fa()}};c.prototype.Zr=function(a){a||(a=window.event);var b=a.touches,e=this.He();this.pa.x=b[0].pageX-e.x;this.pa.y=b[0].pageY-e.y;this.oe=this.Ob=null;this.li||(this.li=!0,this.R("hastouch",{}));(this.uf||this.vf&&this.Le)&&this.di();if(!this.M.jc&&
!this.oc){var f=(new Date).getTime();if(this.he)this.Ob=this.he,this.Z.Yc=!0,this.Z.startTime=f,a.preventDefault(),this.Z.nh=!0;else{if(!this.Z.Yc&&b[0]){this.Z.startTime=f;this.Z.start.x=b[0].pageX;this.Z.start.y=b[0].pageY;this.Z.oa.x=b[0].pageX;this.Z.oa.y=b[0].pageY;this.vb=b[0].target;if(this.Ic(this.vb)){(f=this.Aj(this.pa.x,this.pa.y))&&f.Ie&&(this.Ob=f);if(f=this.Vh(this.pa.x,this.pa.y))this.O(f),this.oe=f,this.Qi(f),f=this.Fg(a),this.ag(f.x-e.x,f.y-e.y);this.$n(b[0].pageX,b[0].pageY);this.Z.Ml=
b[0].identifier;this.Z.Yc=!0;a.preventDefault();this.Z.nh=!0;this.Fa()}if(this.vb){e=this.vb;for(f=!1;e&&e!=this.control;){if(e.onmouseover)e.onmouseover();e.onmousedown&&!f&&(e.onmousedown(),f=!0);e=e.parentNode}f&&(a.preventDefault(),this.Z.nh=!0)}}1<b.length&&(this.Z.Yc=!1);!this.ak&&2==b.length&&b[0]&&b[1]&&this.Ic(this.vb)&&(a=b[0].pageX-b[1].pageX,b=b[0].pageY-b[1].pageY,this.fov.En=Math.sqrt(a*a+b*b),this.fov.prev=this.fov.m);this.ga.na.x=0;this.ga.na.y=0}}};c.prototype.di=function(){try{this.Gh&&
this.F.j&&(!this.F.td&&this.F.Mk&&this.F.j.play(),this.F.j.muted=!1);if(this.wa&&(this.wa.resume(),"suspended"==this.wa.state))return;if(this.Id&&this.wa&&this.wa.createOscillator){var a=this.wa.createOscillator(),b=this.wa.createGain();a.frequency.value=30;a.type="sine";a.connect(b);b.connect(this.wa.destination);b.gain.value=.01;a.start(0);setTimeout(function(){a.stop()},1E4)}for(b=0;b<this.Y.length;b++){var e=this.Y[b];(!this.isPlaying(e.id)||e.va)&&0<=e.loop&&e.autoplay&&(e.va&&e.mf(),this.fe(e.id,
e.loop))}for(b=0;b<this.T.length;b++){var f=this.T[b];!this.isPlaying(f.id)&&f.autoplay&&this.Gh&&this.fe(f.id,f.loop);this.isPlaying(f.id)&&f.autoplay&&this.Gh&&(f.se&&(this.Le?f.Ph():this.fe(f.id)),f.j.muted=!1)}this.vf=this.uf=!1}catch(g){this.O(g)}};c.prototype.Yr=function(a){a||(a=window.event);var b=a.touches,e=this.He();this.pa.x=b[0].pageX-e.x;this.pa.y=b[0].pageY-e.y;if(this.M.jc||this.oc)(this.K.xd||this.K.qe)&&a.preventDefault();else{b[0]&&(this.Z.oa.x=b[0].pageX,this.Z.oa.y=b[0].pageY);
if(this.vb){for(var f=this.vb,g=!1;f&&f!=this.control&&!g;)"scrollarea"==f.ggType&&(g=!0),"map"==f.ggType&&(g=!0),"text"==f.ggType&&(g=!0),f=f.parentNode;g||a.preventDefault()}if(this.Z.Yc){a.preventDefault();for(f=0;f<b.length;f++)if(b[f].identifier==this.Z.Ml){this.Zn(b[f].pageX,b[f].pageY);break}this.oe&&(f=this.Fg(a),this.ag(f.x-e.x,f.y-e.y));this.Fa()}2==b.length&&b[0]&&b[1]&&(this.Z.Yc=!1,!this.ak&&this.Ic(this.vb)&&(this.M.be||(e=b[0].pageX-b[1].pageX,b=b[0].pageY-b[1].pageY,this.fov.Bl=Math.sqrt(e*
e+b*b),this.Ka.fov.active=!0,this.Ka.fov.wc=this.fov.prev*Math.sqrt(this.fov.En/this.fov.Bl),4==this.Sa()&&2!=this.Xa&&this.Ka.fov.wc>this.fov.max&&(this.Ka.fov.wc=this.fov.max),this.Ka.fov.wc<this.fov.min&&(this.Ka.fov.wc=this.fov.min)),this.Fa(),a.preventDefault()))}};c.prototype.Xr=function(a){this.Z.nh&&(this.Z.nh=!1,a.preventDefault());var b=this.He(),e=!1;(this.uf||this.vf&&this.Le)&&this.di();if(!this.M.jc&&!this.oc){this.Z.Yc&&(a.preventDefault(),this.Fa());var f=(new Date).getTime();var g=
void 0;var h=!1;g=Math.abs(this.Z.start.x-this.Z.oa.x)+Math.abs(this.Z.start.y-this.Z.oa.y);if(0<=g&&20>g){e=!0;this.Ic(this.vb)&&(a.preventDefault(),this.Ob&&(this.Ob.Ie(),this.he=this.Ob.pb?this.Ob:null));if(this.vb){for(g=this.vb;g&&g!=this.control;)g.onclick&&(g.onclick(),h=!0,e=!1),g=g.parentNode;h&&a.preventDefault()}g=Math.abs(this.Z.Ld.x-this.Z.oa.x)+Math.abs(this.Z.Ld.y-this.Z.oa.y);if(700>f-this.Ug&&0<=g&&20>g){if(this.Ic(this.vb))if(a.preventDefault(),this.oe)this.Pn(this.oe);else if(this.M.Kj){var l=
this;setTimeout(function(){l.gj()},1)}if(this.vb){for(g=this.vb;g&&g!=this.control;)g.ondblclick&&(g.ondblclick(),h=!0,e=!1),g=g.parentNode;h&&a.preventDefault()}this.Ug=0}else this.Ug=f;this.Z.Ld.x=this.Z.oa.x;this.Z.Ld.y=this.Z.oa.y}if(this.vb)for(g=this.vb;g&&g!=this.control;){if(g.onmouseout)g.onmouseout();if(g.onmouseup)g.onmouseup();g=g.parentNode}a=this.Fg(a);this.ag(a.x-b.x,a.y-b.y);this.oe&&e&&this.On(this.oe);this.vb=null;this.Z.Yc=!1;this.Qi(this.ob);this.oe=null}};c.prototype.Wr=function(a){var b=
this.He();this.M.jc||this.oc||(this.Z.Yc=!1);this.oe=null;this.Qi(this.ob);a=this.Fg(a);this.ag(a.x-b.x,a.y-b.y)};c.prototype.Cm=function(){return null!=this.vb||this.Z.Yc||this.Z.Lc};c.prototype.Om=function(a){!this.Pe&&window.MSGesture&&(this.O("setup gesture"),this.Pe=new MSGesture,this.Pe.target=this.control);this.Pe&&this.Pe.addPointer(a.pointerId)};c.prototype.Vl=function(a){this.ak=!0;this.Fi=1;this.M.jc||this.M.be||this.oc||(a.touches?(this.vb=a.touches.target,this.Ic(a.target)&&(a.preventDefault(),
this.fov.prev=this.fov.m,this.Fa())):(a.preventDefault(),this.fov.prev=this.fov.m,this.Fa()))};c.prototype.gp=function(a){this.M.jc||this.M.be||this.oc||!this.Ic(a.target)||(a.preventDefault(),this.Ka.fov.active=!0,this.Ka.fov.wc=this.fov.prev/Math.sqrt(a.scale),4==this.Sa()&&2!=this.Xa&&this.Ka.fov.wc>this.fov.max&&(this.Ka.fov.wc=this.fov.max),this.update(),this.Fa())};c.prototype.xq=function(a){this.M.jc||this.M.be||this.oc||(a.preventDefault(),1!=a.scale&&(this.Ka.fov.active=!0,this.Fi*=a.scale,
this.Ka.fov.wc=this.fov.prev/Math.sqrt(this.Fi),4==this.Sa()&&2!=this.Xa&&this.Ka.fov.wc>this.fov.max&&(this.Ka.fov.wc=this.fov.max),this.update(),this.Fa()))};c.prototype.Ul=function(a){this.M.jc||this.M.be||this.oc||(this.Ka.fov.active=!1,a.preventDefault(),this.Fa(),this.Pe&&this.Pe.reset&&this.Pe.reset())};c.prototype.kq=function(a){this.M.bh||this.oc||(this.isFullscreen&&a.preventDefault(),this.wi=a.keyCode,this.Fa())};c.prototype.lq=function(a){this.wi&&(this.wi=0,a.preventDefault())};c.prototype.Dq=
function(){this.wi=0};c.prototype.Ji=function(){this.isFullscreen&&(this.ti()||this.exitFullscreen(),this.ti()&&(this.aa.style.left="0px",this.aa.style.top="0px"))};c.prototype.Hq=function(a,b,e,f){f?(this.Mg.alpha=a,this.Mg.beta=b,this.Mg.gamma=e,this.Mg.gamma+=90):(this.kb.alpha=a,this.kb.beta=b,this.kb.gamma=e,this.kb.gamma+=90);this.kb.orientation=window.orientation?1*parseInt(""+window.orientation,10):0;e=new r.cl;a=this.kb;e.Ue(-a.alpha);e.Ve(-a.beta);e.Od(-a.gamma);e.Ve(90-a.orientation);1>
e.Kb?-1<e.Kb?(b=180/Math.PI*Math.asin(-e.Kb),a=180/Math.PI*Math.atan2(e.nc,e.mc),e=180/Math.PI*Math.atan2(e.lc,e.kc)):(b=0,a=90,e=-180/Math.PI*Math.atan2(-e.Ub,e.Vb)):(b=0,a=-90,e=180/Math.PI*Math.atan2(-e.Ub,e.Vb));if(this.cg)if(this.Cm()||this.G.ni||this.kb.rh)this.kb.Qe=this.Hg()+e,this.kb.fadeIn=0,this.kb.rh=!1;else{f=this.G.active;var g=1;10>this.kb.fadeIn&&(this.kb.fadeIn+=1,g=.1*this.kb.fadeIn);e=-e+this.kb.Qe;this.Xe(g*e+(1-g)*this.Hg());this.Ye(g*a+(1-g)*this.ii());this.Xn?this.Ui(g*b+(1-
g)*this.im()):this.Ui(0);this.pg();this.G.active=f}};c.prototype.On=function(a){this.la&&this.la.hotspotProxyClick&&this.la.hotspotProxyClick(a.id,a.url);""!=a.url&&(this.uk(a.url,a.target),this.ag(-1,-1))};c.prototype.Pn=function(a){this.la&&this.la.hotspotProxyDoubleClick&&this.la.hotspotProxyDoubleClick(a.id,a.url)};c.prototype.ei=function(){return Math.min(1,2*Math.tan(Math.PI*Math.min(this.fov.m,90)/360))};c.prototype.Zm=function(){var a=this;setTimeout(function(){a.Zm()},100);9!=a.Ni||a.pi||
window.requestAnimationFrame(function(){a.lh();a.Jc("restart recover timer")});10<a.Ni&&1<a.zk&&(a.Jc("recover timer - disabling requestAnimationFrame"),a.pi=!0,a.lh());a.Ni++};c.prototype.Xi=function(a){var b={vs:{value:0,name:"pan"},xs:{value:1,name:"tilt"},us:{value:2,name:"fov"}},e=0,f=0,g=0,h;for(h in b){for(var l=b[h],k,q=Math.floor(a);!this.xf(q,l.value)&&0<q;)q--;q=this.xf(q,l.value);var p=this.Cp(q);if(p){k=new r.Ec(q.time,q.value);var w=new r.Ec(p.time,p.value),x=(a-q.time)/(p.time-q.time);
if(0!=q.type||0!=p.type&&3!=p.type)if(3==q.type)k=q.value;else{x=new r.Ec;var y=new r.Ec,z=p.time-q.time;0==q.type?y.init(q.time+.3*z,q.value):y.init(q.xe,q.ye);0==p.type||3==p.type?x.init(p.time-.3*z,p.value):x.init(p.ve,p.we);p=new r.Ec;p.sj(k,w,y,x,a);k=p.y}else p=new r.Ec,p.Gd(k,w,x),k=p.y}else k=q.value;switch(l.value){case 0:l=this.pan.m;if(this.Td&&3!=q.type){if(2!=this.Xa){for(;360<k;)k-=360;for(;-360>k;)k+=360}e=k-l;2!=this.Xa&&(180<e&&(e-=360),-180>e&&(e+=360));this.pan.m+=e*this.zd}else this.pan.m=
k;this.C.Zg=this.pan.m;break;case 1:l=this.A.m;this.Td&&3!=q.type?(f=k-l,this.A.m+=f*this.zd):this.A.m=k;this.C.$g=this.A.m;break;case 2:l=this.fov.m,this.Td&&3!=q.type?(g=k-l,this.fov.m+=g*this.zd):this.fov.m=k,this.C.Yg=this.fov.m}}b=this.Sa();for(h=Math.floor(a);!this.xf(h,3)&&0<h;)h--;h=this.xf(h,3);q=a-h.time;this.Td&&-1!=this.kg&&this.Rh+this.pj>a?(b=this.Eg(this.kg),this.fov.m>b?this.Rh=a:(q=(a-this.Rh)/this.pj,q=Math.min(1,q),this.Nc(this.Wa,this.kg,1-q))):(0==h.Eb||q>h.Eb-.3?this.Nc(h.value):
(q/=h.Eb,this.Nc(b,h.value,1-q)),this.C.Jm=h.value);this.Td&&(e=Math.sqrt(e*e+f*f+g*g),.3>e&&(this.Td=!1,this.zd=.02,this.jg=0),0<this.jg&&e>this.jg&&(this.zd+=.01,this.zd=Math.min(this.zd,1)),this.jg=e);h=Math.floor(a);if(h!=this.kl)for(this.kl=h,a=this.hp(h),e=0;e<a.length;e++)f=a[e],g=f.Qh,this.vd.hasOwnProperty(g)&&(b=this.vd[g].type,0==b?this.ke(g,f.Yk):1==b?this.ke(g,f.value):2==b&&this.ke(g,"true"==f.Yk));this.update()};c.prototype.Wl=function(){if(""!=this.C.Kf){var a=this.dm(this.C.Kf);if(1==
a.length&&a[0]==this.Qa)return this.Qa}a=this.Qa;do if(this.C.Tm){var b=1E3;do a=this.Za[Math.floor(Math.random()*this.Za.length)];while(b--&&a==this.Qa)}else b=this.Za.indexOf(a),b++,b>=this.Za.length&&(b=0),a=this.Za[b];while(""!=this.C.Kf&&!this.Gg(a).tags.includes(this.C.Kf)&&a!=this.Qa);return a};c.prototype.Oq=function(a){var b=this.G.speed;this.G.jk&&(b=b*(a.getTime()-this.G.jk)/60,5<b&&(b=5),.2>b&&(b=.2));this.G.jk=a.getTime();this.C.Ag&&(this.za.ready()||4==this.Wa)&&this.gi()&&(this.C.Ag=
!1,this.C.active=!0,this.yb.running=!0,this.yb.Rj=!1);if(this.G.active||0!=this.G.Lb&&this.za.ready()){if(this.G.Wk&&"__AutoMove"==this.J.bb){var e=a.getTime()-this.G.jl;b=e/100;if(b>=this.J.length){if(this.Xi(this.J.length),this.xa.splice(this.xa.indexOf(this.J),1),this.G.active=!1,this.J=this.G.il,this.G.Lb=0,this.Ti(this.G.pan,this.G.A,this.G.fov),this.pan.Vc=this.G.pan,this.A.Vc=this.G.A,this.G.ih&&(this.G.ih=!1,this.C.Di=!0,this.C.active=!0,this.R("autorotatechanged",{})),this.onMoveComplete)this.onMoveComplete()}else this.Xi(b)}else{this.pan.d=
this.G.pan-this.pan.m;if(360==this.pan.max-this.pan.min){for(;-180>this.pan.d;)this.pan.d+=360;for(;180<this.pan.d;)this.pan.d-=360}this.A.d=this.G.A-this.A.m;this.V.d=this.G.V-this.V.m;this.fov.d=this.G.fov-this.fov.m;e=b*this.ei();var f=Math.sqrt(this.pan.d*this.pan.d+this.A.d*this.A.d+this.V.d*this.V.d+this.fov.d*this.fov.d),g=this.pan.m-this.G.Zg,h=this.A.m-this.G.$g,l=this.V.m-this.G.Km,k=this.fov.m-this.G.Yg;100*Math.sqrt(g*g+h*h+l*l+k*k)<e&&0==this.G.Lb&&(this.G.aborted=!0);this.G.Zg=this.pan.m;
this.G.$g=this.A.m;this.G.Km=this.V.m;this.G.Yg=this.fov.m;if(100*f<e||this.G.aborted){if(this.pan.d=0,this.A.d=0,this.V.d=0,this.fov.d=0,this.G.active&&(this.G.active=!1,this.pan.m=this.G.pan,this.A.m=this.G.A,this.V.m=this.G.V,this.fov.m=this.G.fov,this.onMoveComplete))this.onMoveComplete()}else f=f>5*e?e/f:.2,this.pan.d*=f,this.A.d*=f,this.fov.d*=f;this.pan.m+=this.pan.d;this.A.m+=this.A.d;this.V.m+=this.V.d;this.fov.m+=this.fov.d;0!=this.G.Lb&&(this.G.Lb!=this.Wa?(b=this.Eg(this.G.Lb),this.Vj()>
b?(this.fov.m+=-Math.max((2.5-1.7*Math.min(Math.sqrt(this.pan.d*this.pan.d+this.A.d*this.A.d+this.V.d*this.V.d)/e,1))*e,this.fov.d)-this.fov.d,this.G.fov=this.fov.m):(this.Bc=this.Wa,this.Wa=this.G.Lb,this.O("New projection from Target:"+this.Wa),this.kh=this.G.ph=0,this.za.oi())):1>this.G.ph?(this.G.ph=Math.min(1,this.G.ph+.05*b),this.kh=this.G.ph):(this.Bc=0,this.G.Lb=0,this.za.oi()))}this.Ff=a.getTime();this.update()}else if(this.C.active){e=a.getTime()-this.C.startTime;this.C.zi<this.C.startTime&&
(this.C.zi=this.C.startTime);if((this.C.dg||this.yb.running)&&0<this.xa.length){b=e/100;f=!1;if(this.Wb!=this.J.bb||""!=this.J.hf&&this.C.Ud!=this.J.hf){for(e=0;e<this.xa.length;e++)if(""==this.Wb&&this.xa[e].hf==this.C.Ud||""!=this.Wb&&this.xa[e].bb==this.Wb&&this.xa[e].hf==this.C.Ud){f=!0;this.J=this.xa[e];this.Wb=this.J.bb;break}!f&&0<this.xa.length&&this.xa[0].hf==this.C.Ud&&(f=!0,this.J=this.xa[0],this.Wb=this.J.bb)}else f=!0;if(f)if(e=(g=this.F.j&&this.F.td)&&this.C.Pk&&!this.yb.running,this.gf){f=
b;if(e)for(this.F.j.currentTime<this.ll&&this.rj&&(this.qj++,this.rj=!1),f=10*(this.qj*this.F.j.duration+this.F.j.currentTime),this.ll=this.F.j.currentTime,.05>this.F.j.duration-this.F.j.currentTime&&(this.rj=!0);f>=10*this.ff;)f-=10*this.ff;if(!g&&b>=this.J.length||g&&!e&&b>=this.J.length||g&&e&&(this.J.bb!=this.J.Pm||this.J.Gi!=this.Qa)&&b>=this.J.length){this.Xi(this.J.length);this.C.Kd=0;this.gf=!1;if(this.yb.running){this.sn();return}this.Wb=this.J.Pm;this.Wb==this.J.bb&&this.Qa==this.J.Gi?1<
this.Za.length&&0<this.C.Hi&&(e=this.Wl())&&(this.dd("{"+e+"}"),this.C.startTime=a.getTime(),this.gf=!1,this.C.active=!0,this.K.ue=!0):(this.Ef&&this.J.Gi!=this.Qa&&(this.dd("{"+this.J.Gi+"}",this.J.Aq),this.K.enabled?(this.C.active=!1,this.K.ue=!0):this.C.active=!0),this.C.startTime=a.getTime())}else this.Xi(f),this.C.Kd=f}else if(b=this.J.da[0],f=this.J.da[1],g=this.J.da[2],h=this.J.da[3],3!=h.tb&&(h=0),this.C.Di||this.G.aborted||this.yb.running||e){if(this.gf=!0,this.C.startTime=0<this.C.Kd?a.getTime()-
100*this.C.Kd:a.getTime(),this.Td=e){for(this.ff=this.qj=0;this.ff<this.J.length/10;)this.ff+=this.F.j.duration;f=10*this.F.j.currentTime;for(e=Math.floor(f);!this.xf(e,3)&&0<e;)e--;e=this.xf(e,3);e.value==this.Wa?this.kg=-1:(this.kg=e.value,this.Rh=f,this.pj=Math.max(5,e.time+e.Eb-f))}}else{e={};if(0<this.C.Kd)e.pan=this.C.Zg,e.tilt=this.C.$g,e.fov=this.C.Yg,e.projection=this.C.Jm;else{for(e.pan=b.value;360<e.pan;)e.pan-=360;for(;-360>e.pan;)e.pan+=360;e.tilt=f.value;e.fov=g.value;e.projection=h?
h.value:4}e.timingFunction=3;e.speed=1;this.G.ih=!0;this.Ei(e);this.C.active=!0}}else 0<this.C.Hi&&this.Ef&&e>=1E3*this.C.Hi?1<this.Za.length&&(e=this.Wl())&&(this.C.startTime=a.getTime(),this.C.ud=a.getTime(),this.C.timeout=0,this.dd("{"+e+"}"),this.C.active=!0,this.K.ue=!0):(e=a.getTime(),f=b=1E3/60,0!=this.C.ud&&(f=e-this.C.ud),this.A.d=this.C.fj*(0-this.A.m)/100,this.fov.d=this.C.fj*(this.fov.eb-this.fov.m)/100,this.pan.d=.95*this.pan.d+-this.C.speed*this.ei()*.05,b=f/b,this.pan.m+=this.pan.d*
b,this.A.m+=this.A.d*b,this.fov.m+=this.fov.d*b,this.C.ud=e,this.update());3E3<a.getTime()-this.C.zi&&!this.C.Yh&&(this.Ra.style.cursor="none",this.C.Yh=!0)}else!this.yb.Rj&&1E3<a.getTime()-this.Ff&&(this.xa.splice(this.xa.indexOf(this.J),1),this.J=this.Dg(!1),this.Wb=this.J.bb,this.C.active=!1,this.C.Ag=!0),this.C.enabled&&!this.Z.ri()&&a.getTime()-this.Ff>1E3*this.C.timeout&&!this.C.Ag&&(this.C.xh&&this.gi()||!this.C.xh)&&(this.C.active=!0,this.C.startTime=a.getTime(),this.C.ud=0,this.R("autorotatechanged",
{}),this.pan.d=0,this.A.d=0,this.fov.d=0),!this.Ka.enabled||this.Z.ri()||0==this.pan.d&&0==this.A.d&&0==this.fov.d||(this.G.ni=!0,this.pan.d*=.9,this.A.d*=.9,this.fov.d*=.9,this.pan.m+=this.pan.d,this.A.m+=this.A.d,this.yj(this.fov.d),1E-4>this.pan.d*this.pan.d+this.A.d*this.A.d+this.fov.d*this.fov.d&&(this.pan.d=0,this.A.d=0,this.fov.d=0),this.update())};c.prototype.Qq=function(a){var b=this.K;if(b.xd){var e=a.getTime()-b.ho;e/=1E3*b.fo;1<=e?(b.xd=!1,this.Jl(),b.Nk=a.getTime(),this.Hn(),b.qe=!0,
0==b.sc||b.hg||(4==b.sc?(this.J=this.Dg(!0,b.$e,b.af,b.Rd),this.Wb=this.J.bb,this.C.active=!0,this.yb.running=!0):this.moveTo(b.$e,b.af,b.Rd,b.te,0,b.wd))):b.Ym(e)}else b.qe&&(e=a.getTime()-b.Nk,e/=1E3*b.lg,1<=e?(b.qe=!1,this.Ff=a.getTime(),this.update(),0!=b.sc&&b.hg&&(4==b.sc?(this.J=this.Dg(!0,b.$e,b.af,b.Rd),this.Wb=this.J.bb,this.C.active=!0,this.yb.running=!0):this.moveTo(b.$e,b.af,b.Rd,b.te,0,b.wd)),4!=b.sc&&(this.Ri(!1),this.C.active=b.ue,this.R("autorotatechanged",{}),b.ue=!1),this.C.ud=
0,this.qa&&this.Fj(),this.ng=!1):b.Ym(e));b=this.Jq;b.Fo&&(b.Zh?a.getTime()-b.Mj>=1E3*b.delay&&(b.Zh=!1):(b.current+=b.jd,0>b.current&&(b.current=0,b.jd=-b.jd,b.Zh=!0,b.Mj=a.getTime()),1<b.current&&(b.current=1,b.jd=-b.jd,b.Zh=!0,b.Mj=a.getTime())))};c.prototype.Tq=function(){var a,b=this.I;if(0<b.ub.length){for(a=0;a<b.ub.length;a++)b.fd[a]!=b.Zb[a]&&(b.fd[a]>b.Zb[a]?(b.Zb[a]+=.05,b.fd[a]<b.Zb[a]&&(b.Zb[a]=b.fd[a])):(b.Zb[a]-=.05,b.fd[a]>b.Zb[a]&&(b.Zb[a]=b.fd[a],-1!=b.Yi.indexOf(b.ub[a])&&(b.Yi.splice(b.Yi.indexOf(b.ub[a]),
1),b.ub.splice(a,1),b.fd.splice(a,1),b.Zb.splice(a,1)))));this.update()}if(2==b.mode)for(a=0;a<this.X.length;a++){var e=this.X[a];"poly"==e.type&&e.nb!=e.Ba&&(e.nb>e.Ba?(e.Ba+=b.jd,e.nb<e.Ba&&(e.Ba=e.nb)):(e.Ba-=b.jd,e.nb>e.Ba&&(e.Ba=e.nb)),this.update())}3==b.mode&&b.nb!=b.Ba&&(b.nb>b.Ba?(b.Ba+=b.jd,b.nb<b.Ba&&(b.Ba=b.nb)):(b.Ba-=b.jd,b.nb>b.Ba&&(b.Ba=b.nb)),this.update())};c.prototype.Sq=function(){var a=this.Ka;this.Z.ri()&&(this.M.Hd?(a.na.x=.4*(this.ga.oa.x-a.oa.x),a.na.y=.4*(this.ga.oa.y-a.oa.y),
a.oa.x+=a.na.x,a.oa.y+=a.na.y):(a.na.x=.1*-this.ga.na.x*this.M.sensitivity/8,a.na.y=.1*-this.ga.na.y*this.M.sensitivity/8),this.Yn(a.na.x,a.na.y),this.update());a.fov.active&&(this.pl(.4*(a.fov.wc-this.fov.m)),.001>Math.abs(a.fov.wc-this.fov.m)/this.fov.m&&(a.fov.active=!1),this.update());if(a.enabled&&(0!=a.na.x||0!=a.na.y)&&!this.Z.ri()){var b=.9*(1-a.Ek);a.na.x*=b;a.na.y*=b;this.G.ni=!0;.01>a.na.x*a.na.x+a.na.y*a.na.y?(a.na.x=0,a.na.y=0):(this.Yn(a.na.x,a.na.y),this.update())}};c.prototype.Pq=
function(){if(this.M.pn&&this.M.Hd){var a=this.bn;a.pan=this.pan.m;a.A=this.A.m;a.fov=this.fov.m;this.nf(a);this.nf(a);this.nf(a);var b=a.pan-this.pan.m,e=a.A-this.A.m;a=a.fov-this.fov.m;if(0!=b||0!=e||0!=a){var f=.2+.9*Math.min((Math.abs(b)+Math.abs(e)+Math.abs(a))/Math.abs(Math.min(this.fov.m,90))*.3,1);this.pan.m+=b*f;this.A.m+=e*f;this.fov.m+=a*f;this.Ka.Ek=.3;this.update()}else this.Ka.Ek=0}else this.pg();if(isNaN(this.pan.m)||1E7<this.pan.m||-1E7>this.pan.m)this.pan.m=0;if(isNaN(this.A.m)||
1E7<this.A.m||-1E7>this.A.m)this.A.m=0;if(isNaN(this.V.m)||1E7<this.V.m||-1E7>this.V.m)this.V.m=0;if(2!=this.Xa){for(;360<this.pan.m;)this.pan.m-=360;for(;-360>this.pan.m;)this.pan.m+=360}};c.prototype.Rq=function(){if(!this.gi()&&this.Af&&5<this.v.kn){var a,b=0,e=this.gc.length;if(this.Fh)e=50,this.Nj<e&&this.Nj++,b=this.Nj;else for(a=0;a<e;a++)(this.gc[a].complete&&this.gc[a].src!=this.Fl||""==this.gc[a].src)&&b++;b==e?(this.mh=1,this.isLoaded=!0,this.ta&&this.ta.ggLoaded&&this.ta.ggLoaded(),this.R("imagesready",
{}),this.C.xh&&this.C.enabled&&!this.G.active&&!this.K.xd&&(this.C.active=!0,this.C.startTime=(new Date).getTime(),this.C.ud=0)):this.mh=b/(1*e);this.R("downloadprogress",{percentLoaded:this.mh})}};c.prototype.lh=function(){var a=this;a.Pi||(a.pi?setTimeout(function(){a.Pi=!1;a.lh()},1E3/60):window.requestAnimationFrame(function(){a.Pi=!1;a.lh()}));a.Pi=!0;this.zk=this.Ni=0;a.G.ni=!1;var b=new Date;this.fi++;120<=this.fi&&(this.O("F/s: "+Math.round(1E3*this.fi/(b.getTime()-this.Fm))),this.Fm=b.getTime(),
this.fi=0);this.R("timer",{});this.ia&&this.za.$o();this.Nb&&""!==this.Fe&&!this.ra&&document.hasOwnProperty(this.Fe)&&document[this.Fe].setPan&&0==this.ep--&&(this.ra=document[this.Fe],this.hd=this.ia=!1,this.Ja&&(this.Ja.style.visibility="hidden"),this.ra.setLocked(!0),this.ra.setSlaveMode(!0),this.ra.readConfigString(this.Ij),this.Jc("Flash player '"+this.Fe+"' connected."));this.Vk&&(this.Pc(),this.Vk=!1);this.Sq();this.Rq();this.Oq(b);this.Pq();this.Qq(b);this.za.hs();(0<=this.I.mode||0<this.I.ub.length)&&
this.Tq();this.kj();if(this.Gf.pan!=this.pan.m||this.Gf.A!=this.A.m||this.Gf.fov!=this.fov.m)this.Gf.pan=this.pan.m,this.Gf.A=this.A.m,this.Gf.fov=this.fov.m,this.R("positionchanged",{});this.Hm!=this.Wa&&(this.Hm=this.Wa,this.R("projectionchanged",{}));this.Na&&(0<this.ug?this.ug--:(this.Na=!1,this.ug=0),this.K.qe||this.K.xd||this.ef||(this.Eh(),this.R("renderframe",{})),this.R("repaint",{}));b=this.$l();b!=this.Gm&&(b?(this.ta&&this.ta.ggReLoadedLevels&&this.ta.ggReLoadedLevels(),this.R("tilesrequested",
{})):(a.ta&&a.ta.ggLoadedLevels&&a.ta.ggLoadedLevels(),this.R("tilesready",{})),this.Gm=b)};c.prototype.Eg=function(a){switch(a){case 4:a=Math.min(110,this.fov.max);break;case 12:a=Math.min(270,this.fov.qk);a=Math.min(360*this.aspect(),a);a=Math.min(360/this.aspect(),a);break;case 9:a=Math.min(270,this.fov.rk);break;default:a=90}return a};c.prototype.es=function(){var a=this;setTimeout(function(){a.Vf(!1)},10);setTimeout(function(){a.Vf(!1)},100)};c.prototype.kj=function(){this.Hj.Nl(this.pan.m,this.A.m);
for(var a=0;a<this.Y.length+this.T.length;a++){if(a<this.Y.length)var b=this.Y[a];else if(b=this.T[a-this.Y.length],b.cd)continue;b.kj()}};c.prototype.Fr=function(a,b){var e=this;var f="<<L>>"+String(e.Pa);f=f.toUpperCase();"U"!=f.charAt(2)&&(e.M.Bf=!1);if(0!=e.fh.length||!e.M.Bf||e.M.rg||e.M.Wh)if(e.od)e.aa.removeChild(e.od),e.od=null;else{e.od=document.createElement("div");var g=e.od;f="left: "+a+"px;"+("top:\t "+b+"px;")+"z-index: 32000;";f+="position:relative;";f+="display: table;";f+="color: black;";
f+="background-color: white;";f+="border: 1px solid lightgray;";f+="box-shadow: 1px 1px 3px #333;";f+="font-family: Verdana, Arial, Helvetica, sans-serif;";f+="font-size: 9pt;";f+="opacity : 0.95;";g.setAttribute("style",f);g.setAttribute("class","gg_contextmenu");f=document.createElement("style");a=document.createTextNode(".gg_context_row:hover { background-color: #3399FF }");f.type="text/css";f.styleSheet?f.styleSheet.cssText=a.nodeValue:f.appendChild(a);g.appendChild(f);for(a=0;a<e.fh.length;a++){b=
e.fh[a];var h=document.createElement("div");f="text-align: left;";f+="margin: 0;";f+="padding: 5px 20px;";f+="vertical-align: left;";h.setAttribute("style",f);h.setAttribute("class","gg_context_row");f=document.createElement("a");f.href=b.url;f.target="_blank";f.innerHTML=b.text;f.setAttribute("style","color: black; text-decoration: none;");h.appendChild(f);g.appendChild(h)}0<e.fh.length&&(!e.M.Bf||e.M.rg||e.M.Wh)&&g.appendChild(document.createElement("hr"));if(e.M.Wh&&e.ia){b=[];b.push({text:"Rectilinear Projection",
oh:4});b.push({text:"Stereographic Projection",oh:9});b.push({text:"Fisheye Projection",oh:12});for(a=0;a<b.length;a++){h=b[a];var l=document.createElement("div");l.setAttribute("class","gg_context_row");f="text-align: left;";f+="margin: 0;";f=e.Wa==h.oh?f+"padding: 5px 20px 5px 7px;":f+"padding: 5px 20px;";f+="vertical-align: left;";f+="cursor: pointer;";l.setAttribute("style",f);l.onclick=function(k){return function(){e.zj(k,1);e.update()}}(h.oh);l.innerHTML=e.Wa==h.oh?"&#10687; "+h.text:h.text;
g.appendChild(l)}e.M.Bf&&!e.M.rg||g.appendChild(document.createElement("hr"))}e.M.rg&&(a=document.createElement("div"),a.setAttribute("class","gg_context_row"),f="text-align: left;margin: 0;padding: 5px 20px;",f+="vertical-align: left;",f+="cursor: pointer;",a.setAttribute("style",f),a.onclick=function(){e.gj()},a.innerHTML=e.ti()?"Exit Fullscreen":"Enter Fullscreen",g.appendChild(a));e.M.Bf||(a=document.createElement("div"),f="text-align: left;margin: 0;padding: 5px 20px;",f+="vertical-align: left;",
a.setAttribute("style",f),a.setAttribute("class","gg_context_row"),f=document.createElement("a"),f.href=c.tg("aHR0cDovL3Bhbm8ydnIuY29tLw=="),f.target="_blank",f.innerHTML=c.tg("Q3JlYXRlZCB3aXRoIFBhbm8yVlI="),7<this.Bi.length&&(f.innerHTML+="<br/>"+c.Cl(this.Bi).replace(/./gm,function(k){return"&#"+k.charCodeAt(0)+";"})),f.setAttribute("style","color: black; text-decoration: none;"),a.appendChild(f),g.appendChild(a));e.aa.insertBefore(e.od,e.aa.firstChild);g.onclick=function(){e.od&&(e.aa.removeChild(e.od),
e.od=null)};g.oncontextmenu=g.onclick}};c.prototype.Eo=function(){var a=this;var b=a.Ra;a.control=b;a.control=b;a.es();setTimeout(function(){a.lh()},10);setTimeout(function(){a.Zm()},200);setTimeout(function(){a.df();a.Eh()},10);b.addEventListener&&(b.addEventListener("touchstart",function(e){a.Zr(e)},!1),b.addEventListener("touchmove",function(e){a.Yr(e)},!1),b.addEventListener("touchend",function(e){a.Xr(e)},!1),b.addEventListener("touchcancel",function(e){a.Wr(e)},!1),b.addEventListener("pointerdown",
function(e){a.Om(e)},!1),b.addEventListener("MSPointerDown",function(e){a.Om(e)},!1),b.addEventListener("MSGestureStart",function(e){a.Vl(e)},!1),b.addEventListener("MSGestureEnd",function(e){a.Ul(e)},!1),b.addEventListener("MSGestureChange",function(e){a.xq(e)},!1),b.addEventListener("gesturestart",function(e){a.Vl(e)},!1),b.addEventListener("gesturechange",function(e){a.gp(e)},!1),b.addEventListener("gestureend",function(e){a.Ul(e)},!1),b.addEventListener("mousedown",function(e){a.uq(e)},!1),b.addEventListener("mousemove",
function(e){a.tq(e)},!1),document.addEventListener("mouseup",function(e){a.sq(e)},!1),b.addEventListener("mousewheel",function(e){a.Nm(e)},!1),b.addEventListener("DOMMouseScroll",function(e){a.Nm(e)},!1),document.addEventListener("keydown",function(e){a.kq(e)},!1),document.addEventListener("keyup",function(e){a.lq(e)},!1),window.addEventListener("resize",function(){a.df()},!1),window.addEventListener("blur",function(){a.Dq()},!1),a.aa.addEventListener("webkitfullscreenchange",function(){a.Ji()},!1),
document.addEventListener("mozfullscreenchange",function(){a.Ji()},!1),window.addEventListener("webkitfullscreenchange",function(){a.Ji()},!1),document.addEventListener("MSFullscreenChange",function(){a.Ji()},!1));b.oncontextmenu=function(e){void 0===e&&(e=window.event);if(e.target&&!a.Ic(e.target))return!0;if(!e.ctrlKey){e=a.Fg(e);var f=a.He();a.Fr(e.x-f.x,e.y-f.y);return!1}return!0};window.addEventListener("deviceorientation",function(e){a.Hq(e.alpha,e.beta,e.gamma,e.absolute);null!=e.alpha&&null!=
e.beta&&null!=e.gamma&&0==a.Zj&&(a.Zj=!0,a.R("gyroavailable",{available:!0}),a.R("playerstatechanged",{}))})};c.prototype.hl=function(){for(var a=0;a<this.X.length;a++)if("point"==this.X[a].type&&(this.la&&this.la.addSkinHotspot?(this.X[a].tf(),this.X[a].j=this.la.addSkinHotspot(this.X[a])):(this.X[a].j=new r.jo(this,this.X[a]),this.X[a].Wc&&this.X[a].bg&&(this.X[a].j.ggUse3d=!0,this.X[a].j.gg3dDistance=this.X[a].$h)),this.X[a].j.__div.style.left="-1000px",this.X[a].j.__div.style.top="-1000px",this.X[a].j&&
this.X[a].j.__div)){var b=this.Ra.firstChild;b?this.Ra.insertBefore(this.X[a].j.__div,b):this.Ra.appendChild(this.X[a].j.__div)}};c.prototype.eo=function(){var a,b=document.createElement("fakeelement"),e={OTransition:"oTransitionEnd",MSTransition:"msTransitionEnd",MozTransition:"transitionend",WebkitTransition:"webkitTransitionEnd",transition:"transitionEnd"};for(a in e)if(void 0!==b.style[a])return e[a]};c.prototype.xb=function(a){var b=[];a="#"==a.substr(0,1)?a.substr(1):"^"+a+"$";a=new RegExp(a,
"");for(var e=0;e<this.Y.length;e++)a.test(this.Y[e].id)&&b.push(this.Y[e]);for(e=0;e<this.T.length;e++)a.test(this.T[e].id)&&b.push(this.T[e]);for(e=0;e<this.fb.length;e++)a.test(this.fb[e].id)&&b.push(this.fb[e]);return b};c.prototype.Bp=function(a){if("_videopanorama"==a)return this.F.j;a=this.xb(a);return 0<a.length?a[0].j:null};c.prototype.en=function(a,b){var e=this;b.addEventListener("ended",function(g){e.R("videoended",{video:g.target})});b.addEventListener("pause",function(g){e.R("videopaused",
{video:g.target})});b.addEventListener("play",function(g){e.R("videostarted",{video:g.target})});for(var f=0;f<this.T.length;f++)if(this.T[f].id==a)return this.T[f].j=b,this.T[f];f=new r.fl(this);f.registerElement(a,b);return f};c.prototype.isPlaying=function(a){if(this.Nb){var b=this.ra;if(b)return b.isPlaying(a)}else{if("_main"===a)return!0;a=this.xb(a);if(0<a.length)return a[0].va?a[0].Nf:!a[0].j.ended&&!a[0].j.paused}return!1};c.prototype.fe=function(a,b){if(this.Nb){var e=this.ra;e&&e.playSound(a,
b)}else try{e=this.xb(a);for(var f=0;f<e.length;f++){var g=e[f];g.wb=b&&!isNaN(Number(b))?Number(b)-1:g.loop-1;-1==g.wb&&(g.wb=1E7);this.O(g.j);this.isPlaying(a)&&this.$i(a);g.va?g.Wd():(g.j.play(),!g.se||this.yc&&this.li||g.Ph());this.xr(g.id)}}catch(h){this.O(h)}};c.prototype.$m=function(a,b){a=this.xb(a);for(var e=0;e<a.length;e++){var f=a[e];this.isPlaying(f.id)?this.vk(f.id):this.fe(f.id,b)}};c.prototype.Uq=function(a,b){a=this.xb(a);for(var e=0;e<a.length;e++){var f=a[e];this.isPlaying(f.id)?
this.$i(f.id):this.fe(f.id,b)}};c.prototype.vk=function(a){if(this.Nb){var b=this.ra;b&&b.pauseSound(a)}else try{if(b=void 0,"_main"==a){this.Vi(a);for(b=0;b<this.Y.length;b++)this.Y[b].va?this.Y[b].uj():this.Y[b].j.pause();for(b=0;b<this.T.length;b++)this.T[b].j.pause()}else{var e=this.xb(a);for(b=0;b<e.length;b++){var f=e[b];this.Vi(f.id);f.va?f.uj():f.j.pause()}}}catch(g){this.O(g)}};c.prototype.uo=function(a,b){a=this.xb(a);for(var e=0;e<a.length;e++){var f=a[e];0==b||1==b?f.Kg&&f.Kg(1==b):2==
b&&f.Ie&&f.Ie();!f.pb||-1==this.fb.indexOf(f)&&-1==this.T.indexOf(f)||(this.Ob=this.he=f)}};c.prototype.$i=function(a){var b;if(this.Nb)(b=this.ra)&&b.stopSound(a);else try{if("_main"===a){this.Vi(a);for(b=0;b<this.Y.length;b++)this.Y[b].va?this.Y[b].mf():(this.Y[b].j.pause(),this.Y[b].j.currentTime=0);for(b=0;b<this.T.length;b++)this.T[b].j.pause(),this.T[b].j.currentTime=0}else{var e=this.xb(a);for(b=0;b<e.length;b++){var f=e[b];this.Vi(f.id);f.va?f.mf():f.j&&f.j.pause&&(f.j.pause(),f.j.currentTime=
0)}}}catch(g){this.O(g)}};c.prototype.Vi=function(a){-1==this.gd.indexOf(a)&&this.gd.push(a);var b=this.re.indexOf(a);-1!=b&&this.re.splice(b,1);"_main"==a&&(this.re=[])};c.prototype.xr=function(a){-1!=this.gd.indexOf("_main")&&-1==this.re.indexOf(a)&&this.re.push(a);a=this.gd.indexOf(a);-1!=a&&this.gd.splice(a,1)};c.prototype.Gr=function(a){a=this.xb(a);return 0<a.length?(a=a[0],a.va?a.Ho():a.j?a.j.currentTime:0):0};c.prototype.Hr=function(a,b){a=this.xb(a);0<a.length&&(a=a[0],a.va?(0>b&&(b=0),b>
a.Th.duration&&(b=a.Th.duration-.1),a.Io(b)):a.j&&(0>b&&(b=0),b>a.j.duration&&(b=a.j.duration-.1),a.j.currentTime=b))};c.prototype.setVolume=function(a,b){if(this.Nb){var e=this.ra;e&&e.setVolume(a,b)}else try{e=void 0;var f=Number(b);1<f&&(f=1);0>f&&(f=0);"_videopanorama"===a&&this.F.j&&(this.F.j.volume=f);if("_main"===a){this.ca=f;for(e=0;e<this.Y.length;e++)this.Y[e].j.volume=this.Y[e].level*this.ca;for(e=0;e<this.T.length;e++)this.T[e].j.volume=this.T[e].level*this.ca;this.F.j&&(this.F.j.volume=
this.ca)}else{var g=this.xb(a);this.O(g);for(e=0;e<g.length;e++){var h=g[e];h.j&&null!=h.j.volume&&(h.j.volume=f*this.ca);h.level=f}}}catch(l){this.O(l)}};c.prototype.Po=function(a,b){if(this.Nb){var e=this.ra;e&&e.changeVolume(a,b)}else try{var f=e=void 0;"_videopanorama"===a&&this.F.j&&(this.F.j.volume+=Number(b));if("_main"===a){e=this.ca;e+=Number(b);1<e&&(e=1);0>e&&(e=0);this.ca=e;for(f=0;f<this.Y.length;f++)this.Y[f].j.volume=this.Y[f].level*this.ca;for(f=0;f<this.T.length;f++)this.T[f].j.volume=
this.T[f].level*this.ca;this.F.j&&(this.F.j.volume=this.ca)}else{var g=this.xb(a);for(f=0;f<g.length;f++){var h=g[f];e=h.level;e+=Number(b);1<e&&(e=1);0>e&&(e=0);h.level=e;h.j&&null!=h.j.volume&&(h.j.volume=e*this.ca)}}}catch(l){this.O(l)}};c.prototype.Si=function(a,b,e){a.j.style.opacity=0==b?1:0;a.j.style[this.Xc]="opacity "+e+"ms";a.j.style.opacity=0==b?0:1};c.prototype.kr=function(a,b,e){function f(){var k=g[l];if(!k.j)return"continue";0==b?(h.Si(k,b,e),setTimeout(function(){0==k.j.style.opacity&&
k.Wf(!1)},e+10),k.qb=!1):1==b?(h.Si(k,b,e),k.Wf(!0),k.qb=!0):2==b&&("visible"==k.j.style.visibility?(h.Si(k,0,e),setTimeout(function(){0==k.j.style.opacity&&k.Wf(!1)},e+10),k.qb=!1):(h.Si(k,1,e),k.Wf(!0),k.qb=!0))}for(var g=this.xb(a),h=this,l=0;l<g.length;l++)f()};c.prototype.Hn=function(){try{for(var a=this,b=!1,e=!1,f=0;f<this.Y.length;f++){var g=this.Y[f];if(-1!=g.loop&&!this.isPlaying(g.id)&&-1==this.gd.indexOf(g.id)&&(-1==this.gd.indexOf("_main")||-1!=this.re.indexOf(g.id)))if(this.wa&&this.Ya.enabled&&
4!=g.mode&&6!=g.mode)if(this.Ya.yl){if(g.va)g.Wd();else{var h=g.j.play();if(void 0!==h)h.then(function(){})["catch"](function(){});g.j.currentTime=0}g.ua=0;e=!0}else b=!0;else if(4!=g.mode&&6!=g.mode&&("_background"!=g.id||!this.isPlaying(g.id)))if(g.va)g.Wd();else{h=g.j.play();if(void 0!==h)h.then(function(){})["catch"](function(){});g.j.currentTime&&(g.j.currentTime=0)}}b&&setTimeout(function(){a.Ya.Nr()},1E3*this.Ya.Eb);e&&(this.Ya.Jr=this.wa.currentTime,this.Ya.Ir=setInterval(function(){a.Ya.cp()},
10))}catch(l){this.O(l)}};c.prototype.Jl=function(){for(var a=0;a<this.Ya.Ch.length;a++)this.Ya.Il(this.Ya.Ch[a])};c.prototype.jn=function(){for(var a;0<this.X.length;)a=this.X.pop(),a.j&&(this.Ra.removeChild(a.j.__div),delete a.j),a.j=null;this.R("hotspotsremoved",{})};c.prototype.Hk=function(a){this.Lh=a;this.aa.style.zIndex=0!=a?a.toString():"auto";this.Ta&&this.Ta.kd&&(this.Ta.kd.zIndex=(a+4).toString());this.Ra.style.zIndex=(a+4).toString();this.Ja.style.zIndex=(a+3).toString();this.Ia.style.zIndex=
(a+5).toString();for(var b=0;b<this.T.length+this.fb.length;b++){var e=b<this.T.length?this.T[b]:this.fb[b-this.T.length];e.j&&(e.j.style.zIndex=(a+(e.pb?8E4:0)).toString())}};c.prototype.Vf=function(a){var b=this.isFullscreen!==a;this.isFullscreen!==a&&(this.isFullscreen=a,this.update(100));if(this.isFullscreen){if(this.lj)try{this.aa.webkitRequestFullScreen?this.aa.webkitRequestFullScreen():this.aa.mozRequestFullScreen?this.aa.mozRequestFullScreen():this.aa.msRequestFullscreen?this.aa.msRequestFullscreen():
this.aa.requestFullScreen?this.aa.requestFullScreen():this.aa.requestFullscreen&&this.aa.requestFullscreen()}catch(e){this.O(e)}this.aa.style.position="absolute";a=this.He();this.aa.style.left=window.pageXOffset-a.x+this.margin.left+"px";this.aa.style.top=window.pageYOffset-a.y+this.margin.top+"px";this.Hk(10);document.body.style.overflow="hidden";b&&(this.ta&&this.ta.ggEnterFullscreen&&this.ta.ggEnterFullscreen(),this.R("fullscreenenter",{}),this.R("playerstatechanged",{}))}else{if(this.lj)try{document.webkitIsFullScreen?
document.webkitCancelFullScreen():document.mozFullScreen?document.mozCancelFullScreen():document.msExitFullscreen?document.msExitFullscreen():document.fullScreen&&(document.cancelFullScreen?document.cancelFullScreen():document.exitFullscreen&&document.exitFullscreen())}catch(e){this.O(e)}this.aa.style.position="relative";this.aa.style.left="0px";this.aa.style.top="0px";this.Hk(0);document.body.style.overflow="";b&&(this.ta&&this.ta.ggExitFullscreen&&this.ta.ggExitFullscreen(),this.R("fullscreenexit",
{}),this.R("playerstatechanged",{}))}this.df()};c.prototype.gj=function(){this.Vf(!this.isFullscreen)};c.prototype.bp=function(){this.Vf(!0)};c.prototype.exitFullscreen=function(){this.Vf(!1)};c.prototype.qp=function(){return this.isFullscreen};c.prototype.wg=function(){this.mb.Wo();this.ln();this.mb.wg();this.mb.Wm();return!0};c.prototype.Tp=function(){return this.mb.display?this.mb.display.displayName:"N/A"};c.prototype.Ar=function(a){this.mb&&(this.mb.Ed=a)};c.prototype.sf=function(){this.mb&&
(this.mb.sf(),this.mb.je(),this.mb.tl());return!0};c.prototype.Nn=function(){this.mb&&(this.mb.Rg()?this.sf():this.wg());return!0};c.prototype.Rg=function(){return this.mb&&this.mb.Rg()?!0:!1};c.prototype.dk=function(){return this.mb&&this.mb.dk()?!0:!1};c.prototype.Lr=function(a,b,e){this.C.Ud=this.C.Sh;this.C.dg=this.C.Ih;this.C.enabled=!0;this.C.jf=this.C.enabled;this.C.active=!0;this.C.ud=0;var f=new Date;this.C.Kd=0;this.C.startTime=f.getTime();a&&0!=a&&(this.C.speed=a);b&&(this.C.timeout=b);
e&&(this.C.fj=e);this.R("autorotatechanged",{})};c.prototype.Or=function(){this.C.active=!1;this.C.enabled=!1;this.C.jf=this.C.enabled;this.gf=this.C.Di=!1;this.G.active&&this.G.ih&&(this.G.active=!1,this.G.ih=!1,this.G.Lb=0);this.R("autorotatechanged",{})};c.prototype.Ur=function(){this.C.enabled=!this.C.active;this.C.jf=this.C.enabled;this.C.active=this.C.enabled;this.C.ud=0;if(this.C.enabled){var a=new Date;this.C.Kd=0;this.C.startTime=a.getTime();this.C.Ud=this.C.Sh;this.C.dg=this.C.Ih}this.R("autorotatechanged",
{})};c.prototype.er=function(a){this.C.Kf=a;this.C.Sm=!0};c.prototype.Kr=function(a){this.yb.running&&this.sn();this.Wb="";a&&""!=a&&(this.C.Ud=a);this.C.jf=this.C.enabled;this.C.dg=!0;this.C.enabled=!0;this.C.active=!0;this.C.ud=0;a=new Date;this.C.Kd=0;this.C.startTime=a.getTime();this.R("autorotatechanged",{})};c.prototype.sn=function(){this.yb.running=!1;this.yb.Rj=!0;this.C.active=this.K.ue;this.xa.splice(this.xa.indexOf(this.J),1);0<this.xa.length&&(this.J=this.xa[0]);this.Wb="";this.Ri(!1);
this.K.ue=!1;this.Ff=(new Date).getTime()};c.prototype.xl=function(a){if(this.ld=document.getElementById(a)){this.ld.innerHTML="";this.aa=document.createElement("div");this.aa.onselectstart=function(){return!1};Gh&&this.aa.setAttribute("id","viewport");a="top:\t0px;left: 0px;position:relative;-ms-touch-action: none;touch-action: none;text-align: left;"+(this.Pa+"user-select: none;");this.aa.setAttribute("style",a);this.ld.appendChild(this.aa);this.L=document.createElement("div");a="top:\t0px;left: 0px;width:  100px;height: 100px;overflow: hidden;position:absolute;-ms-touch-action: none;touch-action: none;"+
(this.Pa+"user-select: none;");Gh&&this.L.setAttribute("id","viewer");this.L.setAttribute("style",a);this.aa.appendChild(this.L);if(this.Nb){var b=document.createElement("div");a="top:\t0px;left: 0px;width:  100%;height: 100%;overflow: hidden;position:absolute;-ms-touch-action: none;touch-action: none;"+(this.Pa+"user-select: none;");b.setAttribute("id",this.Tj);b.setAttribute("style",a);this.L.appendChild(b)}this.Ta&&(this.Ta.kd=document.createElement("canvas"),Gh&&this.Ta.kd.setAttribute("id","lensflarecanvas"),
a="top:\t0px;left: 0px;width:  100px;height: 100px;overflow: hidden;position:absolute;"+(this.Pa+"user-select: none;"),a+=this.Pa+"pointer-events: none;",this.Ta.kd.setAttribute("style",a),this.aa.appendChild(this.Ta.kd));this.Ra=document.createElement("div");Gh&&this.Ra.setAttribute("id","hotspots");a="top:\t0px;left: 0px;width:  100px;height: 100px;overflow: hidden;position:absolute;";this.hk&&(a+="background-image: url(data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7);");
this.yc&&!this.ia&&(a+=this.Pa+"transform: translateZ(9999999px);");a+=this.Pa+"user-select: none;";this.Ra.setAttribute("style",a);this.aa.appendChild(this.Ra);this.Ja=document.createElement("canvas");Gh&&this.Ja.setAttribute("id","hotspotcanvas");a="top:\t0px;left: 0px;width:  100px;height: 100px;overflow: hidden;position:absolute;"+(this.Pa+"user-select: none;");a+=this.Pa+"pointer-events: none;";this.Ja.setAttribute("style",a);this.aa.appendChild(this.Ja);this.Ia=document.createElement("div");
Gh&&this.Ia.setAttribute("id","hotspottext");this.Ia.setAttribute("style","top:\t0px;left: 0px;position:absolute;padding: 3px;visibility: hidden;");this.Ia.classList.add("ggskin");this.Ia.classList.add("ggdefaulthotspot");this.Ia.innerHTML=" Hotspot text!";this.aa.appendChild(this.Ia);this.divSkin=this.ta=this.Ra;this.Hk(0)}else alert("container not found!")};c.prototype.Al=function(a){this.Na=!0;return function(){a.cb&&(a.v&&a.v.complete?(a.loaded=!0,a.cb.drawImage(a.v,0,0,a.width,a.height),a.v=
null,a.Nd=null):a.Nd&&a.Nd.complete&&!a.loaded&&(a.cb.drawImage(a.Nd,0,0,a.width,a.height),a.Nd=null))}};c.prototype.wl=function(a){var b,e=128;this.v.Pf&&(this.L.style.backgroundColor=this.v.Pf.replace("0x","#"));a?(e=this.mg,this.bf=1):this.Dc>e&&(e=this.Dc);for(b=0;6>b;b++){var f=this.cube.faces[b];a?(f.width=this.mg,f.height=this.mg):(f.W=document.createElement("canvas"),f.W.width=this.Dc,f.W.height=this.Dc,f.width=this.Dc,f.height=this.Dc,f.cb=f.W.getContext("2d"));var g="position:absolute;";
g+="left: 0px;";g+="top: 0px;";g+="width: "+e+"px;";g+="height: "+e+"px;";a&&(g+="outline: 1px solid transparent;");g+=this.Pa+"transform-origin: 0% 0%;";g+="-webkit-user-select: none;";g+=this.Pa+"transform: ";var h="";var l=1;this.Rf&&(l=100);h=4>b?h+("rotateY("+-90*b+"deg)"):h+("rotateX("+(4==b?-90:90)+"deg)");this.Rf&&(h+=" scale("+l+")");h+=" translate3d("+-e/2+"px,"+-e/2+"px,"+-e*l/(2*this.bf)+"px)";g+=h+";";f.nm=h;a||(f.W.setAttribute("style",g),this.L.insertBefore(f.W,this.L.firstChild))}if(!a){for(b=
0;6>b;b++)f=this.cube.faces[b],""!=this.qf[b]&&(f.Nd=new Image,f.Nd.crossOrigin=this.crossOrigin,f.Nd.onload=this.Al(f),f.Nd.setAttribute("src",this.Pb(this.qf[b])),this.gc.push(f.Nd));for(b=0;6>b;b++)f=this.cube.faces[b],f.loaded=!1,f.v=new Image,f.v.crossOrigin=this.crossOrigin,f.v.onload=this.Al(f),f.v.setAttribute("src",this.Pb(this.sg[b])),this.gc.push(f.v)}};c.prototype.je=function(){var a;this.Ka.na.x=0;this.Ka.na.y=0;if(this.hd){for(a=0;a<this.cube.faces.length;a++)this.cube.faces[a].W&&this.cube.faces[a].W.setAttribute&&
(this.cube.faces[a].W.setAttribute("src",this.Fl),this.L.removeChild(this.cube.faces[a].W));if(this.v.levels){for(a=0;a<this.v.levels.length;a++){var b=this.v.levels[a];for(f in b.ba)if(b.ba.hasOwnProperty(f)){var e=b.ba[f];e.visible=!1;e.W&&(e.cb&&e.cb.clearRect(0,0,e.cb.canvas.width,e.cb.canvas.height),this.hj.push(e.W));e.v&&delete e.v;e.rb&&(this.S.deleteTexture(e.rb),this.qd--);e.cb=null;e.W=null;e.v=null}delete b.ba}delete this.v.levels;this.v.levels=null}}this.za.je();var f=[];for(a=0;a<this.T.length;a++)b=
this.T[a],b.cd?f.push(b):b.Te();for(a=0;a<this.fb.length;a++)this.fb[a].Te();this.I.Vg=-1;this.Ja.style.visibility="hidden";this.Xa=0;this.Ze=[];this.Ya.Ch=[];for(a=0;a<this.Y.length;a++)b=this.Y[a],0==b.mode||b.Rm||this.Ze.push(b);this.T=f;this.fb=[];this.F.j&&(this.aa.removeChild(this.F.j),this.F.j=null,a=this.xb("_videopanorama"),0<a.length&&(a[0].j=null));this.F.td=!1;this.F.ui=!1};c.prototype.jm=function(){var a=1,b=-1!=navigator.userAgent.indexOf("Mac");window.devicePixelRatio&&b&&(a=window.devicePixelRatio);
return{w:screen.width*a,h:screen.height*a}};c.prototype.cm=function(){var a=this.jm();return a.w>a.h?a.w:a.h};c.prototype.yk=function(a,b){var e=(new DOMParser).parseFromString(a,"text/xml");this.Ij=a;this.dn(e,b);this.ra&&(this.O("Apply to Flash player"),this.ra.readConfigString(this.Ij),this.ra.setLocked(!0),this.ra.setSlaveMode(!0))};c.prototype.cn=function(a,b,e){try{var f=void 0;f=new XMLHttpRequest;f.open("GET",a,!1);f.send(null);if(f.responseXML){var g=a.lastIndexOf("/");0<=g&&(this.Vd=a.substr(0,
g+1));2<=arguments.length&&null!=b&&(this.Vd=b);this.yk(f.responseText,e)}else alert("Error loading panorama XML")}catch(h){alert("Error:"+h)}};c.prototype.Wq=function(a,b,e,f){var g=new XMLHttpRequest;var h=this;g.onload=function(l){if(4<=g.readyState)if(g.responseXML){var k=a.lastIndexOf("/");0<=k&&(h.Vd=a.substr(0,k+1));3<=arguments.length&&null!=e&&(h.Vd=e);h.yk(g.responseText,f);b&&b()}else alert("Error loading panorama XML");else console.error("Wrong state loading XML:"+g.statusText)};g.onerror=
function(){console.error("Error loading XML:"+g.statusText)};g.open("GET",a,!0);g.send(null)};c.prototype.xj=function(a){var b="";"{"==a.charAt(0)&&(b=a.substr(1,a.length-2));(a=this.Xd[b])&&(b=a);a={oldNodeId:this.Qa,nodeId:b};this.R("beforechangenodeid",a);this.Yj?this.Yj=!1:this.sk.push(this.Qa);""!=this.Qa&&-1==this.mj.indexOf(this.Qa)&&(this.mj.push(this.Qa),this.R("changevisitednodes",{}));this.Im=this.Qa;this.Qa=b;this.O("change active node: "+b);this.la&&this.la.changeActiveNode&&this.la.changeActiveNode("{"+
b+"}");this.R("changenodeid",a);this.vf=!0};c.prototype.Uj=function(){return this.Qa};c.prototype.Dp=function(){if(0<this.Za.length){var a=this.Za.indexOf(this.Qa);a++;a>=this.Za.length&&(a=0);return this.Za[a]}return""};c.prototype.Pp=function(){if(0<this.Za.length){var a=this.Za.indexOf(this.Qa);a--;0>a&&(a=this.Za.length-1);return this.Za[a]}return""};c.prototype.wp=function(){return this.Im};c.prototype.Bq=function(a){return-1!=this.mj.indexOf(a)};c.prototype.To=function(){this.mj=[];this.R("changevisitednodes",
{})};c.prototype.dn=function(a,b){var e=a.firstChild;this.pe=[];this.Za=[];this.Xd=[];for(a=e.firstChild;a;){if("map"==a.nodeName){var f={},g=a.getAttributeNode("title");g&&(f.title=g.nodeValue.toString());g=a.getAttributeNode("type");f.type=g.nodeValue.toString();"web"==f.type?(g=a.getAttributeNode("mapprovider"),f.mapprovider=g.nodeValue.toString(),(g=a.getAttributeNode("mapstyle"))&&(f.mapstyle=g.nodeValue.toString()),(g=a.getAttributeNode("googlecustomstylecode"))&&(f.googlecustomstylecode=g.nodeValue.toString()),
(g=a.getAttributeNode("mapurltemplate"))&&(f.mapurltemplate=g.nodeValue.toString()),(g=a.getAttributeNode("mapmaxzoom"))&&(f.mapmaxzoom=Number(g.nodeValue)),(g=a.getAttributeNode("mapkey"))&&(f.mapkey=g.nodeValue.toString()),(g=a.getAttributeNode("styleurl"))&&(f.styleurl=g.nodeValue.toString())):(g=a.getAttributeNode("width"),f.width=Number(g.nodeValue),g=a.getAttributeNode("height"),f.height=Number(g.nodeValue),g=a.getAttributeNode("zoomlevels"),f.zoomlevels=Number(g.nodeValue),g=a.getAttributeNode("tileformat"),
f.tileformat=g.nodeValue.toString(),g=a.getAttributeNode("bgcolor"),f.bgcolor=g.nodeValue.toString(),g=a.getAttributeNode("transparent"),f.transparent=1==g.nodeValue,g=a.getAttributeNode("floorplannorth"),f.floorplannorth=Number(g.nodeValue));g=a.getAttributeNode("id");this.Ci[g.nodeValue.toString()]=f}a=a.nextSibling}if("tour"==e.nodeName){this.Ef=!0;a="";(g=e.getAttributeNode("start"))&&(a=g.nodeValue.toString());this.hasOwnProperty("startNode")&&this.startNode&&(a=String(this.startNode),this.startNode=
"");this.hasOwnProperty("startView")&&this.startView&&("object"===typeof this.startView&&null!==this.startView?b=this.startView:""!=this.startView&&(b=String(this.startView)),this.startView="");f=e.firstChild;var h="";for(e="";f;){if("panorama"==f.nodeName){if(g=f.getAttributeNode("id"))h=g.nodeValue.toString(),""==a&&(a=h),""==e&&(e=h),this.pe[h]=f,this.Za.push(h);for(g=f.firstChild;g;){if("userdata"==g.nodeName){var l=this.yg(g);this.Jh[h]=l;h==a&&(this.Jh._first=l);l.customnodeid&&(this.Xd[l.customnodeid]=
h);this.Kc[h]=this.Gl(g);this.Jf[h]=this.Hl(g)}g=g.nextSibling}}if("masternode"==f.nodeName)for(g=f.firstChild;g;)"userdata"==g.nodeName&&(l=this.yg(g),this.Jh._master=l),g=g.nextSibling;f=f.nextSibling}this.pe.hasOwnProperty(a)||(g=this.Xd[a])&&(a=g);this.pe.hasOwnProperty(a)||(this.Jc("Start node "+a+" not found!"),a=e);this.xk(this.pe[a],b);this.xj("{"+a+"}");this.Qa=a}else this.Ef=!1,this.xk(e,b),this.xj(""),this.Za.push("");this.ef&&(this.O("add pano vr config"),this.mb.ig());this.R("configloaded",
{});this.R("changenode",{});this.R("playerstatechanged",{})};c.prototype.xk=function(a,b){var e=this;this.jn();this.Ta&&this.Ta.Yq();this.Uf(this.ob);this.je();this.Wg=0;for(var f=a.firstChild,g,h,l=0;f;){if("view"==f.nodeName){if(g=f.getAttributeNode("fovmode"))this.fov.mode=Number(g.nodeValue);g=f.getAttributeNode("pannorth");this.pan.tk=1*(g?g.nodeValue:0);for(var k=f.firstChild;k;){"start"==k.nodeName&&(g=k.getAttributeNode("pan"),this.pan.m=Number(g?g.nodeValue:0),this.pan.eb=this.pan.m,g=k.getAttributeNode("tilt"),
this.A.m=Number(g?g.nodeValue:0),this.A.eb=this.A.m,g=k.getAttributeNode("roll"),this.V.m=Number(g?g.nodeValue:0),this.V.eb=this.V.m,g=k.getAttributeNode("fov"),this.fov.m=Number(g?g.nodeValue:70),this.fov.eb=this.fov.m,g=k.getAttributeNode("projection"),this.Ki=Number(g?g.nodeValue:4),this.Nc(this.Ki));"min"==k.nodeName&&(g=k.getAttributeNode("pan"),this.pan.min=1*(g?g.nodeValue:0),g=k.getAttributeNode("tilt"),this.A.min=1*(g?g.nodeValue:-90),g=k.getAttributeNode("fov"),this.fov.min=1*(g?g.nodeValue:
5),1E-20>this.fov.min&&(this.fov.min=1E-20),g=k.getAttributeNode("fovpixel"),this.fov.gh=1*(g?g.nodeValue:0));if("max"==k.nodeName){g=k.getAttributeNode("pan");this.pan.max=1*(g?g.nodeValue:0);g=k.getAttributeNode("tilt");this.A.max=1*(g?g.nodeValue:90);g=k.getAttributeNode("fov");this.fov.max=1*(g?g.nodeValue:120);180<=this.fov.max&&(this.fov.max=179.9);if(g=k.getAttributeNode("fovstereographic"))this.fov.rk=1*g.nodeValue;if(g=k.getAttributeNode("fovfisheye"))this.fov.qk=1*g.nodeValue;if(g=k.getAttributeNode("scaletofit"))this.M.qn=
1==g.nodeValue}if("flyin"==k.nodeName){if(g=k.getAttributeNode("projection"))this.Fc.Lb=Number(g.nodeValue);if(g=k.getAttributeNode("pan"))this.Fc.pan=parseFloat(g.nodeValue);if(g=k.getAttributeNode("tilt"))this.Fc.A=parseFloat(g.nodeValue);if(g=k.getAttributeNode("fov"))this.Fc.fov=parseFloat(g.nodeValue)}k=k.nextSibling}}if("autorotate"==f.nodeName){if(g=f.getAttributeNode("speed"))this.C.speed=1*g.nodeValue;if(g=f.getAttributeNode("delay"))this.C.timeout=1*g.nodeValue;if(g=f.getAttributeNode("returntohorizon"))this.C.fj=
1*g.nodeValue;if(g=f.getAttributeNode("nodedelay"))this.C.Hi=1*g.nodeValue;if(g=f.getAttributeNode("noderandom"))this.C.Tm=1==g.nodeValue;(g=f.getAttributeNode("nodefilter"))&&!this.C.Sm&&(this.C.Kf=g.nodeValue);this.Zd&&(this.C.enabled=!0,this.C.jf=!0,this.C.active=!1);this.C.Kd=0;if(g=f.getAttributeNode("startloaded"))this.C.xh=1==g.nodeValue,this.C.xh&&(this.C.active=!1);if(g=f.getAttributeNode("useanimation"))this.C.Ih=1==g.nodeValue,this.C.dg=this.C.Ih;if(g=f.getAttributeNode("syncanimationwithvideo"))this.C.Pk=
1==g.nodeValue}if("animation"==f.nodeName){if(g=f.getAttributeNode("syncanimationwithvideo"))this.C.Pk=1==g.nodeValue;if(g=f.getAttributeNode("useinautorotation"))this.C.Ih=1==g.nodeValue;if(g=f.getAttributeNode("animsequence"))this.C.Sh=g.nodeValue,this.Zd&&(this.C.Ud=this.C.Sh);this.xa=[];for(k=f.firstChild;k;){if("clip"==k.nodeName){this.J=new r.bl;if(g=k.getAttributeNode("animtitle"))this.J.hf=g.nodeValue.toString();if(g=k.getAttributeNode("cliptitle"))this.J.bb=g.nodeValue.toString();if(g=k.getAttributeNode("nodeid"))this.J.As=
g.nodeValue.toString();if(g=k.getAttributeNode("length"))this.J.length=Number(g.nodeValue);if(g=k.getAttributeNode("animtype"))this.J.Bo=Number(g.nodeValue);if(g=k.getAttributeNode("nextcliptitle"))this.J.Pm=g.nodeValue.toString();if(g=k.getAttributeNode("nextclipnodeid"))this.J.Gi=g.nodeValue.toString();if(g=k.getAttributeNode("nextclipstartview"))this.J.Aq=g.nodeValue.toString();if(g=k.getAttributeNode("transitiontype"))this.J.$r=Number(g.nodeValue);var q=k.firstChild;for(this.J.da=[];q;){if("keyframe"==
q.nodeName){var p=new r.Uc;if(g=q.getAttributeNode("time"))p.time=Number(g.nodeValue);if(g=q.getAttributeNode("value"))p.value=Number(g.nodeValue);if(g=q.getAttributeNode("valuestring"))p.Yk=g.nodeValue.toString();if(g=q.getAttributeNode("transitiontime"))p.Eb=Number(g.nodeValue);g=q.getAttributeNode("type");var w=0;g&&(p.type=Number(g.nodeValue),w=Number(g.nodeValue));if(g=q.getAttributeNode("property"))p.tb=Number(g.nodeValue);if(g=q.getAttributeNode("additionaltrackid"))p.Qh=g.nodeValue.toString();
if(1==w||2==w){if(g=q.getAttributeNode("bezierintime"))p.ve=Number(g.nodeValue);if(g=q.getAttributeNode("bezierinvalue"))p.we=Number(g.nodeValue);if(g=q.getAttributeNode("bezierouttime"))p.xe=Number(g.nodeValue);if(g=q.getAttributeNode("bezieroutvalue"))p.ye=Number(g.nodeValue)}this.J.da.push(p)}q=q.nextSibling}this.xa.push(this.J)}k=k.nextSibling}}"input"==f.nodeName&&(h||(h=f));if(h)for(q=0;6>q;q++)g=h.getAttributeNode("prev"+q+"url"),this.qf[q]=g?String(g.nodeValue):"";"altinput"==f.nodeName&&
(k=0,(g=f.getAttributeNode("screensize"))&&(k=1*g.nodeValue),0<k&&k<=this.cm()&&k>l&&(l=k,h=f));if("control"==f.nodeName&&this.Zd){if(g=f.getAttributeNode("simulatemass"))this.Ka.enabled=1==g.nodeValue;if(g=f.getAttributeNode("rubberband"))this.M.pn=1==g.nodeValue;if(g=f.getAttributeNode("locked"))this.M.jc=1==g.nodeValue;g&&(this.M.bh=1==g.nodeValue);if(g=f.getAttributeNode("lockedmouse"))this.M.jc=1==g.nodeValue;if(g=f.getAttributeNode("lockedkeyboard"))this.M.bh=1==g.nodeValue;if(g=f.getAttributeNode("lockedkeyboardzoom"))this.M.pq=
1==g.nodeValue;if(g=f.getAttributeNode("lockedwheel"))this.M.be=1==g.nodeValue;if(g=f.getAttributeNode("invertwheel"))this.M.xm=1==g.nodeValue;if(g=f.getAttributeNode("speedwheel"))this.M.Dn=1*g.nodeValue;if(g=f.getAttributeNode("invertcontrol"))this.M.Hd=1==g.nodeValue;if(g=f.getAttributeNode("sensitivity"))this.M.sensitivity=1*g.nodeValue,1>this.M.sensitivity&&(this.M.sensitivity=1);if(g=f.getAttributeNode("dblclickfullscreen"))this.M.Kj=1==g.nodeValue;if(g=f.getAttributeNode("contextfullscreen"))this.M.rg=
1==g.nodeValue;if(g=f.getAttributeNode("contextprojections"))this.M.Wh=1==g.nodeValue;if(g=f.getAttributeNode("hideabout"))this.M.Bf=1==g.nodeValue;for(k=f.firstChild;k;)"menulink"==k.nodeName&&(q={text:"",url:""},g=k.getAttributeNode("text"),q.text=g.nodeValue,g=k.getAttributeNode("url"),q.url=g.nodeValue,this.fh.push(q)),k=k.nextSibling}if("transition"==f.nodeName&&this.Zd){if(g=f.getAttributeNode("enabled"))this.K.enabled=1==g.nodeValue;if(g=f.getAttributeNode("blendtime"))this.K.lg=1*g.nodeValue;
if(g=f.getAttributeNode("blendcolor"))this.K.lf=g.nodeValue.toString();if(g=f.getAttributeNode("type"))this.K.type=g.nodeValue.toString();if(g=f.getAttributeNode("softedge"))this.K.Oc=1*g.nodeValue;if(g=f.getAttributeNode("zoomin"))this.K.sa=1*g.nodeValue;if(g=f.getAttributeNode("zoomout"))this.K.sc=1*g.nodeValue;if(g=f.getAttributeNode("zoomfov"))this.K.gg=1*g.nodeValue;if(g=f.getAttributeNode("zoomspeed"))this.K.te=1*g.nodeValue;if(g=f.getAttributeNode("zoomoutpause"))this.K.hg=1==g.nodeValue;"cut"==
this.K.type&&(this.K.lg=0)}if("soundstransition"==f.nodeName){if(g=f.getAttributeNode("enabled"))this.Ya.enabled=1==g.nodeValue;if(g=f.getAttributeNode("transitiontime"))this.Ya.Eb=1*g.nodeValue;if(g=f.getAttributeNode("crossfade"))this.Ya.yl=1==g.nodeValue}if("flyintransition"==f.nodeName){if(g=f.getAttributeNode("enabled"))this.yb.enabled=1==g.nodeValue&&this.ia;if(g=f.getAttributeNode("speed"))this.yb.speed=1*g.nodeValue}"userdata"==f.nodeName&&(this.userdata=this.eg=this.yg(f),this.Kc[a.id]||
(this.Kc[a.id]=this.Gl(f),this.Jf[a.id]=this.Hl(f)));if("hotspots"==f.nodeName)for(k=f.firstChild;k;){if("label"==k.nodeName&&this.Zd){q=this.I.cj;if(g=k.getAttributeNode("enabled"))q.enabled=1==g.nodeValue;if(g=k.getAttributeNode("width"))q.width=1*g.nodeValue;if(g=k.getAttributeNode("height"))q.height=1*g.nodeValue;if(g=k.getAttributeNode("textcolor"))q.dj=1*g.nodeValue;if(g=k.getAttributeNode("textalpha"))q.bj=1*g.nodeValue;if(g=k.getAttributeNode("background"))q.background=1==g.nodeValue;if(g=
k.getAttributeNode("backgroundalpha"))q.bc=1*g.nodeValue;if(g=k.getAttributeNode("backgroundcolor"))q.cc=1*g.nodeValue;if(g=k.getAttributeNode("border"))q.Uh=1*g.nodeValue;if(g=k.getAttributeNode("bordercolor"))q.ec=1*g.nodeValue;if(g=k.getAttributeNode("borderalpha"))q.dc=1*g.nodeValue;if(g=k.getAttributeNode("borderradius"))q.tj=1*g.nodeValue;if(g=k.getAttributeNode("wordwrap"))q.nj=1==g.nodeValue}if("polystyle"==k.nodeName&&this.Zd){if(g=k.getAttributeNode("mode"))this.I.mode=1*g.nodeValue;if(g=
k.getAttributeNode("bordercolor"))this.I.ec=1*g.nodeValue;if(g=k.getAttributeNode("backgroundcolor"))this.I.cc=1*g.nodeValue;if(g=k.getAttributeNode("borderalpha"))this.I.dc=1*g.nodeValue;if(g=k.getAttributeNode("backgroundalpha"))this.I.bc=1*g.nodeValue;if(g=k.getAttributeNode("handcursor"))this.I.zf=1==g.nodeValue}g=void 0;"hotspot"==k.nodeName&&(g=new r.Oh(this),g.type="point",g.Yb(k),this.X.push(g));"polyhotspot"==k.nodeName&&(g=new r.Oh(this),g.type="poly",g.Yb(k),this.X.push(g));k=k.nextSibling}if("sounds"==
f.nodeName||"media"==f.nodeName)for(k=f.firstChild;k;){if("sound"==k.nodeName&&!this.Qm)for(g=new r.ro(this),g.Yb(k),this.Nb||g.addElement(),q=0;q<this.Ze.length;q++)g.id==this.Ze[q].id&&(this.Ze.splice(q,1),q--);"video"==k.nodeName&&(g=new r.fl(this),g.Yb(k),this.Nb||g.addElement());"image"==k.nodeName&&(g=new r.po(this),g.Yb(k),this.Nb||g.addElement());"lensflare"==k.nodeName&&this.Ta&&(g=new r.qo(this),g.Yb(k),this.Ta.ah.push(g));k=k.nextSibling}f=f.nextSibling}for(q=0;q<this.Ze.length;q++){a=
this.Ze[q];if(this.wa&&this.Ya.enabled&&this.isPlaying(a.id))this.Ya.Ch.push(a);else{try{a.va?a.mf():a.j.pause()}catch(y){this.O(y)}a.Te()}this.Y.splice(this.Y.indexOf(a),1)}1!=this.K.sa&&2!=this.K.sa&&6!=this.K.sa&&this.Jl();this.kb.rh=!0;b&&("object"===typeof b&&null!==b?(b.hasOwnProperty("pan")&&this.Xe(Number(b.pan)),b.hasOwnProperty("tilt")&&this.Ye(Number(b.tilt)),b.hasOwnProperty("fov")&&this.We(Number(b.fov)),b.hasOwnProperty("projection")&&this.Nc(Number(b.projection))):""!=b&&(b=b.toString().split("/"),
4<b.length&&this.Nc(Number(b[4])),0<b.length&&(g=String(b[0]),"N"==g.charAt(0)?this.Gk(Number(g.substr(1))):"S"==g.charAt(0)?this.Gk(-180+Number(g.substr(1))):this.Xe(Number(g))),1<b.length&&this.Ye(Number(b[1])),2<b.length&&this.We(Number(b[2]))),this.pan.open=this.pan.m);if(h){g=h.getAttributeNode("stereo");this.Jd=!1;g&&1==g.nodeValue&&(this.Jd=!0);g=h.getAttributeNode("fliplr");this.yh=!1;g&&1==g.nodeValue&&(this.yh=!0);for(q=0;q<(this.Jd?12:6);q++)(g=h.getAttributeNode("tile"+q+"url"))&&(this.sg[q]=
String(g.nodeValue));for(q=0;6>q;q++)(g=h.getAttributeNode("prev"+q+"url"))&&(this.qf[q]=String(g.nodeValue));if(g=h.getAttributeNode("tilevrurl"))this.zl=String(g.nodeValue);if(g=h.getAttributeNode("tilesize"))this.Dc=1*g.nodeValue;if(g=h.getAttributeNode("canvassize"))this.mg=Number(g.nodeValue);if(g=h.getAttributeNode("tilescale"))this.bf=1*g.nodeValue;if(g=h.getAttributeNode("leveltileurl"))this.v.mk=g.nodeValue;if(g=h.getAttributeNode("leveltilesize"))this.v.N=Number(g.nodeValue);if(g=h.getAttributeNode("levelbias"))this.v.Lm=
Number(g.nodeValue);if(g=h.getAttributeNode("levelbiashidpi"))this.v.Mm=Number(g.nodeValue);g=h.getAttributeNode("overlap");this.Oa.V=0;this.Oa.pitch=0;g&&(this.v.Ea=Number(g.nodeValue));if(g=h.getAttributeNode("levelingroll"))this.Oa.V=Number(g.nodeValue);if(g=h.getAttributeNode("levelingpitch"))this.Oa.pitch=Number(g.nodeValue);this.Xa=0;(g=h.getAttributeNode("flat"))&&1==g.nodeValue&&(this.Xa=2);g=h.getAttributeNode("width");this.v.width=1*(g?g.nodeValue:1);g=h.getAttributeNode("height");this.v.height=
1*(g?g.nodeValue:this.v.width);this.F.src=[];this.v.levels=[];for(k=h.firstChild;k;){if("preview"==k.nodeName){if(g=k.getAttributeNode("color"))this.v.Pf=g.nodeValue;if(g=k.getAttributeNode("strip"))this.v.an=1==g.nodeValue}if("video"==k.nodeName){if(g=k.getAttributeNode("format"))"3x2"==g.nodeValue&&(this.F.format=14),"equirectangular"==g.nodeValue&&(this.F.format=1);if(g=k.getAttributeNode("flipy"))this.F.flipY=Number(g.nodeValue);if(g=k.getAttributeNode("startonload"))this.F.Mk=1==g.nodeValue;
if(g=k.getAttributeNode("startmutedmobile"))this.F.Fn=1==g.nodeValue;if(g=k.getAttributeNode("bleed"))this.F.kf=Number(g.nodeValue);if(g=k.getAttributeNode("endaction"))this.F.De=String(g.nodeValue);if(g=k.getAttributeNode("targetview"))this.F.Qk=String(g.nodeValue);if(g=k.getAttributeNode("width"))this.F.width=Number(g.nodeValue);if(g=k.getAttributeNode("height"))this.F.height=Number(g.nodeValue);for(q=k.firstChild;q;)"source"==q.nodeName&&(g=q.getAttributeNode("url"))&&this.F.src.push(g.nodeValue.toString()),
q=q.nextSibling}if("level"==k.nodeName){h=new r.el;g=k.getAttributeNode("width");h.width=1*(g?g.nodeValue:1);g=k.getAttributeNode("height");h.height=1*(g?g.nodeValue:h.width);if(g=k.getAttributeNode("preload"))h.cache=1==g.nodeValue;if(g=k.getAttributeNode("preview"))h.Se=1==g.nodeValue;h.U=Math.floor((h.width+this.v.N-1)/this.v.N);h.ea=Math.floor((h.height+this.v.N-1)/this.v.N);this.v.levels.push(h)}k=k.nextSibling}this.v.kk=this.v.levels.length}this.Af=!0;this.Fh&&(this.ia=this.hd=!1,this.vc||(this.O("dummy rendering"),
this.vc=document.createElement("canvas"),this.vc.width=100,this.vc.height=100,this.vc.id="dummycanvas",this.L.appendChild(this.vc)),this.Pc());this.ia&&this.S&&(this.za.vm(this.bf),this.za.wm());this.hd&&(0<this.v.levels.length?this.wl(!0):this.wl(!1),this.Wg=0);var x=this;0<this.v.levels.length&&this.v.an&&0==this.Xa&&(b=new Image,h=new r.el,h.Se=!0,h.cache=!0,h.U=h.ea=0,h.height=h.width=0,this.v.levels.push(h),b.crossOrigin=this.crossOrigin,b.onload=this.za.zq(b),b.setAttribute("src",this.ne(6,
this.v.kk-1,0,0)));if(0<this.F.src.length&&this.ia)if(this.Gh){this.F.j=document.createElement("video");this.F.j.crossOrigin=this.crossOrigin;this.F.j.setAttribute("style","display:none; max-width:none;");this.F.j.setAttribute("playsinline","playsinline");this.F.j.preload=!0;this.F.j.volume=this.ca;this.aa.appendChild(this.F.j);this.F.td=!1;this.F.Jn=!1;this.F.j.oncanplay=function(){if(!x.F.td){x.F.ui=!0;var y,z,fa=[],la=new r.Ha,B=x.S,db=x.F.j.videoWidth/3;x.F.width=x.F.j.videoWidth;x.F.height=x.F.j.videoHeight;
for(y=0;6>y;y++){var ja=y%3*db+x.F.kf;var id=ja+db-2*x.F.kf;var tf=4;3>y&&(tf+=db);var ih=tf+db-2*x.F.kf;for(z=0;4>z;z++){la.x=-1;la.y=-1;la.z=1;for(var hh=0;hh<z;hh++)la.nn();fa.push((0<la.x?ja:id)/(3*db),(0<la.y?ih:tf)/(2*db))}}B.bindBuffer(B.ARRAY_BUFFER,x.F.aj);B.bufferData(B.ARRAY_BUFFER,new Float32Array(fa),B.STATIC_DRAW)}};this.F.wb=function(){var y=x.xb("_videopanorama");return 0<y.length&&y[0].wb?y[0].wb:0};this.F.rn=function(y){var z=x.xb("_videopanorama");0<z.length&&(z[0].wb=y)};this.F.loop=
function(){return 0<x.F.wb()?(x.F.rn(x.F.wb()-1),x.F.j.play(),!0):!1};"exit"==this.F.De?this.F.j.onended=function(){x.F.ui=!1;x.F.td=!1;x.aa.removeChild(x.F.j);x.F.j=null;x.update()}:"stop"==this.F.De?x.F.j.onended=function(){x.F.loop()||x.update()}:"{"==this.F.De.charAt(0)?this.F.j.onended=function(){x.dd(x.F.De,x.F.Qk)}:this.F.j.loop=!0;for(q=0;q<this.F.src.length;q++)h=document.createElement("source"),h.setAttribute("src",this.Pb(this.F.src[q])),this.F.j.appendChild(h);h=this.xb("_videopanorama");
0<h.length?h[0].j=this.F.j:this.en("_videopanorama",this.F.j);if(this.F.Mk&&(h=this.F.j.play(),void 0!==h))h.then(function(){})["catch"](function(){e.F.Fn&&(e.F.j.muted=!0,e.F.j.play())})}else"{"==this.F.De.charAt(0)&&x.dd(x.F.De,x.F.Qk);this.hl();this.K.xd||this.Hn();this.update();this.Zd&&(this.Zd=!1,this.ta&&this.ta.ggViewerInit&&(this.ta.ggViewerInit(),this.R("viewerinit",{})),this.yb.enabled&&0==this.Xa&&this.ia&&(this.Nc(9),this.pan.m=this.Fc.pan,this.A.m=this.Fc.A,this.fov.m=this.Fc.fov,this.Wa=
this.Fc.Lb,this.J=this.Dg(!1),this.pan.m=this.J.da[0].value,this.A.m=this.J.da[1].value,this.fov.m=this.J.da[2].value,3==this.J.da[3].tb&&this.Nc(this.J.da[3].value),this.Wb=this.J.bb,this.Ri(!0),this.C.active=!1,this.C.Ag=!0));this.Pc()};c.prototype.uk=function(a,b){0<a.length&&(".xml"==a.substr(a.length-4)||".swf"==a.substr(a.length-4)||"{"==a.charAt(0)?this.dd(this.Pb(a),b):window.open(this.Pb(a),b))};c.prototype.Mr=function(){this.Af=this.isLoaded=!1;this.checkLoaded=this.gc=[];this.mh=0;this.ta&&
this.ta.ggReLoaded&&this.ta.ggReLoaded();this.R("beforechangenode",{})};c.prototype.bq=function(a){var b="";0<this.sk.length&&(b=this.sk.pop());""!=b&&(this.Yj=!0);this.dd("{"+b+"}",a)};c.prototype.dd=function(a,b){if(""!=a&&"{}"!=a){this.Mr();this.la&&this.la.hotspotProxyOut&&this.la.hotspotProxyOut(this.Da.id,this.Da.url);".swf"==a.substr(a.length-4)&&(a=a.substr(0,a.length-4)+".xml");var e="",f=null;"object"===typeof b&&null!==b?f=b:b&&(e=b.toString());b="/"+this.A.m+"/"+this.fov.m+"//"+this.Sa();
e=e.replace("$cur",this.pan.m+b);e=e.replace("$(cur)",this.pan.m+b);e=e.replace("$fwd","N"+this.Ge()+b);e=e.replace("$(fwd)","N"+this.Ge()+b);e=e.replace("$bwd","S"+this.Ge()+b);e=e.replace("$(bwd)","S"+this.Ge()+b);e=e.replace("$ap",String(this.pan.m));e=e.replace("$(ap)",String(this.pan.m));e=e.replace("$an",String(this.Ge()));e=e.replace("$(an)",String(this.Ge()));e=e.replace("$at",String(this.A.m));e=e.replace("$(at)",String(this.A.m));e=e.replace("$af",String(this.fov.m));e=e.replace("$(af)",
String(this.fov.m));e=e.replace("$ar",String(this.Sa()));e=e.replace("$(ar)",String(this.Sa()));""!=e&&(b=e.split("/"),3<b.length&&""!=b[3]&&(this.startNode=b[3]));b=null!==f?f:e;this.Fa();if("{"==a.charAt(0)){var g=a.substr(1,a.length-2);if(this.Qa==g&&this.ng)return;(f=this.Xd[g])&&(g=f);f=this.K;var h=this.S;if(this.pe[g]){this.ng=!0;if(this.K.enabled&&this.ia&&this.K.rc){f.qe||f.xd||this.Ri(!0);var l=void 0;"wipeleftright"==f.type?l=1:"wiperightleft"==f.type?l=2:"wipetopbottom"==f.type?l=3:"wipebottomtop"==
f.type?l=4:"wiperandom"==f.type&&(l=Math.ceil(4*Math.random()));f.Jj=l;h.bindFramebuffer(h.FRAMEBUFFER,f.rc);h.viewport(0,0,f.rc.width,f.rc.height);h.clear(h.COLOR_BUFFER_BIT|h.DEPTH_BUFFER_BIT);f.Bh=!0;this.Eh();f.Bh=!1;h.bindFramebuffer(h.FRAMEBUFFER,null);h.viewport(0,0,this.zb.width,this.zb.height);h=new Date;this.Da!=this.ob&&6!=f.sa?(f.Mh=this.Da.Xb/this.D.width,f.Nh=1-this.Da.Cb/this.D.height):(f.Mh=.5,f.Nh=.5);1!=f.sa&&2!=f.sa&&6!=f.sa?(f.Nk=h.getTime(),f.qe=!0):(f.ho=h.getTime(),f.xd=!0,
f.Fb=Math.sin(this.Tb()/2*Math.PI/180)/Math.sin(f.gg/2*Math.PI/180),f.Fb=Math.max(f.Fb,1),f.fo=1/f.te*f.Fb*.3)}this.xk(this.pe[g],b);this.xj(a);if(f.enabled&&this.ia&&0!=f.sc){f.$e=this.Hg();f.af=this.ii();f.Rd=this.Tb();f.wd=this.Sa();if(1==f.sc||3==f.sc)this.Wi(f.gg);else if(2==f.sc)this.Wi(this.Tb()+f.gg);else if(4==f.sc){for(g=b=0;g<this.xa.length;g++)this.xa[g].bb&&0==this.xa[g].bb.indexOf("__FlyIn")&&(b=this.xa[g]);0!=b?(this.Nc(this.hi(3,b).value),this.Xe(this.hi(0,b).value),this.Ye(this.hi(1,
b).value),this.We(this.hi(2,b).value)):(this.Nc(this.Fc.Lb),this.Xe(this.Fc.pan),this.Ye(this.Fc.A),this.Wi(this.Fc.fov))}f.hg||1==f.sa||2==f.sa||6==f.sa||(4==f.sc?(this.J=this.Dg(!0,f.$e,f.af,f.Rd),this.Wb=this.J.bb,this.C.active=!0,this.yb.running=!0):this.moveTo(f.$e,f.af,f.Rd,f.te,0,f.wd))}this.ra&&this.ra.openNext(a,e);this.ef&&(this.O("add pano opennext"),this.mb.ig());this.K.xd||this.K.qe||(this.qa&&this.Fj(),this.ng=!1)}else{this.Jc("invalid node id: "+g);return}}else this.cn(a,null,b);this.R("changenode",
{});this.update(5)}};c.prototype.Fp=function(){return this.Af?this.Ef?this.Za.slice(0):[""]:[]};c.prototype.yg=function(a){var b;var e={title:"",description:"",author:"",datetime:"",copyright:"",source:"",information:"",comment:"",latitude:0,longitude:0,customnodeid:"",tags:[]};if(a&&((b=a.getAttributeNode("title"))&&(e.title=b.nodeValue.toString()),(b=a.getAttributeNode("description"))&&(e.description=b.nodeValue.toString()),(b=a.getAttributeNode("author"))&&(e.author=b.nodeValue.toString()),(b=
a.getAttributeNode("datetime"))&&(e.datetime=b.nodeValue.toString()),(b=a.getAttributeNode("copyright"))&&(e.copyright=b.nodeValue.toString()),(b=a.getAttributeNode("source"))&&(e.source=b.nodeValue.toString()),(b=a.getAttributeNode("info"))&&(e.information=b.nodeValue.toString()),(b=a.getAttributeNode("comment"))&&(e.comment=b.nodeValue.toString()),(b=a.getAttributeNode("latitude"))&&(e.latitude=Number(b.nodeValue)),(b=a.getAttributeNode("longitude"))&&(e.longitude=Number(b.nodeValue)),(b=a.getAttributeNode("nodeid"))&&
(e.nodeid=b.nodeValue.toString()),(b=a.getAttributeNode("customnodeid"))&&(e.customnodeid=b.nodeValue.toString()),b=a.getAttributeNode("tags"))){a=b.nodeValue.toString().split("|");for(b=0;b<a.length;b++)""==a[b]&&(a.splice(b,1),b--);e.tags=a}return e};c.prototype.Gl=function(a){for(var b={},e=a.firstChild;e;){if("mapcoords"==e.nodeName){var f={x:0,y:0};a=e.getAttributeNode("x");f.x=Number(a.nodeValue);a=e.getAttributeNode("y");f.y=Number(a.nodeValue);a=e.getAttributeNode("mapid");b[a.nodeValue.toString()]=
f}e=e.nextSibling}return b};c.prototype.Hl=function(a){for(var b={},e=a.firstChild;e;){if("mapcoords"==e.nodeName){var f={x:0,y:0};a=e.getAttributeNode("x_floorplan_percent");f.x=Number(a.nodeValue);a=e.getAttributeNode("y_floorplan_percent");f.y=Number(a.nodeValue);a=e.getAttributeNode("mapid");b[a.nodeValue.toString()]=f}e=e.nextSibling}return b};c.prototype.Gg=function(a){return a?this.Jh[a]?this.Jh[a]:this.yg():this.eg};c.prototype.Wj=function(a){a=this.Gg(a);var b=[];""!=a.latitude&&0!=a.latitude&&
0!=a.longitude&&(b.push(a.latitude),b.push(a.longitude));return b};c.prototype.dm=function(a){for(var b=[],e=0;e<this.Za.length;e++){var f=this.Za[e],g=this.Gg(f);g&&g.tags.includes(a)&&b.push(f)}return b};c.prototype.Ip=function(a){return this.Gg(a).title};c.prototype.Ep=function(a,b){var e=-1;a=this.Wj(a);b=this.Wj(b);if(2==a.length&&2==b.length){e=Math.PI/180*(b[0]-a[0]);var f=Math.PI/180*(b[1]-a[1]);a=Math.sin(e/2)*Math.sin(e/2)+Math.sin(f/2)*Math.sin(f/2)*Math.cos(Math.PI/180*a[0])*Math.cos(Math.PI/
180*b[0]);e=12742E3*Math.atan2(Math.sqrt(a),Math.sqrt(1-a))}return e};c.prototype.xf=function(a,b){var e;for(e=0;e<this.J.da.length;e++)if(this.J.da[e].time==a&&this.J.da[e].tb==b)return this.J.da[e];return!1};c.prototype.hi=function(a,b){var e;for(e=0;e<b.da.length;e++)if(0==b.da[e].time&&b.da[e].tb==a)return b.da[e];return!1};c.prototype.Cp=function(a){var b,e=1E5,f=a,g=!1;for(b=0;b<this.J.da.length;b++)this.J.da[b].tb==a.tb&&this.J.da[b].time>a.time&&this.J.da[b].time<e&&(f=this.J.da[b],e=f.time,
g=!0);return g?f:!1};c.prototype.hp=function(a){for(var b=[],e=0;e<this.J.da.length;e++)if(this.J.da[e].time<=a&&4==this.J.da[e].tb){for(var f=!1,g=0;g<b.length;g++)if(b[g].Qh==this.J.da[e].Qh){b[g].time<this.J.da[e].time?b.splice(g,1):f=!0;break}f||b.push(this.J.da[e])}return b};c.prototype.Dg=function(a,b,e,f){for(var g=0;g<this.xa.length;g++)if(this.xa[g].bb&&0==this.xa[g].bb.indexOf("__FlyIn"))return this.xa[g];g=new r.al;g.bb="__FlyIn";g.le=this.pan.m;g.vh=this.A.m;g.Pd=this.fov.m;g.uh=this.Wa;
g.wd=this.Ki;a?(g.rf=!1,g.Be=!1,g.speed=this.K.te,g.Qd=b,g.me=e,g.Yf=f):(g.rf=!0,g.Be=!0,g.speed=this.yb.speed,g.Qd=this.pan.eb,g.me=this.A.eb,g.Yf=this.fov.eb);return this.Tl(g)};c.prototype.Tl=function(a){var b=new r.bl;b.bb=a.bb;b.hf="";b.da=[];for(var e=a.uh!=a.wd&&-1!=a.wd;-180>a.Qd;)a.Qd+=360;for(;180<a.Qd;)a.Qd-=360;var f=a.Qd-a.le;if(360==this.pan.max-this.pan.min){for(;-180>f;)f+=360;for(;180<f;)f-=360}var g=a.me-a.vh,h=a.Yf-a.Pd,l=Math.round(Math.sqrt(f*f+g*g+h*h)/a.speed*.33);e&&(l=Math.max(10,
l));b.length=l;if(a.Ce){var k=Math.ceil(.7*l);k=Math.min(15,k);k=Math.max(5,k);b.length=l+k;var q=.33*k}var p=a.Yf,w=l,x=0,y=l-1;if(e){var z=a.Pd;var fa=4==a.wd?120:this.Eg(a.wd);var la=a.Yf;h=la-a.Pd;var B=new r.Ec(0,a.Pd),db=new r.Ec(l,la),ja=new r.Ec,id=new r.Ec;id.init(l/3,a.Pd+h/3);ja.init(2*l/3,la-h/3);if(z>fa)for(;x<=l&&z>fa;)z=new r.Ec,z.sj(B,db,id,ja,x),z=z.y,x++;else x=1;x>=.8*l&&(w=x=Math.round(.8*l));0==x&&(x=1);fa=4==a.uh?120:this.Eg(a.uh);z=a.Yf;if(z>fa)for(;y>x&&z>fa;)z=new r.Ec,z.sj(B,
db,id,ja,y),z=z.y,y--}B=new r.Uc;B.time=0;B.tb=0;B.value=a.le;B.type=1;B.xe=l/3;B.ye=a.rf?a.le:a.le+f/3;b.da.push(B);B=new r.Uc;B.time=0;B.tb=1;B.value=a.vh;B.type=1;B.xe=l/3;B.ye=a.rf?a.vh:a.vh+g/3;b.da.push(B);B=new r.Uc;B.time=0;B.tb=2;B.value=a.Pd;B.type=1;B.xe=l/3;B.ye=a.rf?a.Pd:a.Pd+h/3;b.da.push(B);B=new r.Uc;B.time=0;B.tb=3;B.value=a.uh;B.type=0;B.Eb=0;b.da.push(B);e&&(B=new r.Uc,B.time=x,B.tb=3,B.value=a.wd,B.type=0,B.Eb=y-x,b.da.push(B));B=new r.Uc;B.time=l;B.tb=0;B.value=a.le+f;B.type=
1;B.ve=2*l/3;B.we=a.Be&&!a.Ce?B.value:B.value-f/3;a.Ce&&(B.xe=l+q,B.ye=B.value+q/l*f);b.da.push(B);B=new r.Uc;B.time=l;B.tb=1;B.value=a.me;B.type=1;B.ve=2*l/3;B.we=a.Be&&!a.Ce?a.me:a.me-g/3;a.Ce&&(B.xe=l+q,B.ye=B.value+q/l*g);b.da.push(B);B=new r.Uc;B.time=w;B.tb=2;B.value=p;B.type=1;B.ve=2*w/3;B.we=a.Be?p:p-h/3;b.da.push(B);a.Ce&&(B=new r.Uc,B.time=l+k,B.tb=0,B.value=a.le+f,B.type=1,B.ve=l+k-q,B.we=a.le+f,b.da.push(B),B=new r.Uc,B.time=l+k,B.tb=1,B.value=a.me,B.type=1,B.ve=l+k-q,B.we=a.me,b.da.push(B));
this.xa.push(b);return b};c.prototype.os=function(){this.F.j&&this.F.j.play()};c.prototype.ps=function(){this.F.j&&(this.F.j.pause(),this.F.j.currentTime=0)};c.prototype.ns=function(){this.F.j&&this.F.j.pause()};c.prototype.Cr=function(a){this.F.j&&(0>a&&(a=0),a>this.F.j.duration&&(a=this.F.j.duration-.1),this.F.j.currentTime=a,this.update())};c.prototype.Wp=function(){return this.F.j?this.F.j.currentTime:0};c.prototype.Vp=function(){if(this.F.j)return this.F.j};c.prototype.Br=function(a){if(this.F.j){var b=
!this.F.j.paused&&!this.F.j.ended,e=this.F.j.currentTime;this.F.j.pause();this.F.j.src=isNaN(parseInt(a,10))?String(a):this.F.src[parseInt(a,10)];b&&(this.F.j.onloadedmetadata=function(){this.currentTime=e;this.play();this.onloadedmetadata=null});this.F.j.currentTime=e}};c.prototype.ap=function(){this.Qm=!0};return c}();r.f=d})(ggP2VR||(ggP2VR={}));window.ggHasHtml5Css3D=Eh;window.ggHasWebGL=Fh;window.pano2vrPlayer=ggP2VR.f;ggP2VR.f.prototype.getVersion=ggP2VR.f.prototype.mm;
ggP2VR.f.prototype.readConfigString=ggP2VR.f.prototype.yk;ggP2VR.f.prototype.readConfigUrl=ggP2VR.f.prototype.cn;ggP2VR.f.prototype.readConfigUrlAsync=ggP2VR.f.prototype.Wq;ggP2VR.f.prototype.readConfigXml=ggP2VR.f.prototype.dn;ggP2VR.f.prototype.openUrl=ggP2VR.f.prototype.uk;ggP2VR.f.prototype.openNext=ggP2VR.f.prototype.dd;ggP2VR.f.prototype.goBack=ggP2VR.f.prototype.bq;ggP2VR.f.prototype.setMargins=ggP2VR.f.prototype.jr;ggP2VR.f.prototype.addListener=ggP2VR.f.prototype.addListener;
ggP2VR.f.prototype.on=ggP2VR.f.prototype.addListener;ggP2VR.f.prototype.removeEventListener=ggP2VR.f.prototype.removeEventListener;ggP2VR.f.prototype.off=ggP2VR.f.prototype.removeEventListener;ggP2VR.f.prototype.detectBrowser=ggP2VR.f.prototype.El;ggP2VR.f.prototype.initWebGL=ggP2VR.f.prototype.ad;ggP2VR.f.prototype.getPercentLoaded=ggP2VR.f.prototype.Lp;ggP2VR.f.prototype.setBasePath=ggP2VR.f.prototype.fr;ggP2VR.f.prototype.getBasePath=ggP2VR.f.prototype.Xl;ggP2VR.f.prototype.setViewerSize=ggP2VR.f.prototype.zn;
ggP2VR.f.prototype.getViewerSize=ggP2VR.f.prototype.Zp;ggP2VR.f.prototype.setSkinObject=ggP2VR.f.prototype.wr;ggP2VR.f.prototype.changeViewMode=ggP2VR.f.prototype.No;ggP2VR.f.prototype.getViewMode=ggP2VR.f.prototype.Xp;ggP2VR.f.prototype.changePolygonMode=ggP2VR.f.prototype.rl;ggP2VR.f.prototype.setPolygonMode=ggP2VR.f.prototype.rl;ggP2VR.f.prototype.getPolygonMode=ggP2VR.f.prototype.Np;ggP2VR.f.prototype.showOnePolyHotspot=ggP2VR.f.prototype.Bn;ggP2VR.f.prototype.hideOnePolyHotspot=ggP2VR.f.prototype.sm;
ggP2VR.f.prototype.changePolyHotspotColor=ggP2VR.f.prototype.Lo;ggP2VR.f.prototype.toggleOnePolyHotspot=ggP2VR.f.prototype.Vr;ggP2VR.f.prototype.changeViewState=ggP2VR.f.prototype.Oo;ggP2VR.f.prototype.getViewState=ggP2VR.f.prototype.Yp;ggP2VR.f.prototype.setRenderFlags=ggP2VR.f.prototype.nr;ggP2VR.f.prototype.getRenderFlags=ggP2VR.f.prototype.Qp;ggP2VR.f.prototype.setMaxTileCount=ggP2VR.f.prototype.xn;ggP2VR.f.prototype.getVFov=ggP2VR.f.prototype.Tb;ggP2VR.f.prototype.setVFov=ggP2VR.f.prototype.Wi;
ggP2VR.f.prototype.getHFov=ggP2VR.f.prototype.mp;ggP2VR.f.prototype.updatePanorama=ggP2VR.f.prototype.Eh;ggP2VR.f.prototype.isTouching=ggP2VR.f.prototype.Cm;ggP2VR.f.prototype.getIsMobile=ggP2VR.f.prototype.sp;ggP2VR.f.prototype.setIsMobile=ggP2VR.f.prototype.ir;ggP2VR.f.prototype.getIsTour=ggP2VR.f.prototype.tp;ggP2VR.f.prototype.getIsAutorotating=ggP2VR.f.prototype.pp;ggP2VR.f.prototype.getIsLoading=ggP2VR.f.prototype.rp;ggP2VR.f.prototype.getIsLoaded=ggP2VR.f.prototype.gi;
ggP2VR.f.prototype.getIsTileLoading=ggP2VR.f.prototype.$l;ggP2VR.f.prototype.getLastActivity=ggP2VR.f.prototype.vp;ggP2VR.f.prototype.getPan=ggP2VR.f.prototype.Hg;ggP2VR.f.prototype.getPanNorth=ggP2VR.f.prototype.Ge;ggP2VR.f.prototype.getPanDest=ggP2VR.f.prototype.Kp;ggP2VR.f.prototype.getPanN=ggP2VR.f.prototype.em;ggP2VR.f.prototype.setPan=ggP2VR.f.prototype.Xe;ggP2VR.f.prototype.setPanNorth=ggP2VR.f.prototype.Gk;ggP2VR.f.prototype.changePan=ggP2VR.f.prototype.ql;
ggP2VR.f.prototype.changePanLog=ggP2VR.f.prototype.Ko;ggP2VR.f.prototype.getTilt=ggP2VR.f.prototype.ii;ggP2VR.f.prototype.getTiltDest=ggP2VR.f.prototype.Rp;ggP2VR.f.prototype.setTilt=ggP2VR.f.prototype.Ye;ggP2VR.f.prototype.changeTilt=ggP2VR.f.prototype.sl;ggP2VR.f.prototype.changeTiltLog=ggP2VR.f.prototype.Mo;ggP2VR.f.prototype.getFov=ggP2VR.f.prototype.Vj;ggP2VR.f.prototype.getFovDest=ggP2VR.f.prototype.kp;ggP2VR.f.prototype.setFov=ggP2VR.f.prototype.We;ggP2VR.f.prototype.changeFov=ggP2VR.f.prototype.pl;
ggP2VR.f.prototype.changeFovLog=ggP2VR.f.prototype.yj;ggP2VR.f.prototype.getRoll=ggP2VR.f.prototype.im;ggP2VR.f.prototype.setRoll=ggP2VR.f.prototype.Ui;ggP2VR.f.prototype.setPanTilt=ggP2VR.f.prototype.lr;ggP2VR.f.prototype.setPanTiltFov=ggP2VR.f.prototype.Ti;ggP2VR.f.prototype.setDefaultView=ggP2VR.f.prototype.gr;ggP2VR.f.prototype.setLocked=ggP2VR.f.prototype.setLocked;ggP2VR.f.prototype.setLockedMouse=ggP2VR.f.prototype.vn;ggP2VR.f.prototype.setLockedKeyboard=ggP2VR.f.prototype.un;
ggP2VR.f.prototype.getLockedKeyboard=ggP2VR.f.prototype.xp;ggP2VR.f.prototype.setLockedWheel=ggP2VR.f.prototype.wn;ggP2VR.f.prototype.moveTo=ggP2VR.f.prototype.moveTo;ggP2VR.f.prototype.moveToEx=ggP2VR.f.prototype.Ei;ggP2VR.f.prototype.moveToDefaultView=ggP2VR.f.prototype.vq;ggP2VR.f.prototype.moveToDefaultViewEx=ggP2VR.f.prototype.wq;ggP2VR.f.prototype.addHotspotElements=ggP2VR.f.prototype.hl;ggP2VR.f.prototype.playSound=ggP2VR.f.prototype.fe;ggP2VR.f.prototype.playPauseSound=ggP2VR.f.prototype.$m;
ggP2VR.f.prototype.playStopSound=ggP2VR.f.prototype.Uq;ggP2VR.f.prototype.pauseSound=ggP2VR.f.prototype.vk;ggP2VR.f.prototype.activateSound=ggP2VR.f.prototype.uo;ggP2VR.f.prototype.soundGetTime=ggP2VR.f.prototype.Gr;ggP2VR.f.prototype.soundSetTime=ggP2VR.f.prototype.Hr;ggP2VR.f.prototype.setMediaVisibility=ggP2VR.f.prototype.kr;ggP2VR.f.prototype.isPlaying=ggP2VR.f.prototype.isPlaying;ggP2VR.f.prototype.stopSound=ggP2VR.f.prototype.$i;ggP2VR.f.prototype.setVolume=ggP2VR.f.prototype.setVolume;
ggP2VR.f.prototype.changeVolume=ggP2VR.f.prototype.Po;ggP2VR.f.prototype.removeHotspots=ggP2VR.f.prototype.jn;ggP2VR.f.prototype.getHotspotsVisible=ggP2VR.f.prototype.Yl;ggP2VR.f.prototype.getCurrentPerspective=ggP2VR.f.prototype.pd;ggP2VR.f.prototype.addHotspot=ggP2VR.f.prototype.wo;ggP2VR.f.prototype.updateHotspot=ggP2VR.f.prototype.ds;ggP2VR.f.prototype.removeHotspot=ggP2VR.f.prototype.Xq;ggP2VR.f.prototype.setActiveHotspot=ggP2VR.f.prototype.Uf;ggP2VR.f.prototype.getPointHotspotIds=ggP2VR.f.prototype.Mp;
ggP2VR.f.prototype.getHotspot=ggP2VR.f.prototype.op;ggP2VR.f.prototype.setFullscreen=ggP2VR.f.prototype.Vf;ggP2VR.f.prototype.toggleFullscreen=ggP2VR.f.prototype.gj;ggP2VR.f.prototype.enterFullscreen=ggP2VR.f.prototype.bp;ggP2VR.f.prototype.exitFullscreen=ggP2VR.f.prototype.exitFullscreen;ggP2VR.f.prototype.getIsFullscreen=ggP2VR.f.prototype.qp;ggP2VR.f.prototype.startAutorotate=ggP2VR.f.prototype.Lr;ggP2VR.f.prototype.stopAutorotate=ggP2VR.f.prototype.Or;ggP2VR.f.prototype.toggleAutorotate=ggP2VR.f.prototype.Ur;
ggP2VR.f.prototype.setAutorotateNodeFilter=ggP2VR.f.prototype.er;ggP2VR.f.prototype.startAnimation=ggP2VR.f.prototype.Kr;ggP2VR.f.prototype.createLayers=ggP2VR.f.prototype.xl;ggP2VR.f.prototype.removePanorama=ggP2VR.f.prototype.je;ggP2VR.f.prototype.getScreenResolution=ggP2VR.f.prototype.jm;ggP2VR.f.prototype.getMaxScreenResolution=ggP2VR.f.prototype.cm;ggP2VR.f.prototype.getNodeIds=ggP2VR.f.prototype.Fp;ggP2VR.f.prototype.getNodeUserdata=ggP2VR.f.prototype.Gg;ggP2VR.f.prototype.getNodeLatLng=ggP2VR.f.prototype.Wj;
ggP2VR.f.prototype.getNodeTitle=ggP2VR.f.prototype.Ip;ggP2VR.f.prototype.getNodeDistance=ggP2VR.f.prototype.Ep;ggP2VR.f.prototype.getCurrentNode=ggP2VR.f.prototype.Uj;ggP2VR.f.prototype.getNextNode=ggP2VR.f.prototype.Dp;ggP2VR.f.prototype.getPrevNode=ggP2VR.f.prototype.Pp;ggP2VR.f.prototype.getLastVisitedNode=ggP2VR.f.prototype.wp;ggP2VR.f.prototype.getNodesWithTag=ggP2VR.f.prototype.dm;ggP2VR.f.prototype.getCurrentPointHotspots=ggP2VR.f.prototype.jp;ggP2VR.f.prototype.getPositionAngles=ggP2VR.f.prototype.Op;
ggP2VR.f.prototype.getPositionRawAngles=ggP2VR.f.prototype.fm;ggP2VR.f.prototype.nodeVisited=ggP2VR.f.prototype.Bq;ggP2VR.f.prototype.clearVisitedNodes=ggP2VR.f.prototype.To;ggP2VR.f.prototype.setElementIdPrefix=ggP2VR.f.prototype.hr;ggP2VR.f.prototype.videoPanoPlay=ggP2VR.f.prototype.os;ggP2VR.f.prototype.videoPanoStop=ggP2VR.f.prototype.ps;ggP2VR.f.prototype.videoPanoPause=ggP2VR.f.prototype.ns;ggP2VR.f.prototype.getVideoPanoTime=ggP2VR.f.prototype.Wp;ggP2VR.f.prototype.setVideoPanoTime=ggP2VR.f.prototype.Cr;
ggP2VR.f.prototype.getVideoPanoObject=ggP2VR.f.prototype.Vp;ggP2VR.f.prototype.setVideoPanoSource=ggP2VR.f.prototype.Br;ggP2VR.f.prototype.getMediaObject=ggP2VR.f.prototype.Bp;ggP2VR.f.prototype.registerVideoElement=ggP2VR.f.prototype.en;ggP2VR.f.prototype.disableSoundLoading=ggP2VR.f.prototype.ap;ggP2VR.f.prototype.setCrossOrigin=ggP2VR.f.prototype.setCrossOrigin;ggP2VR.f.prototype.setProjection=ggP2VR.f.prototype.Nc;ggP2VR.f.prototype.getProjection=ggP2VR.f.prototype.Sa;
ggP2VR.f.prototype.changeProjection=ggP2VR.f.prototype.zj;ggP2VR.f.prototype.changeProjectionEx=ggP2VR.f.prototype.zj;ggP2VR.f.prototype.changeLensflares=ggP2VR.f.prototype.Jo;ggP2VR.f.prototype.setTransition=ggP2VR.f.prototype.yr;ggP2VR.f.prototype.getMapType=ggP2VR.f.prototype.Ap;ggP2VR.f.prototype.getMapDetails=ggP2VR.f.prototype.zp;ggP2VR.f.prototype.getNodeMapCoords=ggP2VR.f.prototype.Gp;ggP2VR.f.prototype.getNodeMapCoordsInPercent=ggP2VR.f.prototype.Hp;
ggP2VR.f.prototype.getMapContainingNode=ggP2VR.f.prototype.yp;ggP2VR.f.prototype.getMapsContainingNode=ggP2VR.f.prototype.bm;ggP2VR.f.prototype.getMapIDs=ggP2VR.f.prototype.am;ggP2VR.f.prototype.addVariable=ggP2VR.f.prototype.zo;ggP2VR.f.prototype.setVariableOptions=ggP2VR.f.prototype.yn;ggP2VR.f.prototype.setVariableValue=ggP2VR.f.prototype.ke;ggP2VR.f.prototype.getVariableValue=ggP2VR.f.prototype.Up;ggP2VR.f.prototype.getGyroAvailable=ggP2VR.f.prototype.lp;ggP2VR.f.prototype.setUseGyro=ggP2VR.f.prototype.zr;
ggP2VR.f.prototype.getUseGyro=ggP2VR.f.prototype.Sp;ggP2VR.f.prototype.getOS=ggP2VR.f.prototype.Jp;ggP2VR.f.prototype.getBrowser=ggP2VR.f.prototype.ip;ggP2VR.f.prototype.triggerEvent=ggP2VR.f.prototype.R;ggP2VR.f.prototype.requestRedraw=ggP2VR.f.prototype.Zq;ggP2VR.f.prototype.getWebGlContext=ggP2VR.f.prototype.$p;ggP2VR.f.prototype.getHasTouch=ggP2VR.f.prototype.np;ggP2VR.f.prototype.enterVR=ggP2VR.f.prototype.wg;ggP2VR.f.prototype.exitVR=ggP2VR.f.prototype.sf;ggP2VR.f.prototype.toggleVR=ggP2VR.f.prototype.Nn;
ggP2VR.f.prototype.isInVR=ggP2VR.f.prototype.Rg;ggP2VR.f.prototype.hasVR=ggP2VR.f.prototype.dk;ggP2VR.f.prototype.getVRDisplayName=ggP2VR.f.prototype.Tp;ggP2VR.f.prototype.setVRFrameBufferScaleFactor=ggP2VR.f.prototype.Ar;
