Beiträge von inframatic

    I have an 360 image which I want to control through click/touch and drag on the desktop. Note that moving the camera works with the 4 arrow keys.

    When I try to click and drag, the cursor image does not change like it should in https://krpano.com/examples/119/k…-corfu/tour.xml

    Why can't I click/touch and drag the 3d image?
    Is there an option I could have turned off? I've looked through the docs but cant find anything!

    <scene name="image_scene" title="imagescene" onstart="plugin[video].stop();" >
    <include url="skin/vtourskin.xml" />
    <include url="skin/loadinganimation.xml" />
    <include url="skin/loadingpercenttext.xml" />
    <include url="skin/loadingbar.xml" />
    <view hlookat="0" />
    <image>
    <cube url="/panorama/%$panoId%/pano_%s.jpg" />
    <cube url="/panorama/%$panoId%/mobile_%s.jpg" devices="iOS" />
    </image>
    </scene>


    <control mouse="drag"
    touch="drag"
    dragrelative="true"
    draginertia="0.1"
    dragfriction="0.9"
    movetorelative="true"
    movetoaccelerate="1.0"
    movetospeed="10.0"
    movetofriction="0.8"
    keybaccelerate="0.5"
    keybspeed="10.0"
    keybfriction="0.9"
    keybfovchange="0.75"
    mousefovchange="1.0"
    fovspeed="3.0"
    fovfriction="0.9"
    zoomtocursor="false"
    zoomoutcursor="true"
    touchzoom="true"
    bouncinglimits="false"
    />

    When I play the video, the video interface always says I'm at 0:00 in the video.

    Note that when I directly change the time in the video to say 1:11, the video interface works again.

    Is there anyway to reset the video reader so it can always tell where I am at in the video?

    I am also not having the user play the video using the interface. The first time the user hits play is with a different button using
    [size=10]

    Code
    changepano( loadscene(video_scene, null, MERGE|KEEPVIEW|KEEPMOVING, BLEND(1)););		plugin[video].play();

    You fixed the problem and optimised my code!

    The actual error was immediately fixed when i added plugin[video].playvideo() instead of playvideo.
    I am baffled as to how this worked for so long before but then suddenly stopped working.

    Why do you set the plugin's enabled to equal false? Doesn't the plugin basically not do anything if I'm on a different scene?


    The ChangeVideoScene() and startup() shortened my code by a good chunk since I was repeating this hotspot example above in a number of places.


    Thanks again!


    Ian Steffy *tongue*

    Guten Morgen,

    I am receiving the error 'WARNING: unknown action: playvideo' on mobile devices only. The desktop plays the video just fine.

    The weirdest part about this error is that even when I revert to previous saves where I know 'playvideo' worked, I still receive the error. In fact, this was working yesterday morning when I finished coding and it only began to not work later that night when no code was changed on my end.

    the playvideo action is described here: https://krpano.com/plugins/videoplayer/#playvideo


    and here is where I call it, where the error is thrown.

    <hotspot name="featured_panorama"
    distorted="true"
    url="http://beta.vr.meventi.de/panorama/78/featured_thumb.png"
    ty="375" tx="-860"
    rx="0.0" ry="-15.0" rz="0.0"
    scale="1.08"
    depth="1300"
    onover="tween(depth,1260);" onout="tween(depth,1300);"
    onclick="changepano( loadscene(video_scene, null, MERGE|KEEPVIEW|KEEPMOVING, BLEND(1)); ); ifnot(device.ios, set(plugin[video].videourl, /panorama/78/video-1920x960.mp4); , set(plugin[video].videourl, /panorama/78/video-1344x672.mp4|/panorama/78/video-iphone-sound.mp3);); ifnot(device.ios, plugin[video].playvideo(/panorama/78/video-1920x960.mp4); , playvideo(/panorama/78/video-1344x672.mp4|/panorama/78/video-iphone-sound.mp3);); plugin[video].play(); hide_all_videos();"
    />


    <plugin name="video" keep="true"
    url.flash="%SWFPATH%/plugins/videoplayer.swf"
    url.html5="%SWFPATH%/plugins/videoplayer.js"
    videourl.no-ios="/panorama/%$panoId%/video-1920x960.mp4|/panorama/%$panoId%/video-1920x960.webm"
    videourl.ios="/panorama/%$panoId%/video-1344x672.mp4|/panorama/%$panoId%/video-iphone-sound.mp3"
    loop="true"
    pausedonstart="true"
    visible="false"
    use_as_videopano="true"
    />

    Note that plugin[video].play(); does work on mobile devices


    *smile* Ian,

    Using 1.19 pr3

    Perhaps I've found a bug for Klaus.

    Dynamically generated hotspots have their alpha set from 1 to 0 every time the scene is changed.

    So right now, krpan does this:

    (starting scene)
    Scene A: Hotspots alpha=1
    (switch to next scene)
    Scene B:Hotspots alpha=0
    (switch back to first scene)
    Scene A: Hotspots alpha=0


    Klaus should make the following changes in my opinion:


    'keep' is not a bool but can be set to specific scenes or all scenes like keep="scene1" or keep="all"
    I don't think it's best to assume that someone wants to either keep a hotspot in all scenes or completely destroy the hotspot.


    Second, it needs to be added to the docs that dynamically generated hotspots need their 'keep' and 'alpha' set but static hotspots do not. Right now, I don't see anywhere that says that the alpha will be set to 0 when the scene is changed.


    Best,
    Ian *g*
    1.19 Pr 3

    'keep' does not work because while it keeps the selectable hotspots on the screen, the hotspots are invisible. Also the hotspots stay on the screen even when the scene is changed to a scene where they don't belong to.

    This is what I want:

    Scene A: Hotspots are visible and can be interacted with
    (switch to next scene)
    Scene B: Hotspots are invisible and can not be interacted with
    (switch back to first scene)
    Scene A: Hotspots are visible and can be interacted with


    Here's what the hotspots look like on Scene A:

    <hotspot name="name1"

    distorted="true"
    keep="true"
    visible="true"
    url="thumbnail.png"
    tx="400"
    tz="0"
    ty="400"
    ry="10"
    depth="1000"
    />

    Servos,
    I generated a list of hotspots using a javascript function which is loaded into onready in embedpano({}), but they are deleted when I try to return to the scene with the hotspots.

    The loadpano function is loadpano(get(startupxml), null, NOPREVIEW|MERGE|KEEPVIEW|KEEPMOVING, BLEND(1)); and it was created by Klaus, i believe, for 1.19 pr3


    So how can I make these generated hotspots return? Should I recall that function again to generate those hotspots and if, yes, then how do I do this?


    Servos,
    Ian Steffy

    Servus,

    I am trying to find any coordinates for hotspot[vr_cursor] , which is the cross-hairs you see in the center of the screen when you 'Enter VR'.

    I want to create an action that takes these coordinates and creates a hotspot to the right of where I'm currently looking, which is why I need coordinates like atv,ath,ty,tz and no angle degrees like view.hlookat and view.vlookat will give.

    Vielen Dank,

    Ian *g*


    Hi,

    in the MobileVR (Cardboard) mode or in the fake-mode it's anytime possible to change the stereo rendering by changing the display.stereo setting,

    but when using the real WebVR API (for the Oculus Rift and HTC Vive) this is not possible of course.

    Best regards,
    Klaus

    Du hast Recht!

    I created a simple action that said something like this and it worked:

    if (detectsGyroscope == false || isMobile == false ) {
    set(display.stereo,false)
    }

    I am having the same issue with totaltime. It would really be helpful to find an answer. I'm still keeping an eye out :)

    Found something! how to get information on video player. SEE BELOW

    ----
    Hi,

    Zitat


    Quoted

    1. how to get the video current time and total time? i don't want to use xml.

    krpano.get("any variables for times")?

    e.g. via:


    Source code
    1
    2

    krpano.get("plugin[NAME].time");
    krpano.get("plugin[NAME].totaltime");

    where NAME is the name of the plugin element inside the xml.


    Zitat


    Quoted

    2. how to get the plugin class on JS ? i tried a lot of ways... but i couldn't any ways...
    because i want to know event that video play,stop,buffer,play end, play start....

    The HTML5 videoplayer plugin exposes the internal <video> DOM element via:


    Source code
    1

    krpano.get("plugin[NAME]").videoDOM

    but when changing the video state directly via that object, the krpano states might not match. Also note - when playing a new video that object might change too.

    To avoid cross-browsers problems, I would recommend using the krpano videoplayer APIs.

    Best regards,
    Klaus


    Device attribute settings are NOT for dynamic code like that. They are used at the start via xml parsing.

    use ifnot(device.ios, set(plugin[video].videourl instead of set(plugin[video].videourl.no-ios,

    A bit silly that i cant set the attribute by videourl.no-ios and must instead use only videourl, but this works partially so thanks.

    One problem is that this solution DOESNT work with the sound mp3 files that is needed to play video sound on ios


    <action name="playtest3">
    ifnot(device.ios, set(plugin[video].videourl, /panorama/77/video-1920x960.mp4); ,
    set(plugin[video].videourl, /panorama/77/video-1344x672.mp4|/panorama/77/video-iphone-sound.mp3););
    ifnot(device.ios, plugin[video].playvideo(/panorama/77/video-1920x960.mp4);, playvideo(/panorama/77/video-1344x672.mp4|/panorama/77/video-iphone-sound.mp3););
    plugin[video].play();
    </action>

    video-1344x672 for ios is being called but video-iphone-sound.mp3 is NOT *confused*