Celestia 1.5.0pre3

General discussion about Celestia that doesn't fit into other forums.
Topic author
chris
Site Admin
Posts: 4211
Joined: 28.01.2002
With us: 22 years 2 months
Location: Seattle, Washington, USA

Celestia 1.5.0pre3

Post #1by chris » 24.05.2007, 17:02

Finally, another prerelease of 1.5.0. The Windows package is here: http://www.celestiaproject.net/~claurel/celest ... .0pre3.exe

This version has most of the changes that will go into 1.5.0 final. One significant remaining area of development is the atmosphere code.

Here is what has changed since 1.5.0pre2:

Code: Select all

- Don't render Sun's orbit about SSB
- Mac OS X: multhreaded load
- Improved DSO picking
- New planetary feature names from the IAU:
  - Mars, Phobos, Venus, Titan, Enceladus
- Switched to double precision for rotation and precession periods--keeps
  synchronous rotations from drifting.
- Localization
  - Updated translation files
  - Added localized versions of documentation and scripts
- Improved depth sorting of translucent models
- Orbit rendering improvements:
  - Don't render the Sun's orbit about the SSB (or any other aperiodic,
    infinite trajectories.)
  - Switch blend mode
  - Changed color of moon orbits
  - Fade orbits to invisibile as their onscreen size shrinks.
- celx scripting enhancements:
  - Added catalogNumber, hubbleType, and absoluteMagnitude to table returned
    by getinfo.
  - Added getdsocount and getdso methods for celestia object
  - stars and dso iterators
  - Added getObjTypeName method to DeepSkyObject
  - ScriptedOrbits/Rotations run in separate context unless
    ScriptSystemAccessPolicy is allow
  - Lua hook no longer required in order to use ScriptOrbit/Rotation
  - get/setaltazimuthmode
- Fixed bug in mesh optimization code that was merging materials which
  actually distinct.
- Defined a lighting model to use for models that don't have normals
  - Prevents crash on Mac OS X version
- Added support for point sprites to cmod format
- Use GLSL for rendering nebula models
- Added blend type to cmod materials: additive and normal alpha blending are
  supported.
- Fixed obscure cmod loader crash (affected models contain submeshes with
  zero primitive groups.)
- Added support for automake 1.10
- Choose Lua 5.1 over Lua 5.0 when both are available
- New planets: Gliese 581 c & d, HD 175541 b, HD 210702 b, HD192699 b,
  HD 47536 c, XO-2 b, HD 147506 (HAT-P-2), HD 17092 b
- Minor moons:
  - Added 2007S1, 2007S2, and 2007S3
  - New IAU names for small satellites of Jupiter, Saturn, and Neptune
  - Updated orbital elements for 2006 S6
- Fixed bug in PNG image capture
- Stricter GLSL shader compliance
- Mac OS X: refresh star browser when it becomes active
- Fixed bug that limited virtual texture detail on ringed planets
- Added app. magnitude-based fading effect for solar system object labels
- Added app. magnitude-based fading effect for star labels
- Use simpler cloud shadows (less driver headaches.)
- Use fewer interpolants in shaders; prevents bad shaders for cloud shadow+
  eclipse shadow+night lights cases
- Fixed some orbit rendering artifacts (such as disappearing orbits on Mac)
- Added a major update of the galaxy database such that close to 100% of the
  galaxies now involve distance measurements
- Included the complete local group of galaxies
- Added varying label transparency also for stars
- Added the PERL scripts used for extraction of galaxy and binary orbit data
  from scientific sources. They both are useful tools and a concise
  documentation of Celestia's data
- updated binary orbit data ( visualbins.stc and spectbins.stc) along with
  respective PERL scripts (visualbins.pl and spectbins.pl)
- New IAU names for features on Titan and Enceladus
- Celx scripts:
  - Added script for marking & red-shift coloring all 10000+ galaxies
  - Added script for marking all member galaxies of the local group
- Fixed crash when deepsky.dsc was empty
- Increased max draw distance to 100 Gly


Thanks to everyone who contributed on the development and bug reporting for this release.

--Chris

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

Post #2by t00fri » 24.05.2007, 17:36

Chris,

I thought we had agreed to set automag=ON by default after the clearcut results of the automag= ON/OFF poll??

Bye Fridger
Image

Topic author
chris
Site Admin
Posts: 4211
Joined: 28.01.2002
With us: 22 years 2 months
Location: Seattle, Washington, USA

