Skip to content

Latest commit

 

History

History
55 lines (37 loc) · 2.79 KB

README_linux.md

File metadata and controls

55 lines (37 loc) · 2.79 KB

prt4cmd - CityEngine SDK Command Line Utility

Disclaimer

This is an example for using the CityEngine SDK. There is no support for this application. If you find a bug or want to enhance functionality you have to do this yourself.

Prerequisites

Before you start working with this example, please make sure you follow the main installation instructions for the CityEngine SDK in the README.md file at the root of this example repository. This will explain how to get the sdk binaries and example data.

Software Requirements

  • See "General Software Requirements" (Linux)

Build Instructions

  1. Open a terminal (e.g. bash)
  2. Change into the example directory: cd <your path to>/cityengine-sdk/examples/prt4cmd
  3. Prepare build directory: mkdir build && cd build
  4. Run cmake: cmake ../src
  5. Compile: make install
  6. The build result will appear in a install directory in parallel to the build directory.

Using prt4cmd

  1. Open a bash shell and cd in to the above install directory

  2. Type bin/prt4cmd -h to see the list of options.

  3. Type the following to generate the "candler" building model in the wavefront obj format:

    bin/prt4cmd -l 3 -g ../../../data/candler_footprint.obj -p ../../../data/candler.rpk -a ruleFile:string=bin/candler.cgb -a startRule:string=Default\$Footprint -e com.esri.prt.codecs.OBJEncoder -z baseName:string=theCandler
    
  4. The result is placed in a new output directory inside the install directory:

    • theCandler_0.obj
    • theCandler.mtl
    • Bunch of texture files
  5. To regenerate the same model with a different height, use the following command (note the additional -a BuildingHeight... statement):

    bin/prt4cmd -l 3 -g ../../../data/candler_footprint.obj -p ../../../data/candler.rpk -a ruleFile:string=bin/candler.cgb -a startRule:string=Default\$Footprint -a BuildingHeight:float=30 -e com.esri.prt.codecs.OBJEncoder -z baseName:string=theCandler
    
  6. The obj file will now contain a model which is 30m high instead of the default 62m.

Licensing

The CityEngine SDK is free for personal, educational, and non-commercial use. Commercial use requires at least one commercial license of the latest CityEngine version installed in the organization. Redistribution or web service offerings are not allowed unless expressly permitted.

The CityEngine SDK is licensed under the Esri Terms of Use: