Beiträge von florian_mrt

    ...I think I found a completely new, simpler solution !

    I do want people's opinion on this? It looks a bit like hacking, but both flash and html5 seem to work with this.

    The Xml pano test-highresframe2.xml :


    The skin skin-highresframe2.xml :


    In short, right where it adds the txt url to highresframedyna var, within the highres_load action, that is what makes the highres loading dynamic. This could be a different url upon next call, or the use of %1 could be made.

    Is this a normal usage of the player?

    Ok, so further from my example above.

    As one can see, there are two scenes: scene-video and scene-highresframeimage.

    Switching between the two works, without the video reloading. This is very nice so far.

    I now need to make the image.sphere.url load an on-demand frame image. The image url is provided externally, via the webpage JS.

    From a previous thread, the action script call:

    Code
    <action name="ui_loadhighres">
    set(ui_vars_file_highresframe, %1);
    txtadd(highresframedyna, 'image.sphere.url=', get(ui_vars_file_highresframe));
    loadpanoscene(null, scene-highresframeimage, get(highresframedyna), KEEPALL, BLEND(1));
    </action>

    ...Gives me some positive result: the highres scene is properly loaded, and the UI skin is also kept (because of the KEEPALL flag). The video plugin is also kept, because when I press play, the video plays in the background (I can hear the sound, but no image).

    But the video image is not shown, and an error now shows:

    ERROR: loadscene() - scene "scenevideo" not found

    ..Which indicates to me that the scenes have all been removed, despite the KEEPALL flag??

    I do know that Klaus repeatedly said that dynamic loading is not possible. Is it _really_ not possible? Im this close !

    My problem here was:
    - How to keep the UI intact (eg. when highres frames are loaded, the UI doesnt change)
    - How to keep the UI visible even during a scene change between video and highres frame
    - What ideal structure is needed for video and highres frames
    - How to switch between these two scenes

    The following seems to come very close to what I want, and I will share it here, so others may find this useful.

    It creates two scenes. Initially, it loads one of them. Note that the video plugin is keep=true when switching between scenes.

    The skin file contains the play/pause button (you may have to create your own button and apply the correct crop accross the files: skin-highresframe.xml.

    Note that when we switch scenes, the KEEPALL and BLEND have an effect on how to smoothly display everything.

    These examples have worked for both flash and html5, though are a bit basic. You may have to change UI according to your needs.

    I hope this will help someone.

    Hello Klaus,

    This works and meets my intention, but only in Html5 mode ! Your alert is not displayed when using Flash.

    Also, it does not allow multiple listening functions, eg:

    Code
    krpano.set("events.my_custom_event_when_something_is_done", function()
    {
      alert("FIRST something was done inside the krpano player !");
    });
    krpano.set("events.my_custom_event_when_something_is_done", function()
    {
      alert("SECOND something was done inside the krpano player !");
    });

    ...only the SECOND alert will display (although adding multiple listening functions could be extended with some code).

    Also, I dont see how custom data could be passed during the event dispatch (although this could also be extended with some krpano.call() code during the event listening functions).

    But the flash limitation blocks the use of this feature? How to get this working in flash mode?

    Thank you !

    I would like to do something like:

    $(krpano).on("my-custom-event-when-something-is-done", function(event) {
    alert("something was done inside the krpano player !");
    });

    ...and inside the krpano xml, have something somewhere

    events.trigger("my-custom-event-when-something-is-done");

    ...and even better with custom data.

    In otherwords, I want to trigger a custom event inside the player, which will be received/listened to outside the krpano xml.

    This would be useful if a specific button/hotspot was clicked inside the krpano player, but there were multiple instances of the krpano player running (and hence you cant just use the js() function to invoke something in the global scope of the document).

    Without much viewing in detail, it seems possible to:
    - put the video plugin and image sphere in one scene
    - put an image sphere in a second scene
    - put a hotspot in each scene to loadscene() the other scene (like a button to go back and forth)
    - put a loadscene() call in the krpano root onstart attribute to load the first scene
    - put a keep="true" attribute in plugin, image and sphere

    When playing the video, the video keeps on playing even when switching between the scenes..! This indicates that it should be possible somehow?

    I do like the proposed solution of blending using tiled hotspots ! Exactly spoton what I want, but unfortunately the hotspots are cube tiles, not a single spherical image, which is what all my highres video frames are.

    Some more suggestions/alternatives from others are welcome !

    Is it possible to call dispatch events to the webpage, from within the krpano xml file?

    I am looking to dispatch eg. en event on the krpano object (that has been provided from embedpano/onready), with custom data, from within the loaded xml data.

    The alternative currently working method, is to use js() within xml and use an event dispatcher proxy object on a global scope variable. This is not ideal, and gets complicated if an unknown number of krpano players are set.

    Is it possible to dispatch events directly on the krpano object from within the krpano xml file?

    Hi, you could store the current video time, load a new scene with the high res frame and when going back load the video scene and seek it to the stored time.

    That is exactly what I DONT want to do. When someone presses the pause button, it is acceptable and expected that loading the frame takes some time. But when resuming to play the video, it is expected that the video is already loaded, already seeked to the paused time, and playing should be instantly. Unloading and reloading a scene would remove the video being played, requireing a seek, and a delay resulting in the user experience being downgraded from my current setup.

    I have krPano setup that plays 360 videos, who generally are lowres to allow for bandwidth over Mobile.

    I also have frames every 5secs at very highres.

    I now want to change my krPano player, that every time the player pauses, a loading bar is displayed, the nearest highres frame is loaded, and when loaded, displayed. Whenever the play butten is played again, the krPano switches immediately back to the video (and removes the highres frame from memory), and plays the video again.

    I looked at the stereoscopic krpano example, and using external events, a front video player CSS is made invisible, to reveal another krpano instance in the back which is loading the highres frames. This however is great to immediately get the video to play again when the play button is pressed. But Two krpano instances take up more memory and cpu usage, and I now want to reduce this to one player only.

    Is there an example out there that did this before? Has anyone done this? Can someone shed some pointers/hints on doing this?

    Hello all,

    This seems like a trivial matter, but it is bugging me now several workdays, and I just cant figure it out ! Am I overlooking something? I need a third person to look at my issue...

    This is because my client is hosting the player on a cloud server, and the media files are hosted on a CDN.

    I have the following basic XML doc:

    This is hosted from a html page linking to the krpano.js. The krpano loads fine, and the http://localhost/image21.JPG image displays fine in it.

    When I change to the remote url http://someone.blob.core.windows.net/project/00/Fro…ent/image21.JPG (url changed due to IP, but you can use any external image), I just cant get the image to load. The image also has a HTTPS variant; both are not working in the player.

    However, when pasting the url directly in the browser, there are no problems viewing all of the images.

    Im aware that the crossdomain.xml needs to be present for the flash version to work, but this is tested with html5 set to 'always' and I can clearly see the canvas element in dom-developer mode.

    Am I missing something? Does the player load external images? Can someone give me some additional hints/pointers/suggestions?

    Just to respond and close my own question related to this, in the hope it will help others. https://krpano.com/forum/wbb/inde…71658#post71658

    I use Javascript on my hotspots, so I did:

    Code
    objKrPano.call("set(hotspot["+strID+"-click].url,"+strImageOutUrl+"); "+ //projects/Factory/Content/Texture/360 Still Click.png); "+
    				"set(hotspot["+strID+"-click].renderer, css3d); "+
    				"set(hotspot["+strID+"-click].ath,"+fltAngle+"); "+ //45); "+
    				"set(hotspot["+strID+"-click].atv,"+fltPitch+"); "+
    				"set(hotspot["+strID+"-click].scale,"+fltScale+"); ");

    Note:

    1. You must apply css3d on the IMAGE hotspots, not the POLYLINE hotspots. Though I applied it on both.
    2. Zorder or creation order will matter.

    Worked beautifully ! Thank you for the advice.

    Hi all!

    I am trying to add a hotspot PNG image IN FRONT OF a hotspot-polyline.

    Is this possible?

    I have been trying changing Z-Order, changing the creation order, etc... but to no avail !

    Investigating this a bit further, it seems that polylines are SVG rendereings ON TOP OF the krpano player. Is this why I can't change placing the hotspot polylines behind a hotspot image?

    My JS code for reference:

    Florian

    Ok, got it.

    A further question here about my code above. I can see that, for the flash version, there is already a loading bar displaying when the scene changes. I would like to remove it (and place it with my own styled loading bar). OR, I would like to know when the built-in loading bar is displaying, so that I dont display mine.

    How can I do that?

    Hello all,

    I am trying to implement a loading bar for single spherical images. These images tend to be large (+-3MB), so downloading on a phone would take some time. I can show a spinner, to indicate that 'something' is downloading or busy, but it would be perfect if there was a progression bar showing 'how much' has already been downloaded.

    In my research, I found out that the flash version of krPano shows a progressive download bar, whereas the HTML does not. See the difference in both examples, and the smoother progression for the flash version (the html version seems to only count howmany cubical sides have been downloaded):

    https://krpano.com/examples/117/e…ml?html5=prefer

    https://krpano.com/examples/117/e…tml?html5=never

    (notice the html5 parameter in the url)

    Has anyone else got a better progression loading bar for html5?

    My code so far (which should be used as an include, eg: <include url="%SWFPATH%/include-loading.xml" /> ):

    Hello all,

    I have setup a XML file with two scenes, and the switching is fine now.

    I need to determine which frame number I am currently at from the Video plugin. How do I do that?

    I can find out the time (plugin[video].time), but I see nowhere a current frame number that I can use. I also thought of perhaps dividing the time by FPS of the Video, but I cant find the framerate attribute, if there is any? Am I missing something?

    Anyone ?

    Florian

    Hello all,

    My current krPano plays spherical videos using the Video plugin, without any problem.

    I also have a folder with images, each representing one of the frames inside the spherical video. These images are very large (4K+ width).

    The idea now is to play the video in krPano (no problems currently), and whenever the user pauses the video, a loading bar appears that is loading the spherical image corresponding to the current frame of the video. When the image is loaded, krPano should tween to the loaded highres image. It tweens back to the video whenever the play button is pressed.

    This way, the video can display a low-res video even on small/slow devices, but still display a high-res image for closer zoom inspection.

    I am a bit stuck at how to best implement this. Do I use two scenes (the video scene and a single frame scene and krPano switches between the scenes), do I use no scenes and just use image elements to display/hide?

    Is there an example somewhere that is already implementing this idea?

    Thank you so much,

    Florian

    Dear Klaus,

    Thanks, this info and example will help tremendously ! I can solve my project onwards using this information.

    In my project's specific case, the client had the entire project in
    flash, and now wants to fully steer towards html5+WebGl, for support of
    other devices without flash. Again, I am aware that cubical panos are better performance etc for multires panos. However, is it planned that support for multires spherical panos will be ported to Html/WebGl in the future?

    What is the technical limiting feature, out of curiosity (if there is any)?

    Thank you

    Florian Mertens