PDA

View Full Version : Importing Database question



alkart2003
08-07-2008, 09:30 PM
:lwicon:Is there a way to import a database into lightwave to plot a set of points and then replace the points with objects? I work for a planetarium and we are trying to plot a star field from a star database. In know there are alot of plugins that do star fields but we want to make our own star field. Some of the models we a trying to build are the pleadies, orion, etc. If there was a way to import the data to make these models then we could do flyarounds or flybys and the models would be accurate.

djgeenen
08-07-2008, 09:43 PM
What has worked for me in the past has been to put the x,y,z co-ordinates in a point (text) file. This can be read by Accutrans (www.micromouse.ca - $20USD) which can then output points in 3d to Lightwave. It may be that your database is already in the format that Accutrans can read. The format specs might take a a small bit of research. But the micromouse guy is eager to be helpful.

Cheers.

alkart2003
08-07-2008, 10:12 PM
So lightwave does not currently have a way to import a database? Do you have to use a plug-in to import data?

djgeenen
08-07-2008, 11:10 PM
I don't know if Lightwave can import a database. There are more knowledgeable people than me in this forum. But I have used Accutrans to get a database of point locations into Lightwave. Accutrans will read the x,y,z locations and create a Lightwave file with points in the defined locations.

Cheers.

mattclary
08-08-2008, 08:27 AM
So lightwave does not currently have a way to import a database? Do you have to use a plug-in to import data?

"Database import" is not something one normally associates with a graphics application, so no, that functionality is not there by default.

Lightwolf
08-08-2008, 08:42 AM
To make matters worse... "a database" is just about as specific as saying "a file". It could be anything.

Cheers,
Mike

alkart2003
08-08-2008, 10:49 AM
What we are trying to do is take the Yale, Hipparcos and other star database information which has the actual locations, distance, brightness etc. and make a model so we can the fly to specfic stars, deep sky objects etc. We already know about celestria and other applications but we really need to build our own. We have all the data in a spreadsheet format but we need to get that data into lightwave so it will automatically plot the hundreds of thousands of points needed for the starfield. Is there a way to do this. I'm not really familar with Lscript but can it be done with one and how? If not what other method might work.

dpont
08-08-2008, 11:07 AM
I don't think it is a simple data importation,
such catalogs don't deliver positions for stars
but rather right ascension and declination,
so you need calculations to convert them
as position, and if you have distances
a rescaling is necessary...
You can do that with Lscript, if the database is
a text file (ASCII), then you need to know the
fields and the separator for parsing the
file and addpoints/polys in Modeler.

Denis.

Lightwolf
08-08-2008, 11:43 AM
I don't think it is a simple data importation,
such catalogs don't deliver positions for stars
but rather right ascension and declination,
so you need calculations to convert them
as position, and if you have distances
a rescaling is necessary...
You can do that with Lscript, if the database is
a text file (ASCII), then you need to know the
fields and the separator for parsing the
file and addpoints/polys in Modeler.

It's binary:
http://archive.eso.org/ASTROM/TYC-2/format.htm

Cheers,
Mike

dpont
08-08-2008, 12:17 PM
Yes, Tycho database is so huge,
but he spoke of a spreadsheet format,
so may be it is a selection.

Denis.

Lightwolf
08-08-2008, 12:30 PM
Yes, Tycho database is so huge,
but he spoke of a spreadsheet format,
so may be it is a selection.

Actually, I just re-checked, it's not binary but ascii, one line per entry, separated by a "|".

Edit: And since the topic won't let me rest, here is a topic that discusses different catalogues and the problems that can come up: http://www.shatters.net/forum/viewtopic.php?f=4&t=813

Cheers,
Mike

mattclary
08-08-2008, 01:52 PM
To make matters worse... "a database" is just about as specific as saying "a file". It could be anything.

Cheers,
Mike

Yep, technically, pretty sure a model file could be considered a database.

Lightwolf
08-08-2008, 02:37 PM
Yep, technically, pretty sure a model file could be considered a database.
Hehe, technically just about anything could be, including the scraps of paper littering my desk ;)

Cheers,
Mike

alkart2003
08-08-2008, 02:44 PM
We have the data already processed into the xyz cord. star brightness and color each in there own column in a spreadsheet program and can save it as a text file. What is the next step into putting it into a Lscript? I've never used Lscript before. Then can we replace the points with actual spheres to act as stars?

Lightwolf
08-08-2008, 04:08 PM
How many stars are in your db?
Spheres in LW need a certain amount of polygons to look half decent - multiply that by the number of stars and you're likely to get a _very_ high number.

An alternative could be to use spherical hypervoxesl (these are mathematical spheres only visible when rendering), getting the size and colour right might be a little tricky though.

Do you have a sample line or two from the db with explanations to every column?

We tend to be a helpful bunch, I suspect one of us is bound to help out ;)

Cheers,
Mike

alkart2003
08-08-2008, 05:53 PM
I will try and get a sample of the database to show. I hope it will help on trying to figure out how to import it to make our starfield. it will be early next week before I can post it. We don't work weekends and the data is at work. Thanks for all the help so far!

kmacphail
08-24-2008, 01:21 PM
This was an interesting thread. Did you find a way to import your database?

Cheers,

-Kevin