Functions that currently exist:
Comet(), ~Comet(), getInfoString(), getVMagnitude(), setAbsoluteMagnitudeAndSlope()
Plan for the next 7 weeks:
= = = Comet.cpp = for comet representation
antiSunDirection()
- for getting plasma tail and dust tail directions
- dust tail direction calculation will be indirect (sum with comet's velocity vector)
dustTailDensity()
- Calculate via physical equation
- GL Blend to create fade away effect and since tails are quite translucent
dustTail()
- Rate of flow equations/ heliocentric distance for size of tail
- A parabola in a plane
- Calculate solar color? Or just 1 solar color
- uses dustTailDensity() and effectiveJetDirection()
seeDustTail() // observer's view of tail
- according to angle (i.e. head-on: fan; side-on: line)
- parallax for antitail
- bool dead or alive (by heliocentric distance)
coma()
- magnitude according to heliocentric distance
- shape more elliptical as it gets closer
- GL Blend(one, one) with dust tail
ionTail()
- cone // if not efficient enough, then use parabola
- streaky blue texture bind
- GL Blend for fading to let most of the stars behind it visible
- GL Blend to let dust tail take precedence
- length by heliocentric distance
- offset angle by 3 degrees
- bool dead or alive (by heliocentric distance)
projectorOntoPlanetView()
// same function as in StelSkyDrawer.cpp, but customized for comet since not Planet
postDrawSky3dModelComet()
- mip maps? Far away, comet looks like blurry oval. Near, level of detail is much higher
- transform with respect to viewer
effectiveJetDirection()
- Some angle ~45 degrees
- antiSunDirection() + velocityOfComet()
// not actual velocity, just easier to think about it like this for calculating effectiveJetDirection()
velocityOfComet()
- tangent to orbit path, a.k.a. velocity of comet (parallel to orbit's tangent)
period()
heliocentricDistance()
= = = Sky Tab
cometBurst()
- since bursts are random and nigh unpredictable, the viewer can control this. With a comet selected, adjusting a slider in Sky Tab will increase (a.k.a make more negative) the magnitude
= = = Misc.
Could potentially have a Tail class, since there is overlapping direction, blend, texture bind and heliocentric distance considerations. Then the functions ionTail(), dustTail() and dustTailDensity() would instead be:
Tail()
- texture()
- blendWithSky()
- blendTails()
DustTail(): public Tail
- parabola body (deformation and axis determined using effectiveJetDirection)
- dustTailDensity()
- texture bind to parabola
- size() // by rate of flow equations and heliocentric distance
IonTail(): public Tail
- cone body (axis determined using antiSunDirection)
- texture bind of blue streams/streaks to cone
- size() // a.k.a. length by heliocentric distance
I think projectorOntoEarthView() more correct will be renamed to projectorOntoPlanetView()
ReplyDeleteOk, have changed it. Thanks!
Delete