Post #3by chris » 24.05.2007, 17:53

t00fri wrote:Chris,

I thought we had agreed to set automag=ON by default after the clearcut results of the automag= ON/OFF poll??


I was in the process of posting to the dev list about that . . . I do want to change to automag on by default. I started to do it for this release, but the code for setting the defaults is sort of a mess, and I want to clean it up when I make the change. There are multiple places in the code where the defaults are set; the worst part is that the list of default settings is in the platform-specific part of the code. I want the defaults defined in a single place for cross-platform consistency.

The vast majority of people using prereleases have already installed Celestia, so they won't be affected by the default settings. It seemed like it would be ok to postpone the change until pre4.

--Chris

Avatar
PlutonianEmpire M
Posts: 1374
Joined: 09.09.2004
Age: 39
With us: 19 years 7 months
Location: MinneSNOWta
Contact:

Post #4by PlutonianEmpire » 24.05.2007, 20:31

gah! :x

I downloaded it, and now the new atmosphere code won't work at all!

I just see a bright red ball in space now.
Terraformed Pluto: Now with New Horizons maps! :D

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

Post #5by selden » 24.05.2007, 21:13

pre3 uses the new atmosphere code for Earth, so I suspect you may have made a typo somewhere. Please post the SSC file that's causing problems.

[edit]Bright red is Celestia's indicator for an error return in a vertex shader routine. If that's the problem, please post a copy of shaders.log, too.[/edit]
Selden

Avatar
PlutonianEmpire M
Posts: 1374
Joined: 09.09.2004
Age: 39
With us: 19 years 7 months
Location: MinneSNOWta
Contact:

Post #6by PlutonianEmpire » 24.05.2007, 21:27

I don't know which one's causing problems, because I have multiple terraformed bodies in the Sol System using the default new atmosphere code, and they all show up as red balls in pre3. the solarsys.ssc that came with pre3 is absolutely untouched...

earth

Code: Select all

Modify "Earth" "Sol" {
   Texture "snowball_earth.png"
   BumpMap "snowball_earth-bump.png"
   BumpHeight 0.500
   HazeColor [ 1.00 1.00 1.00 ]
   HazeDensity 1.00
   NightTexture "black.png"

SpecularTexture "snowball_earth-spec.png"
   SpecularColor [ 1.000 1.000 0.750 ]
   SpecularPower 25.000

   Atmosphere {
      Height 62
      Lower [ 1.00 1.00 1.00 ]
      #Lower [ 0.40 0.60 1.00 ]
      Upper [ 0.00 0.00 0.50 ]
      Sky   [ 0.20 0.40 1.00 ]
      Sunset [ 1.00 0.60 0.20 ]
      CloudHeight 6.2
      CloudSpeed 35.000
      CloudMap "snowball_earth-clouds.png"

      #Mie 0.001
      #MieAsymmetry -0.25
      #Rayleigh [ 0.006 0.006 0.006 ]
      #MieScaleHeight 12
   }

   Albedo 0.9

}


venus

Code: Select all

Modify "Venus" "Sol" {
   Texture "th_bvenus2k.jpg"
   NightTexture "th_bvenusnight2k.jpg"
   Color [ 0.85 0.85 1.0 ]
   HazeColor [ 0.40 0.60 1.00 ]
   HazeDensity 1.000

SpecularTexture "th_bvenusspec2k.jpg"
   SpecularColor [ 1.000 1.000 0.750 ]
   SpecularPower 17

   Atmosphere {
      Height 75
      Lower [ 0.40 0.60 1.00 ]
      Upper [ 0.00 0.00 0.50 ]
      Sky   [ 0.20 0.40 1.00 ]
      #Sunset [ 1.00 0.40 0.00 ]
      CloudHeight 7
      CloudSpeed 26
      CloudMap "tf_venus-clouds.png"

      Mie 0.001
      MieAsymmetry -0.25
      Rayleigh [ 0.001 0.0025 0.006 ]
      MieScaleHeight 12
   }

   Albedo            0.71

}


titan

Code: Select all

