Join us at the Oolite Anniversary Party -- London, 7th July 2024, 1pm
More details in this thread.

[RELEASE] - OOliteInfo3d

Discussion and information relevant to creating special missions, new ships, skins etc.

Moderators: another_commander, winston

Post Reply
User avatar
maaarcooose
---- E L I T E ----
---- E L I T E ----
Posts: 397
Joined: Sun May 29, 2011 9:36 pm
Location: Devon, UK
Contact:

[RELEASE] - OOliteInfo3d

Post by maaarcooose »

I am please to announce (finally) a release of OOliteInfo3D

http://www.theramist.co.uk/blog/?p=128
Image

I've been struggling for some time to create an installer package for this as most of the windows exe creators for Python only seem to like 32bit and the mac version of VPython has trouble with 64bit.
The intrepid amongst you can simply download the source file from the link above, install Python and vPython http://www.vpython.org/
There should be no other dependencies as all data is generated procedurally.

Running on a mac can be tricky. Depending on which version of Python you are using, and the version of VPython you might need to run as follows:
arch -i386 python ooliteinfo3d.py

There is a new release of VPython which in theory should address these issues but I have been unable to test it as yet.

Also this prog is a bit slow to run. It seems okay on my MacBook Pro with Intel graphics 4GB and my Core2 Duo work PC with an Nvidia. Your millage may vary which is why I've added the option to turn off the grid and the jump routes.

Rotate by holding down the right mouse button, zoom by holding down the middle.
Click on planets to show their info. Click again to hide it.
Pressing <C> will recenter the display but not the zoom (vPython quirks).

When you click on a planet it will show an opaque sphere to indicate the 7LY jump area from that planet.

Lastly I have created a Z coordinate that basically just uses the government number and seems to give a good spread on the planets that overlap.

It's not perfect but give it a go.

Thanks to PhantorGorth for our many conversations on the procedurally generated data and a nice bit of healthy competition.
Also thanks to whoever created TextElite as this helped me work out some of the more odd bits of data.

!m!
Trading computers and writing stuff....
Website: http://www.theramist.co.uk/
OOliteInfo: http://www.theramist.co.uk/ooliteinfo/oo.php
User avatar
submersible
Commodore
Commodore
Posts: 264
Joined: Thu Nov 10, 2011 7:49 am

Re: [RELEASE] - OOliteInfo3d

Post by submersible »

Tried it on ubuntu 12.04 - segfaults right after the window opens.

Code: Select all

OOLITEINFO 3D - Startup....

Linux posix 3.2.0-37-generic-pae
Win:  ('', '', '', '')
Linux:  ('Ubuntu', '12.04', 'precise')
Mac:  ('', ('', '', ''), '')
Java:  ('', '', ('', '', ''), ('', '', ''))
Functions defined - Running
Segmentation fault (core dumped)
GDB output - probably not that helpful. - I will try updating and report my resuts.

Code: Select all

 gdb --args  python ~/Downloads/ooliteinfo3d.py 
GNU gdb (Ubuntu/Linaro 7.4-2012.04-0ubuntu2.1) 7.4-2012.04
Copyright (C) 2012 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "i686-linux-gnu".
For bug reporting instructions, please see:
<http://bugs.launchpad.net/gdb-linaro/>...
Reading symbols from /usr/bin/python...(no debugging symbols found)...done.
(gdb) run
Starting program: /usr/bin/python /home/andrewb/Downloads/ooliteinfo3d.py
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/i386-linux-gnu/libthread_db.so.1".
OOLITEINFO 3D - Startup....

Linux posix 3.2.0-37-generic-pae
Win:  ('', '', '', '')
Linux:  ('Ubuntu', '12.04', 'precise')
Mac:  ('', ('', '', ''), '')
Java:  ('', '', ('', '', ''), ('', '', ''))
Functions defined - Running
[New Thread 0xb2ec4b40 (LWP 24978)]
[New Thread 0xb24ffb40 (LWP 24979)]
[New Thread 0xb1affb40 (LWP 24980)]

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0xb2ec4b40 (LWP 24978)]
0xb0b275e0 in ?? ()
(gdb) backtrace
#0  0xb0b275e0 in ?? ()
#1  0xb59b8b27 in gdk_gl_get_proc_address () from /usr/lib/libgdkglext-x11-1.0.so.0
#2  0xb781336b in Gdk::GL::get_proc_address(char const*) ()
   from /usr/lib/libgdkglextmm-x11-1.2.so.0
