You are not logged in.

virtual pete

Intermediate

  • "virtual pete" started this thread

Posts: 245

Location: Nerja

Occupation: Holiday rentals Nerja Costa del Sol

  • Send private message

1

Thursday, November 28th 2013, 4:10pm

Lens flare help

Hi, I am having a few issues implementing the lens flare effect and I wonder if anyone would be kind enough to assist.

I have placed the krpano_default_flares.jpg image in the main vtour folder and I have the following code in my xml. I only have one pano to keep it simple.

<krpano version="1.16" title="Virtual Tour" onstart="startup();">

<include url="skin/vtourskin.xml" />

<!-- set skin settings: bingmaps? gyro? thumbnail controlling? tooltips? -->
<skin_settings bingmaps="false"
bingmaps_key=""
bingmaps_zoombuttons="false"
gyro="true"
thumbs_width="120" thumbs_height="80" thumbs_padding="10" thumbs_crop="0|40|240|160"
thumbs_opened="false"
thumbs_text="false"
thumbs_dragging="true"
thumbs_onhoverscrolling="false"
thumbs_scrollbuttons="false"
thumbs_scrollindicator="false"
tooltips_thumbs="false"
tooltips_hotspots="false"
tooltips_mapspots="false"
controlbar_offset="20"
/>


<plugin name="editor" url="plugins/editor.swf" keep="true" />

<!-- set optional skin logo url -->
<layer name="skin_logo" url="" scale="0.25" opened_onclick="openurl('...',_blank);" />


<action name="startup">
if(startscene === null, copy(startscene,scene[0].name));
loadscene(get(startscene), null, MERGE);
</action>


<scene name="scene_IMG_7759_Panorama" title="IMG_7759 Panorama" onstart="" thumburl="panos/IMG_7759_Panorama.tiles/thumb.jpg" lat=""

lng="" heading="">

<view hlookat="0" vlookat="0" fovtype="MFOV" fov="120" maxpixelzoom="2.0" fovmin="70" fovmax="140" limitview="auto" />

<preview url="panos/IMG_7759_Panorama.tiles/preview.jpg" />

<image>
<cube url="panos/IMG_7759_Panorama.tiles/pano_%s.jpg" />
<mobile>
<cube url="panos/IMG_7759_Panorama.tiles/mobile_%s.jpg" />
</mobile>
</image>

<!-- place your scene hotspots here -->

</scene>

<lensflare name="lf1" set="DEFAULT" ath="99.439178" atv="-32.10183" />
<lensflare name="default" set="DEFAULT" ath="-69.5034" atv="-4.752" size="0.40" blind="0.30" />

</krpano>

I got the xml snippets from the editor plugin but I cannot get it to work outside the editor. Can anyone see what I am doing wrong?

Many thanks as usual.

virtual pete

Intermediate

  • "virtual pete" started this thread

Posts: 245

Location: Nerja

Occupation: Holiday rentals Nerja Costa del Sol

  • Send private message

2

Tuesday, December 3rd 2013, 12:24pm

Any ideas as I am struggling with this ???

Alexey Tkachenko

Professional

Posts: 770

Location: Russian Federation

Occupation: Interpreting, Building virtual tours

  • Send private message

3

Tuesday, December 3rd 2013, 2:20pm

You are trying to place a lensflare outside the "scene" node. Place the flares between the line

Source code

1
<!-- place your scene hotspots here -->


and scene closing tag and they will work!
Regards,

Alexey

virtual pete

Intermediate

  • "virtual pete" started this thread

Posts: 245

Location: Nerja

Occupation: Holiday rentals Nerja Costa del Sol

  • Send private message

4

Tuesday, December 3rd 2013, 7:20pm

