Window Compass

Post Reply
User avatar
Hopki
Gnome
Posts: 9646
Joined: Thu Jan 10, 2008 3:16 pm
Location: Layer de la Haye, Essex UK
Contact:

Window Compass

Post by Hopki » Mon Jan 21, 2013 7:27 pm

Hi,
Before version 4 this was a not easy, but now so easy thanks to being able to select North and the new modifier Pan North.

compass project_out.swf [ 242.12 KiB | Viewed 5785 times ]

The project works in both the Flash and HTML5 outputs. It looks as if the window compass elements and panorama move out of synchronisation but its just following the 3D distortion of the panorama. To show this there is also a pointer, so when facing N, S, E or W the correct window compass rectangle will be showing at the top of the screen.

How it works:
Each panorama needs its North set in either the User Data or Viewing Parameters.
To keep the math simple I am using a skin window size of 800 x 600, the width being the most important here.
The compass elements are 80px wide, each has a position X/Y of 0/5 and need to be anchored top centre.

The magic is in the Actions Modifiers tab, under Modifiers for each rectangle.
Example from North:
Move X => Pan North => Factor: 10.000 => Offset: 360

North will be centre of the skins window so thats where the 360 comes from, X = 360 puts the north rectangle exactly in the middle of the skin editors window.
For the other elements the offset math is this:

Math summery:

360 = North
360 + 900 = 1260, East
360 + 1800 = 2160, South1

360 - 900 = -540, West
360 - 1800 = -1440, South2.

Why do I have two South's ?
The way the skin works, elements can only be seen going CW (clock wise) from 0 to 180. Past this the you need to use negative numbers.
So 0 to 180 and then 0 to -180.

As this is using the Pan North modifier as you go to different nodes as long as they have North set it will always point in the right direction.

You can add more elements, so to have NE the offset would be 810, for SE the offset would be 1710. Thats using the skin window width of 800 and the rectangles being 80px wide. Please see this skin for a working example:
compass2.ggsk.zip
(1.21 KiB) Downloaded 291 times
If you skin window size is 1024 with compass rectangles of 80px then the offset for North would be 492 and all other calculations start from this number.
Regards,
Hopki
Attachments
Pano2vr Pro window_compass.zip
(586.85 KiB) Downloaded 382 times
Pano2VR window_compass.zip
(923.88 KiB) Downloaded 353 times

User avatar
soulbrother
Posts: 369
Joined: Tue Apr 08, 2008 7:01 pm
Location: München
Contact:

Re: Window Compass

Post by soulbrother » Fri Feb 15, 2013 3:38 pm

Hi Martin
and thanks for your wonderful tips and support !

Just 2 questions to that compass theme:

1. Is it possible to create a setup (special container?) to show and hide this compass, without disturbing that compass function ??

2. Is there any way to "print" this graphics in an output (via "convert input" or any other method) ??
->Reason: to have a panorama for printig and showing the directions on top of the equi-printing, or, so to say, to save the time in photoshop to create it and to adjust the compass-lines...
Last edited by soulbrother on Fri Feb 15, 2013 4:02 pm, edited 1 time in total.

User avatar
Hopki
Gnome
Posts: 9646
Joined: Thu Jan 10, 2008 3:16 pm
Location: Layer de la Haye, Essex UK
Contact:

Re: Window Compass

Post by Hopki » Fri Feb 15, 2013 3:50 pm

Hi,
If you added comp_ to the ID's
Example:

Code: Select all

comp_north_bg
comp_east_bg
comp_south1_bg
Then you can use a regular expression to hide the lot in one click:

Code: Select all

Mouse Click => Toggle Visibility => Target: #comp_.*
Regards,
Hopki

User avatar
soulbrother
Posts: 369
Joined: Tue Apr 08, 2008 7:01 pm
Location: München
Contact:

Re: Window Compass

Post by soulbrother » Fri Feb 15, 2013 4:04 pm

wow, you´re fast today ;-))

thanks, I will try it,

I added a second question (above)
thanks again !!

User avatar
Hopki
Gnome
Posts: 9646
Joined: Thu Jan 10, 2008 3:16 pm
Location: Layer de la Haye, Essex UK
Contact:

Re: Window Compass

Post by Hopki » Fri Feb 15, 2013 4:11 pm

HI,
Sorry no, the transformations does not include any skin elements.
When not use fullscreen template and do a screen print?
Regards,
Hopki

User avatar
soulbrother
Posts: 369
Joined: Tue Apr 08, 2008 7:01 pm
Location: München
Contact:

Re: Window Compass

Post by soulbrother » Fri Feb 15, 2013 4:47 pm

Hopki wrote:HI,
Sorry no, the transformations does not include any skin elements.
When not use fullscreen template and do a screen print?
Regards,
Hopki
OK, just good to know...

...the prints will be 360cm, so no way to do a screenshot ;-)
... but of course I can handle in PS...

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest