You are not logged in.

Dear visitor, welcome to krpano.com Forum. If this is your first visit here, please read the Help. It explains in detail how this page works. To use all features of this page, you should consider registering. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.

Red

Trainee

  • "Red" started this thread

Posts: 99

Location: Australia

Occupation: Virtual tour creator, VR app developer

  • Send private message

1

Sunday, May 1st 2016, 3:48am

Misalignment of images/text on first load

When clearing the browser cache and loading the tour, alignment of images and textfields can be out of place, usually higher or lower.
Once reloaded the textfield is aligned properly. Tested on desktop Chrome, Safari. Mobile Chrome and Safari also.
I understand this is some kind of issue to do with caching and the browser, but just wondering if there's anything that can be done krpano code side.
Cheers

Timescale

Trainee

Posts: 120

Location: Netherlands

Occupation: Archaeologist, Timescale R&D

  • Send private message

2

Sunday, May 1st 2016, 3:08pm

Q&D

If the problem resides on the KRpano side, you could try and call the updatescreen() function or even more extreme (i think) the updateobject(true,true) function on onloaded. If this corrects the problem, it means that somewhere some attribute,variable,thing is being cached that influences some setting after KRpano is finished setting up the object.

A quick and dirty method to check if the caching problem is to force the XML not to be cashed. There are several options to do something along these lines. By using meta in the HTML file to adding a random variable to the URL of the XML.

These should only be a temporary measures to check where the problem lies. But it seems to me that the anomaly could just as well be the second loading of the object, not the initial one.

Red

Trainee

  • "Red" started this thread

Posts: 99

Location: Australia

Occupation: Virtual tour creator, VR app developer

  • Send private message

3

Sunday, May 1st 2016, 5:16pm

Thanks for the suggestions to further isolate.

- Tried updatescreen() and updateobject(true,true) but seemed to have no impact.


-Also tried the cache blocking tips from Klaus here but no joy.
cachebuster



-On further testing, the misalignment appears to affect textfields only.
Image layers load with correct alignment but textfield layers don't.


-Made sure textfield plugin was updated
- A client has it happen with initial loads on their server also.


- The misalignment also happens on a previous tour using pr3 and the current one using pr4.


So stumped on this one. Thanks for any further help

4

Tuesday, May 3rd 2016, 8:37am

I know this bug and it seems to come back every now and then with a new krpano-release (or maybe it´s a browser-issue). For me the problem is the height of the textfield, which seems to not get calculated correctly the first time. My workaround is to set autosize to none and the height after the plugin is loaded....

autosize="none"
onloaded="set(height,30)"

Red

Trainee

  • "Red" started this thread

Posts: 99

Location: Australia

Occupation: Virtual tour creator, VR app developer

  • Send private message

5

Sunday, May 8th 2016, 4:38pm

Hey Nupsi,

Thanks for the info and possible workaround. Unfortunately it didn't work for me.
My issue seems to be the y cordinate. Tried the same code with y instead of height but still nothing.

Cheers