Modify "Titan" "Sol/Saturn" {
   Texture "green_titan2k.png"
   BumpMap "green_titan2k-bump.png"
   BumpHeight 0.500
   HazeColor [ 0.40 0.60 1.00 ]
   HazeDensity 0.800

SpecularTexture "green_titan2k-spec.png"
        SpecularColor [ 1.000 1.000 0.750 ]
   SpecularPower 60.000

   Atmosphere {
      Height 62
      Lower [ 0.40 0.60 1.00 ]
      Upper [ 0.00 0.00 0.50 ]
      Sky   [ 0.20 0.40 1.00 ]
      CloudHeight 6.2
      CloudSpeed 65.000
      CloudMap "green_titan-clouds.png"

      Mie 0.001
      MieAsymmetry -0.25
      Rayleigh [ 0.001 0.0025 0.006 ]
      MieScaleHeight 12
   }

   Albedo           0.30
}


mars

Code: Select all

Modify "Mars" "Sol" {
   Texture "earthly_mars.png"
   BumpMap "earthly_mars-bump.png"
   Color [ 0.800 0.800 1.000 ]
   HazeColor [ 0.40 0.60 1.00 ]
   HazeDensity 0.800

SpecularTexture "earthly_mars-spec.png"
        SpecularColor            [ 1.000 1.000 0.750 ]
   SpecularPower              40.000

   Atmosphere {
      Height 62
      Lower [ 0.40 0.60 1.00 ]
      Upper [ 0.00 0.00 0.50 ]
      Sky   [ 0.20 0.40 1.00 ]
      CloudHeight 6.2
      CloudSpeed 65.000
      CloudMap "earthly_mars-clouds.png"

      Mie 0.001
      MieAsymmetry -0.25
      Rayleigh [ 0.001 0.0025 0.006 ]
      MieScaleHeight 12
   }

   Albedo           0.30
}


pluto

Code: Select all

Modify "Pluto" "Sol" {
   Texture "terraformedpluto.png"
   BumpMap "terraformedpluto-bump2.png"
   BumpHeight 1.700
   HazeColor [ 0.20 0.40 0.80 ]
   HazeDensity 1.000
   NightTexture "terraformedpluto-night.png"

SpecularTexture "terraformedpluto-spec.png"
        SpecularColor            [ 1.000 1.000 0.750 ]
   SpecularPower              60.000

   Atmosphere {
      Height 35
      Lower [ 0.20 0.40 0.80 ]
      Upper [ 0.00 0.00 0.25 ]
      Sky   [ 0.00 0.00 0.26 ]
      CloudHeight 3.5
      CloudSpeed 65.000
      CloudMap "terraformedpluto-clouds.png"

      Mie 0.001
      MieAsymmetry -0.25
      Rayleigh [ 0.000 0.000 0.003 ]
      MieScaleHeight 8
   }

   #CustomOrbit "pluto-jpl"

   Albedo           0.30
}
Terraformed Pluto: Now with New Horizons maps! :D

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

Post #7by selden » 24.05.2007, 21:57

I think it's a shader bug. Chris did mention that he's planning to work some more on the atmosphere code.

The best way to help Chris find and fix the bug is to provide an Addon that's as simple as possible which generates the error.

I managed to persuade Celestia v1.5.0pre3 to generate shader errors for the atmosphere around an earth-like planet in a multiple-star system. I don't know if it's the same as your problem, though.

To see this error, Install the addon, open its html file and click on the Cel:// URL.
http://www.lepp.cornell.edu/~seb/celest ... er-bug.zip (3KB)
Selden

Avatar
PlutonianEmpire M
Posts: 1374
Joined: 09.09.2004
Age: 39
With us: 19 years 7 months
Location: MinneSNOWta
Contact:

Post #8by PlutonianEmpire » 24.05.2007, 22:24

seems to be. 'xcept i haven't added a second star to the sol system.
Terraformed Pluto: Now with New Horizons maps! :D

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

Post #9by selden » 24.05.2007, 22:33

Please try to create an Addon that demonstrates the failure that you see.

There are likely to be several different things that can cause a shader error like this. They will have the same symptoms and look the same but will be caused by different problems.
Last edited by selden on 24.05.2007, 22:40, edited 1 time in total.
Selden

Topic author
chris
Site Admin
Posts: 4211
Joined: 28.01.2002
With us: 22 years 2 months
Location: Seattle, Washington, USA

Post #10by chris » 24.05.2007, 22:35

PlutonianEmpire wrote:seems to be. 'xcept i haven't added a second star to the sol system.


Can you post the contents the shaders.log file that Celestia creates?

--Chris

