Flipping Grids (Celestia SVN)

All about writing scripts for Celestia in Lua and the .cel system
Avatar
Topic author
t00fri
Developer
Posts: 8772
Joined: 29.03.2002
Age: 22
With us: 22 years 10 months
Location: Hamburg, Germany

Flipping Grids (Celestia SVN)

Post #1by t00fri » 04.06.2008, 17:05

Hi all,

now that the SVN version enjoys all these nice new grids, one drawback for now is that only the QT4 GUI supports easy menu-supported flipping between the various new grids.

Here are 3 simple celx scripts that allow playing with the different grids in ANY Celestia GUI.

  • galacticgrid.celx
  • eclipticgrid.celx
  • horizontalgrid.celx

Just unpack this archive
http://www.celestiaproject.net/~t00fri/images/ ... p_celx.zip
in your scripts directory.

The default equatorial grid can be switched on|off with the ';' key as usual.

Moreover, executing galacticgrid.celx, inverts the rendering status of the galactic grid, while switching off any other grid (except the equatorial one). If the galactic grid was off before, it will now be on, and vice versa.

Analogously, eclipticgrid.celx inverts the rendering status of the ecliptic grid, while switching off any other grid (except the equatorial one).

Finally, horizontalgrid.celx, inverts the rendering status of the horizontal grid, while switching off any other grid (except the equatorial one).

Enjoy,
Fridger
Last edited by t00fri on 04.06.2008, 19:41, edited 2 times in total.
Image

chris
Site Admin
Posts: 4211
Joined: 28.01.2002
With us: 23 years
Location: Seattle, Washington, USA

Re: Flipping Grids (Celestia SVN)

Post #2by chris » 04.06.2008, 17:10

t00fri wrote:Hi all,

now that the SVN version enjoys all these nice new grids, one drawback for now is that only the QT4 GUI supports easy menue-supported flipping between the various new grids.

Here are 3 simple celx scripts that allow playing with the different grids in ANY celestia GUI.

  • galacticgrid.celx
  • eclipticgrid.celx
  • horizontalgrid.celx

Just unpack this archive
http://www.celestiaproject.net/~t00fri/images/ ... p_celx.zip
in your scripts directory.

The default equatorial grid can be switched on|off with the ';' key as usual.

Moreover, executing galacticgrid.celx, inverts the rendering status of the galactic grid, while switching off any other grid (except the equatorial one). If the galactic grid was off before, it will now be on, and vice versa.

Analogously, eclipticgrid.celx inverts the rendering status of the ecliptic grid, while switching off any other grid (except the equatorial one).

Finally, horizontalgrid.celx, inverts the rendering status of the horizontal grid, while switching off any other grid (except the equatorial one).

Thank you for making these scripts available. I like the automatic disabling of other grids--do you think this is how the UI should work? It seems rare that you'd more than one grid at a time.

--Chris

Avatar
Topic author
t00fri
Developer
Posts: 8772
Joined: 29.03.2002
Age: 22
With us: 22 years 10 months
Location: Hamburg, Germany

Re: Flipping Grids (Celestia SVN)

Post #3by t00fri » 04.06.2008, 17:22

chris wrote:...
Thank you for making these scripts available. I like the automatic disabling of other grids--do you think this is how the UI should work? It seems rare that you'd more than one grid at a time.

--Chris

Well, naturally, I spent some thoughts on that question. Most of the time the present "exclusive" logics should be sufficient, but...who really knows. ;-)

There may e.g. be some educational motivation for displaying more than one grid at a time. Also for people experimenting with frame transformations it may be quite useful to see more than one grid at a time.

Therefore, the present individual on|off logics in the QT4 GUI is certainly the more versatile implementation.

In my personal Celestia code ;-) I also experimented with a cycling solution through all 4 grids by hitting the ';' repeatedly. At the same time, the respective grid name would be flashed on the canvas. Just as we have it for the render paths or the star types.

Fridger
Image

Avatar
Cham M
Posts: 4324
Joined: 14.01.2004
Age: 60
With us: 21 years
Location: Montreal

Re: Flipping Grids (Celestia SVN)

Post #4by Cham » 04.06.2008, 17:32

Personally, I want to be able to show several grids at the same time, for educational purposes.

Can we use ";", "shift-;", "ctrl-;" and "shift-ctrl-;" for the various grids ?
"Well! I've often seen a cat without a grin", thought Alice; "but a grin without a cat! It's the most curious thing I ever saw in all my life!"

Avatar
Topic author
t00fri
Developer
Posts: 8772
Joined: 29.03.2002
Age: 22
With us: 22 years 10 months
Location: Hamburg, Germany

Re: Flipping Grids (Celestia SVN)

Post #5by t00fri » 04.06.2008, 17:39

Cham wrote:Personally, I want to be able to show several grids at the same time, for educational purposes.

Can we use ";", "shift-;", "ctrl-;" and "shift-ctrl-;" for the various grids ?

Since coding of keys (as long as there are free ones ;-) ) is a trivial task...of course we can do this, BUT

Firstly, we are talking about GUI implementation logics, rather than key association. Second, my trivial .celx gridflippers are only meant as interims for people to play with the new grids.

Fridger
Image

Avatar
Cham M
Posts: 4324
Joined: 14.01.2004
Age: 60
With us: 21 years
Location: Montreal

Re: Flipping Grids (Celestia SVN)

Post #6by Cham » 04.06.2008, 18:35

Well, the user has total freedom with the various keys ( ;      shift-;      ctrl-;      trl-shift-; )
"Well! I've often seen a cat without a grin", thought Alice; "but a grin without a cat! It's the most curious thing I ever saw in all my life!"

Avatar
Cham M
Posts: 4324
Joined: 14.01.2004
Age: 60
With us: 21 years
Location: Montreal

Re: Flipping Grids (Celestia SVN)

Post #7by Cham » 04.06.2008, 20:04

Apparently, there's an interaction between Earth's atmosphere, the horizontalgrid and the FOV :

cel://Follow/Sol:Earth/2004-01-08T08:24 ... 1782&ver=2

Just use the FOV a bit (zooming in and out) and I see the atmosphere disappearing. Anybody confirm this bug ?
"Well! I've often seen a cat without a grin", thought Alice; "but a grin without a cat! It's the most curious thing I ever saw in all my life!"


Return to “Scripting”