#3  0xb675d7ab in ?? () from /usr/lib/python2.7/dist-packages/cvisualmodule.so
#4  0xb6743889 in ?? () from /usr/lib/python2.7/dist-packages/cvisualmodule.so
#5  0xb674448b in ?? () from /usr/lib/python2.7/dist-packages/cvisualmodule.so
#6  0xb6766a47 in ?? () from /usr/lib/python2.7/dist-packages/cvisualmodule.so
#7  0xb675dc4f in ?? () from /usr/lib/python2.7/dist-packages/cvisualmodule.so
#8  0xb672e1de in ?? () from /usr/lib/python2.7/dist-packages/cvisualmodule.so
#9  0xb675d9de in ?? () from /usr/lib/python2.7/dist-packages/cvisualmodule.so
#10 0xb6763252 in ?? () from /usr/lib/python2.7/dist-packages/cvisualmodule.so
#11 0xb615aa54 in ?? () from /usr/lib/i386-linux-gnu/libglibmm-2.4.so.1
#12 0xb5b7ea7f in ?? () from /lib/i386-linux-gnu/libglib-2.0.so.0
#13 0xb5b7dd86 in g_main_context_dispatch () from /lib/i386-linux-gnu/libglib-2.0.so.0
#14 0xb5b7e125 in ?? () from /lib/i386-linux-gnu/libglib-2.0.so.0
#15 0xb5b7e56b in g_main_loop_run () from /lib/i386-linux-gnu/libglib-2.0.so.0
#16 0xb5de0b8f in gtk_main () from /usr/lib/i386-linux-gnu/libgtk-x11-2.0.so.0
#17 0xb6407194 in Gtk::Main::run_impl() () from /usr/lib/i386-linux-gnu/libgtkmm-2.4.so.1
#18 0xb6407bcf in Gtk::Main::run() () from /usr/lib/i386-linux-gnu/libgtkmm-2.4.so.1
#19 0xb675e23e in ?? () from /usr/lib/python2.7/dist-packages/cvisualmodule.so
#20 0xb6762fcd in ?? () from /usr/lib/python2.7/dist-packages/cvisualmodule.so
#21 0xb67632bd in ?? () from /usr/lib/python2.7/dist-packages/cvisualmodule.so
#22 0xb5ae248c in thread_proxy () from /usr/lib/libboost_thread.so.1.46.1
#23 0xb7fa7d4c in start_thread (arg=0xb2ec4b40) at pthread_create.c:308
#24 0xb7cc4d3e in clone () at ../sysdeps/unix/sysv/linux/i386/clone.S:130
User avatar
maaarcooose
---- E L I T E ----
---- E L I T E ----
Posts: 397
Joined: Sun May 29, 2011 9:36 pm
Location: Devon, UK
Contact:

Re: [RELEASE] - OOliteInfo3d

Post by maaarcooose »

Intersting....

Is your OS 32 or 64 bit?

!m!
Trading computers and writing stuff....
Website: http://www.theramist.co.uk/
OOliteInfo: http://www.theramist.co.uk/ooliteinfo/oo.php
User avatar
maaarcooose
---- E L I T E ----
---- E L I T E ----
Posts: 397
Joined: Sun May 29, 2011 9:36 pm
Location: Devon, UK
Contact:

Re: [RELEASE] - OOliteInfo3d

Post by maaarcooose »

I've just read on the vpython website that this is a known issue with Ubuntu.

Apparently an issue concerning the NVidia drivers.
Have a look at the bottom on this page unt her older versions heading:
http://www.vpython.org/contents/download_linux.html

I'm currently trying to get it running on my Linux virtual. I honestly thought that Linux would run this the easiest.

!m!
Trading computers and writing stuff....
Website: http://www.theramist.co.uk/
OOliteInfo: http://www.theramist.co.uk/ooliteinfo/oo.php
User avatar
Amah
---- E L I T E ----
---- E L I T E ----
Posts: 485
Joined: Tue Aug 28, 2012 8:05 pm
Location: aboard the Laenina Crowne - Yasen-N class space freighter
Contact:

Re: [RELEASE] - OOliteInfo3d

Post by Amah »

Just for the record:
Debian GNU/Linux 7.0 - amd64
python 2.7.3 + python-visual

seems kind to work. Able to resize and spin the grid, but having the star name labels permanantly displayed.
Amah
User avatar
maaarcooose
---- E L I T E ----
---- E L I T E ----
Posts: 397
Joined: Sun May 29, 2011 9:36 pm
Location: Devon, UK
Contact:

Re: [RELEASE] - OOliteInfo3d

Post by maaarcooose »

Amah wrote:
Just for the record:
Debian GNU/Linux 7.0 - amd64
python 2.7.3 + python-visual

seems kind to work. Able to resize and spin the grid, but having the star name labels permanantly displayed.
That shouldn't happen.
It initially displays all the star labels in order to get round an issue where the labels never displayed.
I'll have another look at the code and try to sort it out.