Avatar
PlutonianEmpire M
Posts: 1374
Joined: 09.09.2004
Age: 39
With us: 19 years 7 months
Location: MinneSNOWta
Contact:

Post #11by PlutonianEmpire » 24.05.2007, 22:37

chris wrote:
PlutonianEmpire wrote:seems to be. 'xcept i haven't added a second star to the sol system.

Can you post the contents the shaders.log file that Celestia creates?

--Chris

Vertex shader source:
1: #version 110
2: uniform vec3 light0_direction;
3: uniform vec3 light0_diffuse;
4: uniform vec3 light0_specular;
5: uniform vec3 light0_halfVector;
6: uniform vec3 light1_direction;
7: uniform vec3 light1_diffuse;
8: uniform vec3 light1_specular;
9: uniform vec3 light1_halfVector;
10: uniform vec3 eyePosition;
11: varying vec2 diffTexCoord;
12: varying vec2 nightTexCoord;
13: uniform float textureOffset;
14: uniform vec3 atmosphereRadius;
15: uniform float mieCoeff;
16: uniform float mieH;
17: uniform float mieK;
18: uniform vec3 rayleighCoeff;
19: uniform float rayleighH;
20: uniform vec3 scatterCoeffSum;
21: uniform vec3 invScatterCoeffSum;
22: uniform vec3 extinctionCoeff;
23: vec3 eyeDir = normalize(eyePosition - gl_Vertex.xyz);
24: float NV = dot(gl_Normal, eyeDir);
25: varying vec4 diffFactors;
26: varying vec3 normal;
27: varying vec3 lightHalfVec0;
28: varying vec3 lightHalfVec1;
29: varying vec3 scatterEx;
30:
31: void main(void)
32: {
33: float NL;
34: normal = gl_Normal;
35: NL = max(0.0, dot(gl_Normal, light0_direction));
36: diffFactors.x = NL;
37: lightHalfVec0 = light0_direction + eyeDir;
38: NL = max(0.0, dot(gl_Normal, light1_direction));
39: diffFactors.y = NL;
40: lightHalfVec1 = light1_direction + eyeDir;
41: diffTexCoord = gl_MultiTexCoord0.st + vec2(textureOffset, 0.0);
42: nightTexCoord = gl_MultiTexCoord1.st;
43: {
44: float rq = dot(eyePosition, eyeDir);
45: float qq = dot(eyePosition, eyePosition) - atmosphereRadius.y;
46: float d = sqrt(rq * rq - qq);
47: vec3 atmEnter = eyePosition + min(0.0, (-rq + d)) * eyeDir;
48: vec3 atmLeave = gl_Vertex.xyz;
49: vec3 atmSamplePoint = (atmEnter + atmLeave) * 0.5;
50: vec3 atmSamplePointSun = atmEnter * 0.5 + atmLeave * 0.5;
51: rq = dot(atmSamplePointSun, light0_direction);
52: qq = dot(atmSamplePointSun, atmSamplePointSun) - atmosphereRadius.y;
53: d = sqrt(rq * rq - qq);
54: float distSun = -rq + d;
55: float distAtm = length(atmEnter - atmLeave);
56: float density = 0.0;
57: atmSamplePoint = atmEnter * 0.333 + atmLeave * 0.667;
58: float h = max(0.0, length(atmSamplePoint) - atmosphereRadius.z);
59: density += exp(-h * mieH);
60: atmSamplePoint = atmEnter * 0.667 + atmLeave * 0.333;
61: h = max(0.0, length(atmSamplePoint) - atmosphereRadius.z);
62: density += exp(-h * mieH);
63: vec3 sunColor = exp(-extinctionCoeff * density * distSun);
64: vec3 ex = exp(-extinctionCoeff * density * distAtm);
65: float cosTheta = dot(eyeDir, light0_direction);
66: float phMie = (1.0 - mieK * mieK) / ((1.0 - mieK * cosTheta) * (1.0 - mieK * cosTheta));
67: float phRayleigh = 1.0;
68: scatterEx = ex;
69: gl_FrontSecondaryColor.rgb = (phRayleigh * rayleighCoeff + phMie * mieCoeff) * invScatterCoeffSum * sunColor * (1.0 - exp(-scatterCoeffSum * density * distAtm));
70: }
71: gl_Position = ftransform();
72: }

