What field is the Plant_Loader Rule looking for for "Name"?

1760
3
Jump to solution
02-03-2016 03:22 PM
JayGeisen
New Contributor III

Hi,

I'm using the Plant_Loader rule that comes with CityEngine. My height seems to be coming across properly, but name is defaulting to "Orange Tree" for all my trees. I'm guessing the name field I'm using in my data ("CommonName") does not match what the rule is expecting the name field to be. Can someone please tell me what field the rule is looking for so I can change my database accordingly? I've gone through the rule file, but can't seem to make out what it's looking for. Also, I have a "CrownWidth" field in my data. Is this what the rule is looking for to populate the "Radius"?

Thanks,
Jay

0 Kudos
1 Solution

Accepted Solutions
CherylLau
Esri Regular Contributor

I assume you want to set the attributes in the Plant Loader based on values you already have somewhere else.  Perhaps you have a set of shapes with object attributes that contain this info.  Yes, the names of your object attributes have to be the same as the attribute names in the rules.

According to the rules, the attribute Name will be set to "Orange Tree" by default.  This is a rule set attribute (because its value is determined by the rules).

This can be changed by manually setting the value for this attribute in the Inspector.  Then, the attribute becomes a user set value (indicated by bold font for the value of the attribute in the Inspector).

Or, another way to set the value of this attribute is to link it to an object attribute so that it gets its value from the object attribute of the same name.  I assume this is the option that you are looking for.  To do this, select your shapes, click on the icon (square with arrow) between the attribute name and the value field in the Inspector, select "Object Attribute".  This will make the attribute get its value from the object attribute of the same name.  Note that for this to work, the rule attribute has to have the same exact name as the object attribute.

View solution in original post

0 Kudos
3 Replies
CherylLau
Esri Regular Contributor

I assume you want to set the attributes in the Plant Loader based on values you already have somewhere else.  Perhaps you have a set of shapes with object attributes that contain this info.  Yes, the names of your object attributes have to be the same as the attribute names in the rules.

According to the rules, the attribute Name will be set to "Orange Tree" by default.  This is a rule set attribute (because its value is determined by the rules).

This can be changed by manually setting the value for this attribute in the Inspector.  Then, the attribute becomes a user set value (indicated by bold font for the value of the attribute in the Inspector).

Or, another way to set the value of this attribute is to link it to an object attribute so that it gets its value from the object attribute of the same name.  I assume this is the option that you are looking for.  To do this, select your shapes, click on the icon (square with arrow) between the attribute name and the value field in the Inspector, select "Object Attribute".  This will make the attribute get its value from the object attribute of the same name.  Note that for this to work, the rule attribute has to have the same exact name as the object attribute.

0 Kudos
by Anonymous User
Not applicable

Also, it might be good to know that the data in your field must match one of the values in the @Range list above the attr Name = "Orange Tree" in the CGA tule.

Regarding CrownWidth field in your database, there is a Radius attribute in the rule. If your crown width is the diameter of the crown, then you might add a field called Radius and put half of your CrownWidth into that field.

0 Kudos
JayGeisen
New Contributor III

Thank you both! The rule is looking for the name field to be called "Name" haha. I guess that makes sense.

Also, I've been noticing the tree library seems fairly West Coast-centric. Is that fair to say?  Do any of you know where one might find more tree models?

Thanks,

Jay

0 Kudos