!m!
Trading computers and writing stuff....
Website: http://www.theramist.co.uk/
OOliteInfo: http://www.theramist.co.uk/ooliteinfo/oo.php
User avatar
maaarcooose
---- E L I T E ----
---- E L I T E ----
Posts: 397
Joined: Sun May 29, 2011 9:36 pm
Location: Devon, UK
Contact:

Re: [RELEASE] - OOliteInfo3d

Post by maaarcooose »

Amah wrote:
Just for the record:
Debian GNU/Linux 7.0 - amd64
python 2.7.3 + python-visual

seems kind to work. Able to resize and spin the grid, but having the star name labels permanantly displayed.
So, if you try turning the labels on and off do they dissapear?

!m!
Trading computers and writing stuff....
Website: http://www.theramist.co.uk/
OOliteInfo: http://www.theramist.co.uk/ooliteinfo/oo.php
m4r35n357
---- E L I T E ----
---- E L I T E ----
Posts: 296
Joined: Wed Jan 19, 2011 4:00 pm

Re: [RELEASE] - OOliteInfo3d

Post by m4r35n357 »

Partial success here:

Code: Select all

$ python ooliteinfo3d.py 
OOLITEINFO 3D - Startup....

Linux posix 3.2.0-4-686-pae
Win:  ('', '', '', '')
Linux:  ('debian', '7.0', '')
Mac:  ('', ('', '', ''), '')
Java:  ('', '', ('', '', ''), ('', '', ''))
Functions defined - Running
Draw the grid
Reading Galaxy Data 1
Plotting Planets
Plotting jump routes
Traceback (most recent call last):
  File "ooliteinfo3d.py", line 757, in <module>
    text(pos=vector(5,-43,0), text='Grid Toggle', align='left', height=5, font='Arial')
NameError: name 'text' is not defined
clearly a dependency/import issue, but I'm not sure where "text" is supposed to come from . . . any ideas?
User avatar
maaarcooose
---- E L I T E ----
---- E L I T E ----
Posts: 397
Joined: Sun May 29, 2011 9:36 pm
Location: Devon, UK
Contact:

Re: [RELEASE] - OOliteInfo3d

Post by maaarcooose »

m4r35n357 wrote:
Partial success here:

Code: Select all

$ python ooliteinfo3d.py 
OOLITEINFO 3D - Startup....

Linux posix 3.2.0-4-686-pae
Win:  ('', '', '', '')
Linux:  ('debian', '7.0', '')
Mac:  ('', ('', '', ''), '')
Java:  ('', '', ('', '', ''), ('', '', ''))
Functions defined - Running
Draw the grid
Reading Galaxy Data 1
Plotting Planets
Plotting jump routes
Traceback (most recent call last):
  File "ooliteinfo3d.py", line 757, in <module>
    text(pos=vector(5,-43,0), text='Grid Toggle', align='left', height=5, font='Arial')
NameError: name 'text' is not defined
clearly a dependency/import issue, but I'm not sure where "text" is supposed to come from . . . any ideas?
Hmmmm...

Text should be a standard function of vPython. Which version have you got installed?

!m!
Trading computers and writing stuff....
Website: http://www.theramist.co.uk/
OOliteInfo: http://www.theramist.co.uk/ooliteinfo/oo.php
m4r35n357
---- E L I T E ----
---- E L I T E ----
Posts: 296
Joined: Wed Jan 19, 2011 4:00 pm

Re: [RELEASE] - OOliteInfo3d

Post by m4r35n357 »

maaarcooose wrote:
Hmmmm...
Text should be a standard function of vPython. Which version have you got installed?
!m!
Debian wheezy package
ii python-visual 1:5.12-1.5 i386 VPython 3D scientific visualization library
looks like the packagers might have gone mad & split it up or something, I'll see if I can find out, thanks.
User avatar
maaarcooose
---- E L I T E ----
---- E L I T E ----
Posts: 397
Joined: Sun May 29, 2011 9:36 pm
Location: Devon, UK
Contact:

Re: [RELEASE] - OOliteInfo3d

Post by maaarcooose »

m4r35n357 wrote:
maaarcooose wrote:
Hmmmm...
Text should be a standard function of vPython. Which version have you got installed?
!m!
Debian wheezy package
ii python-visual 1:5.12-1.5 i386 VPython 3D scientific visualization library
looks like the packagers might have gone mad & split it up or something, I'll see if I can find out, thanks.
I've got an odd feeling that the text module was only available in later releases.
I'll have a check of the release notes.

!m!
Trading computers and writing stuff....
Website: http://www.theramist.co.uk/
OOliteInfo: http://www.theramist.co.uk/ooliteinfo/oo.php
Post Reply