Error compiling vertex shader:
(1) : error C0104: Unknown pre-processor directive #version
Fragment shader source:
1: #version 110
2: uniform sampler2D diffTex;
3: uniform sampler2D nightTex;
4: varying vec2 diffTexCoord;
5: varying vec2 nightTexCoord;
6: uniform vec3 ambientColor;
7: uniform float opacity;
8: varying vec4 diffFactors;
9: vec4 diff = vec4(ambientColor, opacity);
10: varying vec3 normal;
11: vec4 spec = vec4(0.0);
12: uniform float shininess;
13: varying vec3 lightHalfVec0;
14: uniform vec3 lightcolor0;
15: uniform vec3 lightspecColor0;
16: varying vec3 lightHalfVec1;
17: uniform vec3 lightcolor1;
18: uniform vec3 lightspecColor1;
19: varying vec3 scatterEx;
20:
21: void main(void)
22: {
23: vec4 color;
24: float NH;
25: vec3 n = normalize(normal);
26: diff.rgb += diffFactors.x * lightcolor0;
27: NH = max(0.0, dot(n, normalize(lightHalfVec0)));
28: spec.rgb += diffFactors.x * pow(NH, shininess) * lightspecColor0;
29: diff.rgb += diffFactors.y * lightcolor1;
30: NH = max(0.0, dot(n, normalize(lightHalfVec1)));
31: spec.rgb += diffFactors.y * pow(NH, shininess) * lightspecColor1;
32: color = texture2D(diffTex, diffTexCoord.st);
33: gl_FragColor = color * diff + float(color.a) * spec;
34: float totalLight = diffFactors.x + diffFactors.y;
35: totalLight = 1.0 - totalLight;
36: totalLight = totalLight * totalLight * totalLight * totalLight;
37: gl_FragColor += texture2D(nightTex, nightTexCoord.st) * totalLight;
38: gl_FragColor.rgb = gl_FragColor.rgb * scatterEx + gl_SecondaryColor.rgb;
39: }

Error compiling fragment shader:
(1) : error C0104: Unknown pre-processor directive #version
Vertex shader source:
1: #version 110
2: uniform vec3 light0_direction;
3: uniform vec3 light0_diffuse;
4: uniform vec3 light0_specular;
5: uniform vec3 light0_halfVector;
6: uniform vec3 light1_direction;
7: uniform vec3 light1_diffuse;
8: uniform vec3 light1_specular;
9: uniform vec3 light1_halfVector;
10: uniform vec3 eyePosition;
11: varying vec2 diffTexCoord;
12: uniform float textureOffset;
13: uniform vec3 atmosphereRadius;
14: uniform float mieCoeff;
15: uniform float mieH;
16: uniform float mieK;
17: uniform vec3 rayleighCoeff;
18: uniform float rayleighH;
19: uniform vec3 scatterCoeffSum;
20: uniform vec3 invScatterCoeffSum;
21: uniform vec3 extinctionCoeff;
22: vec3 eyeDir = normalize(eyePosition - gl_Vertex.xyz);
23: float NV = dot(gl_Normal, eyeDir);
24: uniform vec3 ambientColor;
25: uniform float opacity;
26: varying vec4 diff;
27: varying vec3 scatterEx;
28:
29: void main(void)
30: {
31: float NL;
32: diff = vec4(ambientColor, opacity);
33: NL = max(0.0, dot(gl_Normal, light0_direction));
34: diff.rgb += light0_diffuse * NL;
35: NL = max(0.0, dot(gl_Normal, light1_direction));
36: diff.rgb += light1_diffuse * NL;
37: diffTexCoord = gl_MultiTexCoord0.st + vec2(textureOffset, 0.0);
38: {
39: float rq = dot(eyePosition, eyeDir);
40: float qq = dot(eyePosition, eyePosition) - atmosphereRadius.y;
41: float d = sqrt(rq * rq - qq);
42: vec3 atmEnter = eyePosition + min(0.0, (-rq + d)) * eyeDir;
43: vec3 atmLeave = gl_Vertex.xyz;
44: vec3 atmSamplePoint = (atmEnter + atmLeave) * 0.5;
45: vec3 atmSamplePointSun = atmEnter * 0.5 + atmLeave * 0.5;
46: rq = dot(atmSamplePointSun, light0_direction);
47: qq = dot(atmSamplePointSun, atmSamplePointSun) - atmosphereRadius.y;
48: d = sqrt(rq * rq - qq);
49: float distSun = -rq + d;
50: float distAtm = length(atmEnter - atmLeave);
51: float density = 0.0;
52: atmSamplePoint = atmEnter * 0.333 + atmLeave * 0.667;
53: float h = max(0.0, length(atmSamplePoint) - atmosphereRadius.z);
54: density += exp(-h * mieH);
55: atmSamplePoint = atmEnter * 0.667 + atmLeave * 0.333;
56: h = max(0.0, length(atmSamplePoint) - atmosphereRadius.z);
57: density += exp(-h * mieH);
58: vec3 sunColor = exp(-extinctionCoeff * density * distSun);
59: vec3 ex = exp(-extinctionCoeff * density * distAtm);
60: float cosTheta = dot(eyeDir, light0_direction);
61: float phMie = (1.0 - mieK * mieK) / ((1.0 - mieK * cosTheta) * (1.0 - mieK * cosTheta));
62: float phRayleigh = 1.0;
63: scatterEx = ex;
64: gl_FrontSecondaryColor.rgb = (phRayleigh * rayleighCoeff + phMie * mieCoeff) * invScatterCoeffSum * sunColor * (1.0 - exp(-scatterCoeffSum * density * distAtm));
65: }
66: gl_Position = ftransform();
67: }

