From 19840dad0e3d873b92dfc1e786f9d1b34a542865 Mon Sep 17 00:00:00 2001 From: Victor Hugo Date: Thu, 30 Nov 2017 17:48:53 -0300 Subject: [PATCH 1/2] small addition of the variable is_stereo to make it clearer and easier for new users on how it can build their ambient with different panorama types --- examples/gallery/index.js | 1 + examples/hotspots/index.js | 6 +++++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/examples/gallery/index.js b/examples/gallery/index.js index 7302b63a..95cec065 100644 --- a/examples/gallery/index.js +++ b/examples/gallery/index.js @@ -60,6 +60,7 @@ function loadScene(id) { vrView.setContent({ image: scenes[id].image, preview: scenes[id].preview, + is_stereo: scenes[id].is_stereo || false, is_autopan_off: true }); diff --git a/examples/hotspots/index.js b/examples/hotspots/index.js index 93c336b3..ed16a763 100644 --- a/examples/hotspots/index.js +++ b/examples/hotspots/index.js @@ -19,6 +19,7 @@ var scenes = { dolphins: { image: 'dolphins.jpg', preview: 'dolphins-preview.jpg', + is_stereo: true, hotspots: { whaleRight: { pitch: 0, @@ -43,6 +44,7 @@ var scenes = { whaleLeft: { image: 'whale-left.jpg', preview: 'whale-left-preview.jpg', + is_stereo: true, hotspots: { whaleRight: { pitch: 0, @@ -67,6 +69,7 @@ var scenes = { whaleRight: { image: 'whale-right.jpg', preview: 'whale-right-preview.jpg', + is_stereo: true, hotspots: { dolphins: { pitch: 0, @@ -91,6 +94,7 @@ var scenes = { walrus: { image: 'walrus.jpg', preview: 'walrus-preview.jpg', + is_stereo: true, hotspots: { whaleLeft: { pitch: 0, @@ -158,7 +162,7 @@ function loadScene(id) { vrView.setContent({ image: scenes[id].image, preview: scenes[id].preview, - is_stereo: true, + is_stereo: scenes[id].is_stereo || false, is_autopan_off: true }); From 86fa6de6279ec3c60f99fd20955d60f9f0dd0861 Mon Sep 17 00:00:00 2001 From: Victor Hugo Date: Thu, 30 Nov 2017 21:50:00 -0300 Subject: [PATCH 2/2] feature that allows a hotspot to have its own icon if added 'icon: icon_path' in its definition. If no icon is assigned, a default hotspot is created --- images/hotspot_example.png | Bin 0 -> 2321 bytes src/api/player.js | 2 + src/embed/hotspot-renderer.js | 121 +++++++++++++++++++++++----------- src/embed/main.js | 3 +- 4 files changed, 86 insertions(+), 40 deletions(-) create mode 100644 images/hotspot_example.png diff --git a/images/hotspot_example.png b/images/hotspot_example.png new file mode 100644 index 0000000000000000000000000000000000000000..9b1b17383586d7de28194e300229cfe509870b79 GIT binary patch literal 2321 zcmV+s3GViZP)4$B8;%MnN? zAtuH)1vd$87{V23(zGGNG?}*3beca?>Og5HZPN*H+;pa)f6$qx!6hwIXjq}kv5zVG)v?Y{R`2P$)q!?BcGcU5!*1v>U5w}AZK9OAAP~BF8B38 zPtPT}t-YQ9Piq^2WB653lK#x`{A(ZgUusQvThrD7iz&*S3t0#BS>(aog=X`P9gi9| z-nSlS7#eiC*_A;EK_n7|mNV~3O-;>lmgR3GZzhiNH{kg2aEwb=+vh}Kp*ydHE`5oj zy*HkI=2`y2#Sf5LbY8fKp8C$SNyZc4=+eMTHk)lxCbeTW2ffF|_(#A0!Vi*zgF~tb zpGg0}0DA85^9hRaj}$wYCqSj4JSkRdiOcN^c5dEM&&9ew)J*t9BGDMCez=ZxdxITT ztCP}1e39Mth>P)$zS;biD9duj#4E_MjNWK!mKaZfEwa-MYHG(AxBr)`zOs&s#=0}D z`wk+}7+Se{9Y=ct#{d9Jt8%Z`tEWBwlXY7gSe}n(TI-~69FJj#@HBLz?l|oPK*&la%1Mj7y6ENE2Ke>DF0bY`%OlzAqk|d$sd!I~r zyum-gT!sVV2^`$&+n=BI+=c(h{GTF&O6 zw$Dhs)#{{Zx1SA%BbnAPXCl!Uaxp%(puoXQS3luU70OPkwjEpan6)YsK4(C3&BeeMqyQ!M*Un1NW1rg|PpQFWuf?znY5~^Mz1HC-QiM|5bEj z0H3bmEi{|VexFxEKLEnv2!z8CO=||r0$?;6a|?>83V`trFqlj`zxB->22EQ607n{+ z!jZl9!Z231v+f{u{aU<9cTR92K5HLDK)cV8hBDJ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