Parameters defining the walnut tree canopy. More...
#include <CanopyGenerator.h>
Public Member Functions | |
WalnutCanopyParameters () | |
Default constructor. | |
WalnutCanopyParameters (const pugi::xml_node canopy_node) | |
void | readParametersFromXML (const pugi::xml_node canopy_node) |
Sets canopy parameters from the given XML node. | |
void | buildPlant (CanopyGenerator &canopy_generator, helios::vec3 origin) override |
Makes the given Canopy generator build a single plant of our canopy type with our parameters at the given position. | |
void | buildCanopy (CanopyGenerator &canopy_generator) override |
Makes the given Canopy generator build a canopy of our type with our parameters. | |
![]() | |
BaseCanopyParameters () | |
Default constructor. | |
BaseCanopyParameters (const pugi::xml_node canopy_node) | |
void | readParametersFromXML (const pugi::xml_node canopy_node) |
Sets canopy parameters from the given XML node. | |
Data Fields | |
float | leaf_length |
Maximum length of leaves along midrib. | |
helios::int2 | leaf_subdivisions |
Number of sub-division segments per leaf. | |
std::string | leaf_texture_file |
Path to texture map file for leaves. | |
std::string | wood_texture_file |
Path to texture map file for wood/branches. | |
int | wood_subdivisions |
Number of radial subdivisions for branch tubes. | |
float | trunk_radius |
Radius of trunk. | |
float | trunk_height |
Height of the trunk. | |
helios::vec3 | branch_length |
Average length of branches in each recursive branch level. For example, the first (.x) value is the length of branches emanating from the trunk, the second (.y) is the the length of branches emanating from the first branching level. | |
float | plant_spacing |
Spacing between adjacent plants along the row direction. | |
float | row_spacing |
Spacing between plant rows. | |
float | fruit_radius |
Radius of walnuts. | |
std::string | fruit_texture_file |
Texture map for walnut fruit. | |
uint | fruit_subdivisions |
Number of azimuthal and zenithal subdivisions making up fruit (will result in roughly fruit_subdivisions^2 triangles per fruit) | |
helios::int2 | plant_count |
Number of crowns/plants in the x- and y-directions. | |
![]() | |
helios::vec3 | canopy_origin |
Cartesian (x,y,z) coordinate of the bottom center point of the canopy (i.e., specifying z=0 places the bottom surface of the canopy at z=0). | |
float | canopy_rotation |
Azimuthal rotation of the canopy about the canopy origin. Note that if canopy_rotation is not equal to zero, the plant_spacing and plant_count parameters are defined in the x- and y-directions before rotation. | |
Parameters defining the walnut tree canopy.
Definition at line 684 of file CanopyGenerator.h.
WalnutCanopyParameters::WalnutCanopyParameters | ( | ) |
Default constructor.
Definition at line 1190 of file CanopyGenerator.cpp.
WalnutCanopyParameters::WalnutCanopyParameters | ( | const pugi::xml_node | canopy_node | ) |
[in] | canopy_node | XML node containing the canopy parameters |
Definition at line 1221 of file CanopyGenerator.cpp.
|
overridevirtual |
Makes the given Canopy generator build a canopy of our type with our parameters.
Implements BaseCanopyParameters.
Definition at line 1294 of file CanopyGenerator.cpp.
|
overridevirtual |
Makes the given Canopy generator build a single plant of our canopy type with our parameters at the given position.
Implements BaseCanopyParameters.
Definition at line 1290 of file CanopyGenerator.cpp.
void WalnutCanopyParameters::readParametersFromXML | ( | const pugi::xml_node | canopy_node | ) |
Sets canopy parameters from the given XML node.
[in] | canopy_node | XML node containing the canopy parameters |
Definition at line 1225 of file CanopyGenerator.cpp.
helios::vec3 WalnutCanopyParameters::branch_length |
Average length of branches in each recursive branch level. For example, the first (.x) value is the length of branches emanating from the trunk, the second (.y) is the the length of branches emanating from the first branching level.
Definition at line 728 of file CanopyGenerator.h.
float WalnutCanopyParameters::fruit_radius |
Radius of walnuts.
Definition at line 738 of file CanopyGenerator.h.
uint WalnutCanopyParameters::fruit_subdivisions |
Number of azimuthal and zenithal subdivisions making up fruit (will result in roughly fruit_subdivisions^2 triangles per fruit)
Definition at line 744 of file CanopyGenerator.h.
std::string WalnutCanopyParameters::fruit_texture_file |
Texture map for walnut fruit.
Definition at line 741 of file CanopyGenerator.h.
float WalnutCanopyParameters::leaf_length |
Maximum length of leaves along midrib.
Definition at line 707 of file CanopyGenerator.h.
helios::int2 WalnutCanopyParameters::leaf_subdivisions |
Number of sub-division segments per leaf.
Definition at line 710 of file CanopyGenerator.h.
std::string WalnutCanopyParameters::leaf_texture_file |
Path to texture map file for leaves.
Definition at line 713 of file CanopyGenerator.h.
helios::int2 WalnutCanopyParameters::plant_count |
Number of crowns/plants in the x- and y-directions.
Definition at line 747 of file CanopyGenerator.h.
float WalnutCanopyParameters::plant_spacing |
Spacing between adjacent plants along the row direction.
Definition at line 732 of file CanopyGenerator.h.
float WalnutCanopyParameters::row_spacing |
Spacing between plant rows.
Definition at line 735 of file CanopyGenerator.h.
float WalnutCanopyParameters::trunk_height |
Height of the trunk.
Definition at line 725 of file CanopyGenerator.h.
float WalnutCanopyParameters::trunk_radius |
Radius of trunk.
Definition at line 722 of file CanopyGenerator.h.
int WalnutCanopyParameters::wood_subdivisions |
Number of radial subdivisions for branch tubes.
Definition at line 719 of file CanopyGenerator.h.
std::string WalnutCanopyParameters::wood_texture_file |
Path to texture map file for wood/branches.
Definition at line 716 of file CanopyGenerator.h.