3D Mars and the new CVS code

Post requests, images, descriptions and reports about work in progress here.
Avatar
Topic author
cartrite
Posts: 1978
Joined: 15.09.2005
With us: 19 years 6 months
Location: Pocono Mountains, Pennsylvania, USA Greate Grandfother from Irshava, Zakarpattia Oblast Ukraine

3D Mars and the new CVS code

Post #1by cartrite » 03.08.2006, 06:11

A while back I uploaded a stand alone model (no textures) called 3D Mars. It combines 2 models with 131k vertices with a 3rd model of the planet with about 16k vertices.

With the new cvs code (07/30/2006) that improves rendering I was able to modify that model in the following manner. I did not upload this. I may update this after the next release of Celestia but anyone who may be interested who has compiled the latest cvs and would like to try this, This how I did it.
1. cmodfix -a mars-mons-valles-131.cmod 1.cmod
2. cmodfix -s 180 1.cmod 2.cmod
3. cmodfix -t 2.cmod 1.cmod
4. cmodfix -u 1.cmod 2.cmod
5. open in a text editor and add to the materials section

Code: Select all

specular 0.5 0.5 0.55
specpower 1
texture0 "mars.png"
normalmap "norm.png"
specularmap "spec.png"

6. cmodfix -b 2.cmod mars-mons-valles131.cmod
7. Add a texture/medres folder with a 4k mars texture and normalmap called mars.png, norm.png
8. Add a texture called spec.png which is just a 1k grayscale file with one color that is dark grey.
9. The ssc file for this looks like this.

Code: Select all

"Mars2" "Sol/Mars"
{
       Mesh "mars-mons-valles-131.cmod"
       #Texture "mars.*"
       Radius 3396 #small
       Atmosphere {
      Height 50
      Lower [ 0.8 0.6 0.6 ]
      Upper [ 0.7 0.3 0.3 ]
      Sky [ 0.83 0.75 0.65 ]
                Sunset [ 0.7 0.7 0.8 ]
                # Slightly bluish sunset, as seen in true color pictures
                # from Pathfinder
   }

        CustomOrbit "vsop87-mars"
   EllipticalOrbit
   {
   Period            1.8809
   SemiMajorAxis     1.5237
   Eccentricity      0.0934
   Inclination       1.8506
   AscendingNode     49.479
   LongOfPericenter 336.041
        MeanLongitude    355.453
   }

   RotationPeriod        24.622962
   Obliquity             26.72
   EquatorAscendingNode    82.91
   RotationOffset       136.005
        Albedo            0.150
}

Of course one could change the names around but the important things to note are that I could not get this to work by simply modifying the ssc file. Tangents were generated after the smooth 180 run. The textures were declared in the model not the ssc file. The Modify command did not work so I had to define a new planet with it's own orbit. I used the same orbit as mars but made it orbit mars instead of the sun. A sreenshot of the same model thats on the motherlode modified as stated above.

Image

This new cvs code really makes a great improvement.

cartrite
Last edited by cartrite on 03.08.2006, 11:49, edited 1 time in total.
VivoBook_ASUSLaptop X712JA_S712JA Intel(R) UHD Graphics 8gb ram. Intel(R) Core(TM) i5-1035G1 CPU @ 1.00GHz, 1190 Mhz, 4 Core(s), 8 Logical Processor(s) 8 GB ram. Running on Windows 11 and OpenSuse 15.4

Avatar
Topic author
cartrite
Posts: 1978
Joined: 15.09.2005
With us: 19 years 6 months
Location: Pocono Mountains, Pennsylvania, USA Greate Grandfother from Irshava, Zakarpattia Oblast Ukraine

Post #2by cartrite » 03.08.2006, 07:11

A word of caution. The new cvs code (07/30/2006) still has some bugs. This screenshot shows what the model looks like in rendering modes other than OpenGL 2.0. This seems to be caused by the specularmap, specular and specpower lines in the model. This problem will show up in any version of Celestia prior to the new cvs code, and with the new cvs code in all rendering modes but OpenGL.

Image

cartrite
Last edited by cartrite on 03.08.2006, 11:50, edited 2 times in total.
VivoBook_ASUSLaptop X712JA_S712JA Intel(R) UHD Graphics 8gb ram. Intel(R) Core(TM) i5-1035G1 CPU @ 1.00GHz, 1190 Mhz, 4 Core(s), 8 Logical Processor(s) 8 GB ram. Running on Windows 11 and OpenSuse 15.4

Avatar
selden
Developer
Posts: 10192
Joined: 04.09.2002
With us: 22 years 7 months
Location: NY, USA

Post #3by selden » 03.08.2006, 11:42

Cartrite,

Could you edit your post to specify the date that you downloaded the CVS code? Messages stay around for a long time and may be posted a day or so after the code was downloaded, so it's best to be explicit about the time stamps.
[edit]
Also, is this a 3DS model or a CMOD model?
If the latter, have you tried running cmodfix to adjust the surface normals?

p.s.
Usually when reporting a complex problem, I've found that it's more productive to provide a minimal standalone Addon that demonstrates the error, including an HTML document with a URL that takes the observer to a failing viewpoint.
That way the developers don't have to try to recreate the environment from scratch, which they may not be able to do.
[/edit]
Last edited by selden on 03.08.2006, 11:59, edited 3 times in total.
Selden

Avatar
Topic author
cartrite
Posts: 1978
Joined: 15.09.2005
With us: 19 years 6 months
Location: Pocono Mountains, Pennsylvania, USA Greate Grandfother from Irshava, Zakarpattia Oblast Ukraine