Error compiling vertex shader:
(1) : error C0104: Unknown pre-processor directive #version
Fragment shader source:
1: #version 110
2: uniform sampler2D diffTex;
3: varying vec2 diffTexCoord;
4: varying vec4 diff;
5: varying vec3 scatterEx;
6:
7: void main(void)
8: {
9: vec4 color;
10: color = texture2D(diffTex, diffTexCoord.st);
11: gl_FragColor = color * diff;
12: gl_FragColor.rgb = gl_FragColor.rgb * scatterEx + gl_SecondaryColor.rgb;
13: }

Error compiling fragment shader:
(1) : error C0104: Unknown pre-processor directive #version
Vertex shader source:
1: #version 110
2: uniform vec3 light0_direction;
3: uniform vec3 light0_diffuse;
4: uniform vec3 light0_specular;
5: uniform vec3 light0_halfVector;
6: uniform vec3 light1_direction;
7: uniform vec3 light1_diffuse;
8: uniform vec3 light1_specular;
9: uniform vec3 light1_halfVector;
10: uniform vec3 eyePosition;
11: uniform vec3 atmosphereRadius;
12: uniform float mieCoeff;
13: uniform float mieH;
14: uniform float mieK;
15: uniform vec3 rayleighCoeff;
16: uniform float rayleighH;
17: uniform vec3 scatterCoeffSum;
18: uniform vec3 invScatterCoeffSum;
19: uniform vec3 extinctionCoeff;
20: varying vec3 scatteredColor0;
21: varying vec3 scatteredColor1;
22: vec3 eyeDir = normalize(eyePosition - gl_Vertex.xyz);
23: float NV = dot(gl_Normal, eyeDir);
24: varying vec3 scatterEx;
25: varying vec3 eyeDir_obj;
26:
27: void main(void)
28: {
29: float NL;
30: {
31: float rq = dot(eyePosition, eyeDir);
32: float qq = dot(eyePosition, eyePosition) - atmosphereRadius.y;
33: float d = sqrt(rq * rq - qq);
34: vec3 atmEnter = eyePosition + min(0.0, (-rq + d)) * eyeDir;
35: vec3 atmLeave = gl_Vertex.xyz;
36: vec3 atmSamplePoint = (atmEnter + atmLeave) * 0.5;
37: vec3 atmSamplePointSun = atmEnter * 0.5 + atmLeave * 0.5;
38: rq = dot(atmSamplePointSun, light0_direction);
39: qq = dot(atmSamplePointSun, atmSamplePointSun) - atmosphereRadius.y;
40: d = sqrt(rq * rq - qq);
41: float distSun = -rq + d;
42: float distAtm = length(atmEnter - atmLeave);
43: float density = 0.0;
44: atmSamplePoint = atmEnter * 0.333 + atmLeave * 0.667;
45: float h = max(0.0, length(atmSamplePoint) - atmosphereRadius.z);
46: density += exp(-h * mieH);
47: atmSamplePoint = atmEnter * 0.667 + atmLeave * 0.333;
48: h = max(0.0, length(atmSamplePoint) - atmosphereRadius.z);
49: density += exp(-h * mieH);
50: vec3 sunColor = exp(-extinctionCoeff * density * distSun);
51: vec3 ex = exp(-extinctionCoeff * density * distAtm);
52: scatterEx = ex;
53: scatteredColor0 = sunColor * (1.0 - exp(-scatterCoeffSum * density * distAtm));
54: }
55: eyeDir_obj = eyeDir;
56: gl_Position = ftransform();
57: }