Thanks Alexey, I have done as you said as it makes sense but still it does not work :(

I have put the krpano_default_flares.jpg in all folders just in case!

Here is the xml I have:

<krpano version="1.16" onstart="bombtimer(0); startup();">

<include url="skin/vtourskin.xml" />

<!-- set skin settings: bingmaps? gyro? thumbnail controlling? tooltips? -->
<skin_settings bingmaps="false"
bingmaps_key=""
bingmaps_zoombuttons="false"
gyro="true"
thumbs_width="120" thumbs_height="80" thumbs_padding="10" thumbs_crop="0|40|240|160"
thumbs_opened="false"
thumbs_text="false"
thumbs_dragging="true"
thumbs_onhoverscrolling="false"
thumbs_scrollbuttons="false"
thumbs_scrollindicator="false"
tooltips_thumbs="false"
tooltips_hotspots="false"
tooltips_mapspots="false"
controlbar_offset="20"
/>

<!-- set optional skin logo url -->
<layer name="skin_logo" url="" scale="0.25" opened_onclick="openurl('...',_blank);" />




<action name="startup">
set(step,1); set(idletime,2); set(events.onidle, autotour(););
</action>

<action name="startup">
if(startscene === null, copy(startscene,scene[0].name));
loadscene(get(startscene), null, MERGE);
</action>

<action name="bombtimer">
set(bt,%1);
add(bt,1);
delayedcall(1, bombtimer(get(bt)));
if(bt == 42, set(bt,0); nextscene();, );
</action>

<action name="nextscene">
set(ns, get(scene[get(xml.scene)].index) );
set(maxs, get(scene.count) );
add(ns,1);
if(ns == maxs, set(ns,0);, );
loadscene( get(scene[get(ns)].name ), null, MERGE, BLEND(1.5) );
</action>

<autorotate enabled="true" waittime=".5" accel="5.0" speed="8.2" horizon="0.0" tofov="off"/>


<plugin name="editor" url="plugins/editor.swf" keep="true" />


<scene name="scene_IMG_7759_Panorama_Panorama" title="IMG_7759 Panorama Panorama" onstart=""

thumburl="panos/IMG_7759_Panorama_Panorama.tiles/thumb.jpg" lat="" lng="" heading="">

<view hlookat="0" vlookat="0" fovtype="MFOV" fov="120" maxpixelzoom="2.0" fovmin="70" fovmax="140" limitview="auto" />

<preview url="panos/IMG_7759_Panorama_Panorama.tiles/preview.jpg" />

<image>
<cube url="panos/IMG_7759_Panorama_Panorama.tiles/pano_%s.jpg" />
<mobile>
<cube url="panos/IMG_7759_Panorama_Panorama.tiles/mobile_%s.jpg" />
</mobile>
</image>



<lensflare name="lf1" set="DEFAULT" ath="99.439178" atv="-32.10183" />
<lensflare name="default" set="DEFAULT" ath="-69.5034" atv="-4.752" size="0.40" blind="0.30" />

<!-- place your scene hotspots here -->




</scene>

<scene name="scene_IMG_7768_Panorama" title="IMG_7768 Panorama" onstart="" thumburl="panos/IMG_7768_Panorama.tiles/thumb.jpg" lat=""

lng="" heading="">

<view hlookat="0" vlookat="0" fovtype="MFOV" fov="120" maxpixelzoom="2.0" fovmin="70" fovmax="140" limitview="auto" />

<preview url="panos/IMG_7768_Panorama.tiles/preview.jpg" />

<image>
<cube url="panos/IMG_7768_Panorama.tiles/pano_%s.jpg" />
<mobile>
<cube url="panos/IMG_7768_Panorama.tiles/mobile_%s.jpg" />
</mobile>
</image>

<!-- place your scene hotspots here -->

</scene>


</krpano>


I have to be doing something stupid for sure but I cannot see it :(
Should there be a lensflare plugin in the plugin folder?

Kind regards.
Pete

Alexey Tkachenko

Professional

Posts: 770

Location: Russian Federation

Occupation: Interpreting, Building virtual tours

  • Send private message

5

Tuesday, December 3rd 2013, 8:17pm

Are you wieving it in Flash? Lensflares work in Flash only, if I am not mistaken.
Regards,

Alexey

Alexey Tkachenko

Professional

Posts: 770

Location: Russian Federation

Occupation: Interpreting, Building virtual tours

  • Send private message

6

Tuesday, December 3rd 2013, 8:20pm

I aks because I tested quickly and all works. Does it give an error that "flare.jpg can't be loaded" or they just won't appear?
Regards,

Alexey

virtual pete

Intermediate

  • "virtual pete" started this thread

Posts: 245

Location: Nerja

Occupation: Holiday rentals Nerja Costa del Sol

  • Send private message

7

Tuesday, December 3rd 2013, 8:27pm

Hi Alexey, they just dont appesr, no messages at all. You can see it on line

http://www.holidaynerja.co.uk/krpano/tour.html
http://www.holidaynerja.co.uk/krpano/tour.xml

in the main folder krpano/
I have:
Folders - panos, plugins, skin
files - krpano_default_flares.jpg, tour.html, tour.js, tour.swf, tour.xml, tour_editor.html, vtoureditor.swf

I must be missing something :(

Alexey Tkachenko

Professional

Posts: 770

Location: Russian Federation

Occupation: Interpreting, Building virtual tours

  • Send private message

8

Tuesday, December 3rd 2013, 8:42pm

In Opera Flash I see a lensflare in the first pano, while in the second one there's some black polygonal form in the zenith. In chrome Flash I see these black forms in first and the second pano. See printscreens attached.
Alexey Tkachenko has attached the following images:
  • Opera.jpg
  • Chrome.jpg
Regards,

Alexey

virtual pete

Intermediate

  • "virtual pete" started this thread

Posts: 245

Location: Nerja

Occupation: Holiday rentals Nerja Costa del Sol

  • Send private message

9

Tuesday, December 3rd 2013, 9:40pm

Hi Alexey, yes both panos are not fully complete aroud the zenith or the nadir. It is strange you can get it to work in opera but nothing else. I am getting nothing on anything :(

virtual pete

Intermediate

  • "virtual pete" started this thread

Posts: 245

Location: Nerja

Occupation: Holiday rentals Nerja Costa del Sol

  • Send private message

10

Tuesday, December 3rd 2013, 9:43pm

I have discovered that is I view the lens flare in tour_editor.html it works fine but why would it not work normally??

http://www.holidaynerja.co.uk/krpano/tour_editor.html

Alexey Tkachenko

Professional

Posts: 770

Location: Russian Federation

Occupation: Interpreting, Building virtual tours

  • Send private message

11

Wednesday, December 4th 2013, 6:51am

Again, check your html file. I bet there is "html5="prefer" setting. That is why we see lensflare in Opera but don't see it in Chrome. Because Chrome goes to html5 automatically and Opera doesn't support it and goes to Flash. And lensflare is Flash-specific feature.
Regards,

Alexey

virtual pete

Intermediate

  • "virtual pete" started this thread

Posts: 245

Location: Nerja

Occupation: Holiday rentals Nerja Costa del Sol

  • Send private message

12

Wednesday, December 4th 2013, 10:20am

Hi Alexey, yes you are correct. With the help of Klaus I changed it to "html5="auto" and all is ok now.

Thanks for your help and time *smile*

13

Thursday, March 13th 2014, 4:47am

How i can get lensflare in html5?

virtual pete

Intermediate

  • "virtual pete" started this thread

Posts: 245

Location: Nerja

Occupation: Holiday rentals Nerja Costa del Sol

  • Send private message

14

Thursday, March 13th 2014, 10:52am

Hi Omegas, I do not think it is possible in html5 as yet.

Similar threads