1
0
Fork 0

Merge branch 'next' of gitorious.org:fg/flightgear into next

This commit is contained in:
Curtis L. Olson 2010-12-18 12:05:28 -06:00
commit c396fae4a7
3 changed files with 36 additions and 37 deletions

View file

@ -52,7 +52,8 @@ FGClouds::FGClouds() :
update_event = 0;
}
FGClouds::~FGClouds() {
FGClouds::~FGClouds()
{
}
int FGClouds::get_update_event(void) const {
@ -186,7 +187,7 @@ double FGClouds::buildCloud(SGPropertyNode *cloud_def_root, SGPropertyNode *box_
return extent;
}
void FGClouds::buildLayer(int iLayer, const string& name, double alt, double coverage) {
void FGClouds::buildLayer(int iLayer, const string& name, double coverage) {
struct {
string name;
double count;
@ -305,6 +306,7 @@ void FGClouds::buildCloudLayers(void) {
coverage_norm = 8.0/8.0; // 8
string layer_type = "nn";
if( coverage == "cirrus" ) {
layer_type = "ci";
} else if( alt_ft > 16500 ) {
@ -335,7 +337,7 @@ void FGClouds::buildCloudLayers(void) {
}
cloud_root->setStringValue("layer-type",layer_type);
buildLayer(iLayer, layer_type, alt_m, coverage_norm);
buildLayer(iLayer, layer_type, coverage_norm);
}
}
@ -347,7 +349,8 @@ void FGClouds::set_3dClouds(bool enable)
}
}
bool FGClouds::get_3dClouds() const {
bool FGClouds::get_3dClouds() const
{
return clouds_3d_enabled;
}

View file

@ -34,17 +34,13 @@
using std::string;
class SGSampleGroup;
class SGCloudField;
class SGNewCloud;
class FGMetar;
//class FGEnvironmentCtrl;
class FGClouds {
private:
double buildCloud(SGPropertyNode *cloud_def_root, SGPropertyNode *box_def_root, const string& name, double grid_z_rand, SGCloudField *layer);
void buildLayer(int iLayer, const string& name, double alt, double coverage);
void buildLayer(int iLayer, const string& name, double coverage);
void buildCloudLayers(void);