Shared Samples

Try out source code samples stored in Bitbucket repositories.
Showing results for 
Search instead for 
Do you mean 

Job vectorRead

by Technical Evangelist on ‎09-08-2015 11:02 AM - edited on ‎03-29-2016 11:34 AM by Anonymous (717 Views)

Example Type

 

JOB

 

Purpose

 

This example shows how to read vector features such as arcs, polygons, tics and points from a vector layer.

 

Files

 

vectorRead.c (C source code)

vectorRead.eml (EML script)

vectorRead.dsp (Visual C++ Project)(Windows Only)

 

 

Description

 

The vectorRead example is intended to illustrate the following procedures:

  • how to open a vector layer,
  • how to read the descriptive information about that layer,
  • how to read the features (arc, polygons, points, tics) in the layer, and
  • How to read some attribute table data.

The results are written to a text file for later viewing.

This example demonstrates how to use the four major functions that retrieve information from the vector layer:

  1. readVectorLayer
  2. readVectorFeatures
  3. read AttributeTable
  4. describeVector Layer

 

 

 

Command Line Options

 

vectorread -in <inputfile> -out <outputfile> [-m <0|1>]

 

-in[put]

 This is the input vector that will be described.

 

-out[put]

 This is the output text file describing the vector layer.

 

-m

 Specifies whether or not to meter the process. 0 is no and 1 (default) is yes.

 

Interface

 demo.jpg

 

 

Output

This example produces an output text file that contains information about arcs, polygons, points and tics within the vector layer.

 

 

Notes

This program will print information about every feature and every attribute in the coverage, so please be aware that a large coverage may result in a large, unusable text file!

 

 

Source Code:

https://bitbucket.org/HGDN/hgdn_erdas_imagine/src/e1ade3b7d148b0f2f1aa6427044dfa4bce6226ee/Job_vecto...

 

Overview
Contributors