Error compiling vertex shader:
(1) : error C0104: Unknown pre-processor directive #version
Fragment shader source:
1: #version 110
2: varying vec3 scatterEx;
3: varying vec3 eyeDir_obj;
4: uniform float mieK;
5: uniform float mieCoeff;
6: uniform vec3 rayleighCoeff;
7: uniform vec3 invScatterCoeffSum;
8: uniform vec3 light0_direction;
9: varying vec3 scatteredColor0;
10: uniform vec3 light1_direction;
11: varying vec3 scatteredColor1;
12:
13: void main(void)
14: {
15: vec3 color = vec3(0.0, 0.0, 0.0);
16: vec3 V = normalize(eyeDir_obj);
17: float cosTheta = dot(V, light0_direction);
18: float phMie = (1.0 - mieK * mieK) / ((1.0 - mieK * cosTheta) * (1.0 - mieK * cosTheta));
19: float phRayleigh = 1.0;
20: color += (phRayleigh * rayleighCoeff + phMie * mieCoeff) * invScatterCoeffSum * scatteredColor0;
21: float cosTheta = dot(V, light1_direction);
22: float phMie = (1.0 - mieK * mieK) / ((1.0 - mieK * cosTheta) * (1.0 - mieK * cosTheta));
23: float phRayleigh = 1.0;
24: color += (phRayleigh * rayleighCoeff + phMie * mieCoeff) * invScatterCoeffSum * scatteredColor1;
25: gl_FragColor = vec4(color, dot(scatterEx, vec3(0.333, 0.333, 0.333)));
26: }

Error compiling fragment shader:
(1) : error C0104: Unknown pre-processor directive #version
(21) : error C1002: the name "cosTheta" is already defined
(21) : error C1054: initialization of non-variable "cosTheta"
(22) : error C1002: the name "phMie" is already defined
(22) : error C1054: initialization of non-variable "phMie"
(23) : error C1002: the name "phRayleigh" is already defined
(23) : error C1054: initialization of non-variable "phRayleigh"
Terraformed Pluto: Now with New Horizons maps! :D

Avatar
Hungry4info
Posts: 1133
Joined: 11.09.2005
With us: 18 years 7 months
Location: Indiana, United States

Post #12by Hungry4info » 24.05.2007, 22:41

Some errors I have found so far:

81 Cancri system a bit buggy. (Odd star binary)
9 Pup sysgem a bit buggy. (Odd star binary)
There may be more such systems.

GX And system's orbital period (both stars) is about 2,500 years. Is that accurate? (Might not be an error)



Furthermore, may I assume we settled on no atmospheres for stars?
And if so, can somebody tell me how I can add them myself?
Current Setup:
Windows 7 64 bit. Celestia 1.6.0.
AMD Athlon Processor, 1.6 Ghz, 3 Gb RAM
ATI Radeon HD 3200 Graphics

Topic author
chris
Site Admin
Posts: 4211
Joined: 28.01.2002
With us: 22 years 2 months
Location: Seattle, Washington, USA

Post #13by chris » 24.05.2007, 23:16

Error compiling fragment shader:
(1) : error C0104: Unknown pre-processor directive #version
Vertex shader source:
1: #version 110


I'm concerned about this . . . The #version directive is legal GLSL, and in fact is required in order to use the exp() function in shaders. I added in pre3 as part of my effort to make Celestia's shaders strictly conformant. Do you have very old drivers installed?

--Chris

Avatar
PlutonianEmpire M
Posts: 1374
Joined: 09.09.2004
Age: 39
With us: 19 years 7 months
Location: MinneSNOWta
Contact:

Post #14by PlutonianEmpire » 24.05.2007, 23:28

chris wrote:
Error compiling fragment shader:
(1) : error C0104: Unknown pre-processor directive #version
Vertex shader source:
1: #version 110

I'm concerned about this . . . The #version directive is legal GLSL, and in fact is required in order to use the exp() function in shaders. I added in pre3 as part of my effort to make Celestia's shaders strictly conformant. Do you have very old drivers installed?

