Go-To Hotspot -> Play a vid/sequence -> Load Pano?

  • Hey all! I've been using Panotour Pro to put together a tour, and I've been doing different experiments trying to come up with a final layout and structure for my final project.

    I'm curious to know what I would need to do to create a hotspot that loads the pano when you click it, but a video/img sequence plays first and THEN loads the next pano.

    So basically I'll be able to make sort of an animation from one pano to the next.

    I am not too familiar with krpano code, but I've messed around with it recently.

    I'm under the impression that I would have to edit the _core.xml in some fashion to make a loadscene do this sort of thing, but don't know enough to be able to code it where I can do multiple hotspots that load specific animations for that specific transition.


    Would anyone be able to offer any insight on how I might achieve this?


    Thank you so much in advance!

  • Hi

    First I wanted to tell you that this is not right place as you are asking how to change this or that xml file from XYZ software, but than I understood that you are at very right place. Although I can't give you exact answer as I don't know code structure of your tool, I can give you guidelines and hopefuly you could update your side xml in that way.
    Generaly you ask if you could make click on your hotspots first play video and than load new scene. Answer is yes, but.... There is but with this play video as this is not completely true in case of IOS devices where user must click on pano (or play button) to play the video. So there is kind of user iteraction needed to start video. It is possible to make your_play_video action which will play appropriate video file and when ended you trigger load of new scene.
    Made this now in my environment and it works. Will share code but this depends ofcourse on your code structure.
    Your hotspots that is now loading new scene have onclick attribute. If hotspot has style than look to style definition and onlick attribute there. This is to be changed not to loadscene but to play video. Than when video is to be closed you load scene.

    hotspots onclick:

    Code
    onclick="set(play_video_load_scene,true);set(load_scene_after_video_played,get(linkedscene));videoplay(get(name));"

    (made video played adaptation which load video of the same name as the hotspot name is adding appropriate extensions)

    Video player action videoplayer_close to be adapted:

    Code
    <action name="videoplayer_close">
    	.
    	.
    	.		
    	if(play_video_load_scene EQ true,after_play_load_scene(););		
    </action>

    and new action that will actualy load your scene after video played:

    Code
    <action name="after_play_load_scene">					
    	loadscene(get(load_scene_after_video_played),null,MERGE,BLEND(1)); 
    	delayedcall(0.2,set(play_video_load_scene,false));
    </action>

    Even after this very detailed guidelines if you are not Krpano experienced it could be not easy for you to make code adaptations in that way. Give it a try.

  • Thank you so much or laying out this code for me.

    As far as difficulty, it is what it is. Code is set in stone, and it'll be as hard as you want to make it, but this seems relatively simple.

    It'll be pretty easy to figure out where it goes, it just might take a bit.

    Having said that, this gets me very close to 100%, and is exactly what I was looking for. Again, I appreciate you taking the time to help me with this issue!!!

    Have a great week!

Jetzt mitmachen!

Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!