Post #4by cartrite » 03.08.2006, 11:46

Sorry, The cvs was downloaded on 07/30/2006.
VivoBook_ASUSLaptop X712JA_S712JA Intel(R) UHD Graphics 8gb ram. Intel(R) Core(TM) i5-1035G1 CPU @ 1.00GHz, 1190 Mhz, 4 Core(s), 8 Logical Processor(s) 8 GB ram. Running on Windows 11 and OpenSuse 15.4

Avatar
Topic author
cartrite
Posts: 1978
Joined: 15.09.2005
With us: 19 years 6 months
Location: Pocono Mountains, Pennsylvania, USA Greate Grandfother from Irshava, Zakarpattia Oblast Ukraine

Post #5by cartrite » 03.08.2006, 12:20

Selden wrote:
Also, is this a 3DS model or a CMOD model?
If the latter, have you tried running cmodfix to adjust the surface normals?
This is the model on the motherlode which is cmod. The normals were already adjusted.
I modified it as stated in my first post.

Usually when reporting a complex problem, I've found that it's more productive to provide a minimal standalone Addon that demonstrates the error, including an HTML document with a URL that takes the observer to a failing viewpoint.
That way the developers don't have to try to recreate the environment from scratch, which they may not be able to do.


I wish I had a website to show these things but I don't. I could email it if someone needs to recreate the problem.

As far as I can tell this problem started showing itself after I generated tangents to get the normalmaps to work. I created a number of models and everyone that was modified with tangents, specmaps, and normalmaps, etc. show the same thing, with all versions of Celestia. Of course they work correctly with cvs 07/30/2006 in OpenGL2.0 which is why I modified them in the first place.
VivoBook_ASUSLaptop X712JA_S712JA Intel(R) UHD Graphics 8gb ram. Intel(R) Core(TM) i5-1035G1 CPU @ 1.00GHz, 1190 Mhz, 4 Core(s), 8 Logical Processor(s) 8 GB ram. Running on Windows 11 and OpenSuse 15.4

Avatar
selden
Developer
Posts: 10192
Joined: 04.09.2002
With us: 22 years 7 months
Location: NY, USA

Post #6by selden » 03.08.2006, 13:18

You might want to consider one of the "free" web services, although they make up for it by having lots of advertisements. I'm pretty sure there have been some postings here about them.

GeoCities is one of the oldest.
Selden

Avatar
Chuft-Captain
Posts: 1779
Joined: 18.12.2005
With us: 19 years 3 months

Post #7by Chuft-Captain » 03.08.2006, 16:51

selden wrote:I'm pretty sure there have been some postings here about them.

GeoCities is one of the oldest.


I personally wouldn't recommend GeoCities for a number of reasons. Limit of 15MB on maximum filesize uploadable, unwieldy user interface, and there is always the danger that they may delete your site without notice and without giving you a reason: http://celestiaproject.net/forum/viewtopic.php ... highlight=
(EDIT: actually I think 10MB is the limit on individual files, and 30MB total filespace)

I'd recommend SiteSled.com which I've been using for at least as long as GeoCities and, although somewhere in the fine print they do reserve the right to delete your site without notice just like GeoCities, I haven't had any problems with them to date.
(100MB limit and no limit on individual file size)
"Is a planetary surface the right place for an expanding technological civilization?"
-- Gerard K. O'Neill (1969)

CATALOG SYNTAX HIGHLIGHTING TOOLS LAGRANGE POINTS

avpruler
Posts: 57
Joined: 30.10.2005
With us: 19 years 5 months

Post #8by avpruler » 16.09.2006, 00:27

how do i get this thing to work, do i copy paste into a txt???

PLEASE HELP MEEEEEEEEEEEEEEEEEE
Fall Out Boy!!!

W00T!!!!! ^^ ^^ ^^

Avatar
selden
Developer
Posts: 10192
Joined: 04.09.2002
With us: 22 years 7 months
Location: NY, USA

Post #9by selden » 16.09.2006, 00:32

How do you get what to work?

Including images in posts?

Celestia?

Downloading Addons?

Making your own Addons available for others?

I'm sorry, but you really have to be explicit.
Selden

Avatar
Topic author
cartrite
Posts: 1978
Joined: 15.09.2005
With us: 19 years 6 months
Location: Pocono Mountains, Pennsylvania, USA Greate Grandfother from Irshava, Zakarpattia Oblast Ukraine

Post #10by cartrite » 16.09.2006, 03:43

The model will work as downloaded by putting the extracted folder 3dmars into the extras folder and having a texture of mars in any of the textures folders, ie, lores, medres..

BUT...........

If you are trying to modify it to have a normalmap, the above instructions should work. That was exactly what I did and that was the order in which I did it. You will need cmodfix. First you should convert it to ascii with cmodfix and familiarize yourself with the models structure. To make a normalmap work, you do need to generate tangents.

At the time I wrote those instructions, all the SSC file commands where not enabled for meshes in cvs. I think that now they are. So you could modify the SSC file with texture names but the model will still need tangents. And you would also need a recent CVS version of Celestia.

cartrite
VivoBook_ASUSLaptop X712JA_S712JA Intel(R) UHD Graphics 8gb ram. Intel(R) Core(TM) i5-1035G1 CPU @ 1.00GHz, 1190 Mhz, 4 Core(s), 8 Logical Processor(s) 8 GB ram. Running on Windows 11 and OpenSuse 15.4


Return to “Add-on development”