Hi, I don't understand why but hotspots are much too big in VR on mobile compared to Oculus Go on which they are perfectly scaled.
I think I remember a wordscale setting for WebVR which seems to have disappeared ?
Anyway, depth is really different on Oculus and mobile and I don't understand why, or maybe it's a setting on my phone ?
VR scale on mobile
-
-
Strange thing is that vr_cursor is correctly sized ?
And on mobile in VR hit area is larger than text hotpots...
Just did a test with same scene but with Krpano 1.19pr16 and scale is correct on both Oculus and Mobile, so seems to be a bug with 1.20 or webxr maybe ?
Example : https://360images.fr/barebone_vrscale119/ -
Hi,
that's a bad combination of several things:
- Without zoom=true or distorted=true the size of a hotspot depends on the screen-resolution in 'viewport' pixels (e.g. an iPhone 10 has 375x812 viewport pixels).
- This applies also to hotspots MobileVR mode (=browsers/mobiles without WebVR/WebXR API).
- Because as un-distorted screen-based hotspots are looking and working very bad in VR (they seem to rotate because the screen is flat and the VR not), krpano offers a special hotspot rendering mode for such flat hotspots in VR, which is enabled by default - please see here:
https://krpano.com/docu/xml/#display.hotspotvrrendering - With that hotspot VR rendering mode, the hotspot get rendered as distorted hotspot (and so they get also the depth setting, which wouldn't apply to non-zoomed hotspot), but the hotspots still keep their size relative to the screen-size.
Solutions:- Don't use screen-based hotspots (that means without zoom=true or distorted=true) for VR.
- Additionally - I'm already considering always using a fixed 'base'-screen-resolution (e.g. 2000x1000) for MobileVR mode to be independent of the real screen-size.
ZitatAnd on mobile in VR hit area is larger than text hotpots...
No, that just seems so because of the stereo-rendering, compare the left and right eyes, the hit-testing itself is done in 'mono', in a VR headset it will look correct.
Best regards,
Klaus -
Ok, thx Klaus for that fast reply !
What I don't get is why scale is correct with 1.19pr16 and not with 1.20.x ? -
Hi,
before 1.20 the mobile-vr mode was completely(!) different and using the view-fisheye-lens distortion for the 'VR lens' distortion. This was inaccurate and had a lot other problems because the that kind distortion couldn't be applied to all required rendering cases, especially when using free 3d-placed hotspots.
Now the mobile-vr rendering works the same as the real WebVR/WebXR mode by rendering first to a framebuffer and then applying the VR-lens distortion. The only remaining problem in this case is that the non-distorted/non-zoomed hotspots are still based on the actual screen/window-size and the rendering itself is based a physical-based screen size (the device screen size set or detect in MobileVR mode).
With the next krpano release this problem should be fixed automatically.
Best regards,
Klaus -
Ok I got it, thx for the explanations Klaus.
Trying to find a workaround as I don't want hotspots to be distorted or zoom enabled in non-vr mode I tried
zoom="calc:webvr.isenabled == true ? true : false"
and
zoom="calc:webvr.isenabled ? true : false"with no success, is my syntax wrong ?
-
The 'calc:' in attributes works only once during xml parsing.
Here a workaround:
Code
Alles anzeigen<events name="fix_vr_hotspots" keep="true" webvr_onentervr="fix_vr_hotspots(true);" webvr_onexitvr="fix_vr_hotspots(false);" /> <action name="fix_vr_hotspots" scope="local" args="mode"> for(set(i,0), i LT hotspot.count, inc(i), copy(hs, hotspot[get(i)]); if(mode == true, copy(hs.backupzoom, hs.zoom); set(hs.zoom, true); , copy(hs.zoom, hs.backupzoom); ); ); </action>
-
Hi,
there is now a new 1.20.9 build where this is fixed:
krpano 1.20.9 - New MAKE VTOUR Droplet, Panotype-Editor, Leveling, Chroma-Key/Transparent-Videos, Updates for macOS Big Sur and iOS 14Best regards,
Klaus
Jetzt mitmachen!
Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!