--Chris

possibly. i got this dell inspiron 8600 laptop in january 2004, with a nvidia gforce fx go5200 vid card.
Terraformed Pluto: Now with New Horizons maps! :D

Dollan
Posts: 1150
Joined: 18.12.2003
Age: 54
With us: 20 years 4 months
Location: Havre, Montana

Post #15by Dollan » 25.05.2007, 05:14

It seems to work fine for me, except when I turn on the Nebulae. Then the whole program completely crashes.

Where should I look to determine the problem? Should I post my shaders log?

...John...
"To make an apple pie from scratch, you must first create the universe..."
--Carl Sagan

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

Post #16by t00fri » 25.05.2007, 06:18

Hungry4info wrote:Some errors I have found so far:

81 Cancri system a bit buggy. (Odd star binary)
9 Pup sysgem a bit buggy. (Odd star binary)
There may be more such systems.

GX And system's orbital period (both stars) is about 2,500 years. Is that accurate? (Might not be an error)



Furthermore, may I assume we settled on no atmospheres for stars?
And if so, can somebody tell me how I can add them myself?


Many thanks for reporting this. You spotted 2 further binaries the orbits of which have both been determined visually (visualbins.stc) and spectroscopically (spectbins.stc) .

81 Cnc has another name in Spectbins: Fin 347Aa
and hence was particularly hard to find

But again these two are nice examples are demonstrating the high accuracy of the orbit determination: The double orbits are quite close together!

I will try to find out which one of the doubles is perhaps a bit more accurate...


Bye Fridger
Image

Topic author
chris
Site Admin
Posts: 4211
Joined: 28.01.2002
With us: 22 years 2 months
Location: Seattle, Washington, USA

Post #17by chris » 25.05.2007, 18:16

Dollan wrote:It seems to work fine for me, except when I turn on the Nebulae. Then the whole program completely crashes.

Where should I look to determine the problem? Should I post my shaders log?

...John...


Strange. Shaders.log may or may not help in this case. What kind of computer are you using? Also, it would be very helpful if you could isolate the particular nebula add-on that's causing the crash--is it any nebula add-on, or some particular one?

--Chris

Dollan
Posts: 1150
Joined: 18.12.2003
Age: 54
With us: 20 years 4 months
Location: Havre, Montana

Post #18by Dollan » 25.05.2007, 22:09

Hi Chris...

My computer is a Dual Core 3.4Ghz with 1GB of RAM, and a Radeon X1600 vid card with 256MB.

The nebula add-on, which worked fine in the previous pre-version, is a usage of multiple incidences of Selden's graticules add-on. Here's a screen shot: http://farm1.static.flickr.com/228/4953 ... 3550_o.png The add-on caused no problems before, and didn't even slow the program down.

The only other nebula add-on that I have is this one: http://celestiamotherlode.net/catalog/s ... don_id=899

<edit> I just tested the program with both, then only one, of those add-ons. It is definitely the graticule add-on which causes the crash. I don't know if it helps or not, but the cursor flickers whenever that add-on is enabled... just before the program tanks.

I also tested it again on the pre2 version, just to be certain, and it works just fine.

...John...
"To make an apple pie from scratch, you must first create the universe..."
--Carl Sagan

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

Post #19by selden » 26.05.2007, 09:53

John,

Unfortunately, you're going to have to provide a copy of the Addon that causes the crash.

I am unable to cause Celestia to crash with the versions of the OA dominion maps that I have, but they are quite different from what you're showing. I have an Nvidia card, too. It's my guess that something in the AMD/ATI graphics drivers is unhappy with the new code.
Selden

Paolo
Posts: 502
Joined: 23.09.2002
With us: 21 years 7 months
Location: Pordenone/Italy

Post #20by Paolo » 26.05.2007, 10:24

Downloaded, tested. On my system with win XP, everything seems ok.

But please! please , please for 1.5.0 final include some improved textures in the default package. A size of 45-60 MB should be not really a big of problem nowadays.

New textures at least for Earth, Moon and Mars both with normalmaps, cloud and specular maps.

An example of VT with a choice in the guided tour combo box.

Or pack 2 versions 1 basic and one with improved textures. The choice is yours.

Another thing should be useful IMHO. The capability of switching between languages using the UI.

Kind regards
Remember: Time always flows, it is the most precious thing that we have.
My Celestia - Celui


Return to “Celestia Users”