Sie sind nicht angemeldet.

Lieber Besucher, herzlich willkommen bei: krpano.com Forum. Falls dies Ihr erster Besuch auf dieser Seite ist, lesen Sie sich bitte die Hilfe durch. Dort wird Ihnen die Bedienung dieser Seite näher erläutert. Darüber hinaus sollten Sie sich registrieren, um alle Funktionen dieser Seite nutzen zu können. Benutzen Sie das Registrierungsformular, um sich zu registrieren oder informieren Sie sich ausführlich über den Registrierungsvorgang. Falls Sie sich bereits zu einem früheren Zeitpunkt registriert haben, können Sie sich hier anmelden.

Birdseye

Schüler

  • »Birdseye« ist der Autor dieses Themas

Beiträge: 125

Wohnort: De Haan

Beruf: Freelance Photographer

  • Nachricht senden

1

Freitag, 9. März 2012, 13:34

Gyro trouble

Since I don't have an Ipad 2 or Iphone4, it's difficult for me to find a solution. A client is complaining that, when he use the gyro, everything goes fine, but when he turns of gyro, uses the pano by hand and then reenables the gyro, oriention is completely lost. Does anyone knows a solution? This is the code...
Thanks for help,
Yvan.


Quellcode

1
2
3
		<plugin name="gyro" url="gyro.js" enabled="true" camroll="true" friction="0.5" velastic="0.2" devices="html5" keep="true"		onloaded="delayedcall(1,if(available, set(plugin[gyro-button].visible,true);));"		/>				<plugin name="gyro-button" url="gyro.js" enabled="true" camroll="true" friction="0.5" velastic="0.2" devices="html5" keep="true"			visible="false"		/>
		<action name="activateGyro" devices="iphone|tablet|mobile|android">			moveto(0,0);			delayedcall(1,set(plugin[gyro-button].enabled, true));			delayedcall(1,set(plugin[gyro].enabled, true));			set(plugin[btn_gyroOn].visible,true);			set(plugin[btn_gyroOff].visible,false);		</action>
		<action name="deActivateGyro" devices="iphone|tablet|mobile|android">			set(plugin[gyro-button].enabled, false);			set(plugin[gyro].enabled, false);			set(plugin[btn_gyroOn].visible,false);			set(plugin[btn_gyroOff].visible,true);		</action>
</plugin></plugin>

Dieser Beitrag wurde bereits 2 mal editiert, zuletzt von »Birdseye« (9. März 2012, 17:19)


Tuur

Erleuchteter

Beiträge: 3 839

Wohnort: Netherlands

Beruf: Krpano custom coding / Virtual Tours / Photography / Musician / Recording engineer

  • Nachricht senden

2

Freitag, 9. März 2012, 15:42

maybe take that moveto 0,0 out?!

Hope it helps!

i use:

Quellcode

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
<plugin name="gyroscope" 
        url="../skin/gyro.js" 
        keep="true"
        enabled="true"
        camroll="false"
        friction="0.5"
        velastic="0"
/>



<plugin name="gyro" 
        url="../skin/buttons/btn_gyro.png"  
        visible="false" 
        zorder="100"  
        keep="true" 
        scale="2"  
        align="rightbottom" 
        x="-10" 
        y="240"  
        ondown="switch(plugin[gyroscope].enabled);" 
/>


Tuur *thumbsup*

Ps Please try to publish your code in an vertical way. This is almost unreadable in the forum.

Birdseye

Schüler

  • »Birdseye« ist der Autor dieses Themas

Beiträge: 125

Wohnort: De Haan

Beruf: Freelance Photographer

  • Nachricht senden

3

Freitag, 9. März 2012, 17:15

Thank you for the help Tuur.
The move to 0,0 was a tryout to recalibrate the 360. But obviously it didn't work.

Sorry about the horizontal code :( each time I paste the vertical code, it automaticly positions horizontal.

4

Freitag, 9. März 2012, 20:41

I think this is what you are wanting. The camroll option listed here when you disable the gyro.

Info text box not showing in iPhone/iPad

Edit: set(view.camroll,0.0);

I found that you could get stuck with the angle you were holding the phone if you simply turned off the gyro. I added that in and it seemed to fix the problem although using the set made it "jump" to straighten out. I would assume a tween would be more gentle but I have not tested it that way. I don't use the gyro and posted that code to help someone else.

Dieser Beitrag wurde bereits 1 mal editiert, zuletzt von »Jarredja« (12. März 2012, 12:06)


5

Montag, 12. März 2012, 10:13

Hi,

when disabling the gyro also do:

Quellcode

1
tween(view.camroll,0);

then the camroll will animate smoothly back to start,

best regards,
Klaus

Birdseye

Schüler

  • »Birdseye« ist der Autor dieses Themas

Beiträge: 125

Wohnort: De Haan

Beruf: Freelance Photographer

  • Nachricht senden

6

Mittwoch, 14. März 2012, 06:24

Thank you for all the help.

Tuur

Erleuchteter

Beiträge: 3 839

Wohnort: Netherlands

Beruf: Krpano custom coding / Virtual Tours / Photography / Musician / Recording engineer

  • Nachricht senden

7

Samstag, 9. Juni 2012, 12:39

Hi,

is there a way to get the percentage or even better amount of degrees of the camroll?

i like to show that aswell in my krpano 'Tool' ;)

http://virtualtuur.com/krpano/compass/

i also find that the compass direction is changing when you change the device diagonaly,, so when camroll kicks in..
is there some math involved? so that it keeps north when you 'camroll' your device??

I also find that when i go from level to compas or vise versa i have to touch the screen before it 'resets'...
Is there a solution?

And it's a bit stuttering sometimes.. what could that be??
Tuur *thumbsup*

Dieser Beitrag wurde bereits 3 mal editiert, zuletzt von »Tuur« (11. Juni 2012, 10:42)


8

Dienstag, 28. August 2012, 05:19

Biggest problem I see with the air compass, it's all you want to look at. Forget the tour.
Bill



http://astimegoesby.us Personal family history back to the 1800's

9

Dienstag, 16. Oktober 2012, 16:27

I need the loading/starting pano to look north if I point the iPhone/iPad in north-direction. same for any other direction.
is there any way gyro.js can manage that?

Tuur

Erleuchteter

Beiträge: 3 839

Wohnort: Netherlands

Beruf: Krpano custom coding / Virtual Tours / Photography / Musician / Recording engineer

  • Nachricht senden

Ähnliche Themen