2012-04-09 19:58:08 +00:00
|
|
|
#ifndef _PAYSAGES_VEGETATION_H_
|
|
|
|
#define _PAYSAGES_VEGETATION_H_
|
|
|
|
|
2012-04-22 17:12:39 +00:00
|
|
|
#include "pack.h"
|
2012-04-09 19:58:08 +00:00
|
|
|
#include "zone.h"
|
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#define VEGETATION_MAX_LAYERS 50
|
|
|
|
|
|
|
|
typedef struct
|
|
|
|
{
|
|
|
|
Zone* zone;
|
|
|
|
double max_height;
|
|
|
|
} VegetationLayerDefinition;
|
|
|
|
|
|
|
|
typedef struct VegetationDefinition VegetationDefinition;
|
|
|
|
|
|
|
|
void vegetationInit();
|
|
|
|
void vegetationQuit();
|
2012-04-22 17:12:39 +00:00
|
|
|
void vegetationSave(PackStream* stream, VegetationDefinition* definition);
|
|
|
|
void vegetationLoad(PackStream* stream, VegetationDefinition* definition);
|
2012-04-09 19:58:08 +00:00
|
|
|
|
|
|
|
VegetationDefinition* vegetationCreateDefinition();
|
|
|
|
void vegetationDeleteDefinition(VegetationDefinition* definition);
|
|
|
|
void vegetationCopyDefinition(VegetationDefinition* source, VegetationDefinition* destination);
|
|
|
|
void vegetationValidateDefinition(VegetationDefinition* definition);
|
|
|
|
|
|
|
|
VegetationLayerDefinition vegetationLayerCreateDefinition();
|
|
|
|
void vegetationLayerDeleteDefinition(VegetationLayerDefinition* definition);
|
|
|
|
void vegetationLayerCopyDefinition(VegetationLayerDefinition* source, VegetationLayerDefinition* destination);
|
|
|
|
void vegetationLayerValidateDefinition(VegetationLayerDefinition* definition);
|
|
|
|
|
|
|
|
int vegetationGetLayerCount(VegetationDefinition* definition);
|
|
|
|
int vegetationGetLayer(VegetationDefinition* definition, int position, VegetationLayerDefinition* layer);
|
|
|
|
int vegetationSetLayer(VegetationDefinition* definition, int position, VegetationLayerDefinition* layer);
|
|
|
|
int vegetationAddLayer(VegetationDefinition* definition);
|
|
|
|
void vegetationDeleteLayer(VegetationDefinition* definition, int layer);
|
|
|
|
|
|
|
|
/*double vegetationGetLayerCoverage(TextureLayerDefinition* definition, Renderer* renderer, Vector3 location, double detail);*/
|
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#endif
|