atorkhov
08-01-2009 08:55:38
First, following code in PointStarfield::ensureGeometry could be replaced with call of CaelumSystem::makeDirection():
And second, I'm suggesting to add custom parameter, like "CoordinateSystemRotation" that would be added to azimuth in CaelumSystem::makeDirection.
It will ease integration of Caelum with existing systems. For example, in our game client Z axis was pointing south, but Caelum's Z pointing towards north, so we had to change Caelum's sources a bit to accommodate this.
Ogre::Vector3 pos;
pos.z = -Math::Cos (Ogre::Degree(azm)) * Math::Cos (Ogre::Degree(alt));
pos.x = Math::Sin (Ogre::Degree(azm)) * Math::Cos (Ogre::Degree(alt));
pos.y = -Math::Sin (Ogre::Degree(alt));
And second, I'm suggesting to add custom parameter, like "CoordinateSystemRotation" that would be added to azimuth in CaelumSystem::makeDirection.
It will ease integration of Caelum with existing systems. For example, in our game client Z axis was pointing south, but Caelum's Z pointing towards north, so we had to change Caelum's sources a bit to accommodate this.