+ Reply to Thread
Results 1 to 5 of 5

Thread: Extrude shapefile according to height attribute

  1. #1
    Carl Bester
    Join Date
    Jan 2011
    Posts
    35
    Points
    0
    Answers Provided
    1


    0

    Default Extrude shapefile according to height attribute

    Hi,

    I have imported a shapefile into CityEngin and need to extrude the buildings according to an existing height attribute in the shapefile. For example: If there are 3 buildings with height values of 30; 70; 20. Then the buildings have to be extruded according to each one's value.
    Do I need to create an attribute which represents the height attribute for each specific shape? The height attribute is Building_height.

    attr z = Building_height
    Lot --> Shape extrude(z)

    Do I need to define the shapefile in the rule code?

    Any help will be greatly appreciated

  2. #2
    André Cardoso
    Join Date
    Oct 2011
    Posts
    69
    Points
    2
    Answers Provided
    0


    1

    Default Re: Extrude shapefile according to height attribute

    Time to give back to community

    Here are the steps:
    1- import the shapefile
    2- create a rule file and define an attribute with the same name as the one found on the shapefile
    3- associate the rule file to each shape imported onto the scene

    Look at the screens attached .

    After importing the shapefile and creating the rule which uses a attribute with the SAME name as the one found on the object attributes, you just have to make sure that the rule file is associated to the shapes, and that the attribute from the CGA is sourced to read its value from each shape's attributes.



    Quote Originally Posted by CBBester View Post
    Hi,

    I have imported a shapefile into CityEngin and need to extrude the buildings according to an existing height attribute in the shapefile. For example: If there are 3 buildings with height values of 30; 70; 20. Then the buildings have to be extruded according to each one's value.
    Do I need to create an attribute which represents the height attribute for each specific shape? The height attribute is Building_height.

    attr z = Building_height
    Lot --> Shape extrude(z)

    Do I need to define the shapefile in the rule code?

    Any help will be greatly appreciated
    Attached Thumbnails Attached Thumbnails Click image for larger version

Name:	1.png‎
Views:	451
Size:	128.5 KB
ID:	12349   Click image for larger version

Name:	2.jpg‎
Views:	512
Size:	82.1 KB
ID:	12350   Click image for larger version

Name:	3.jpg‎
Views:	446
Size:	84.4 KB
ID:	12351   Click image for larger version

Name:	4.jpg‎
Views:	420
Size:	77.3 KB
ID:	12352   Click image for larger version

Name:	5.jpg‎
Views:	390
Size:	102.2 KB
ID:	12353  


  3. #3
    Matthias Buehler

    Join Date
    Oct 2011
    Posts
    1,676
    Points
    438
    Answers Provided
    140


    0

    Default Re: Extrude shapefile according to height attribute

    @ Andre

    thanks for joining me on the support front !

    amazing, you're even using the @StartRule decoration !!!
    _________________

    CityEngine Machinist

    * YOUTUBE CHANNEL : www.youtube.com/channel/UCNS4TLgToEDQiH9pi06ofOA
    * tutorial videos : http://forums.arcgis.com/threads/648...URCES-FAQ-HELP
    * Please use the rating buttons on the right side !

  4. #4
    Carl Bester
    Join Date
    Jan 2011
    Posts
    35
    Points
    0
    Answers Provided
    1


    0

    Talking Re: Extrude shapefile according to height attribute

    Great!

    Thank you Andre! It worked.

  5. #5
    robert hughes
    Join Date
    Oct 2012
    Posts
    3
    Points
    0
    Answers Provided
    0


    0

    Default Re: Extrude shapefile according to height attribute

    brilliant, helped a lot, thank you soo much for this reply!

+ Reply to Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts