>  Docs Center  >  Using ENVI  >  Vectors
ENVI

Vectors

Vectors

Vectors are points, multipoints, polylines, or polygons used to mark areas of interest within an image. Use the Vector toolbar buttons to work with vectors. For additional details on vectors, see Vector Records Background.

ENVI supports shapefiles (.shp, excluding Z and M polygons) and ENVI vector files (.evf). See Vector Auxiliary Files Background for a list and description of the auxiliary files that ENVI creates on your local drive when opening vector files for the first time.

See the following sections:

Create and Save a Vector Layer


  • Create a new layer by selecting File > New > Vector Layer from the menu bar.
  • Each layer may contain only one Record Type (for example, points).
  • You can select a Source Data file when creating an new layer to define the new layer’s extents and map projection using an existing file.
  • ENVI performs Real-Time Ortho for vector layers created on top of an RPC image. The vector layers will contain projected coordinates that can display with other projected imagery, and projected vector layers will display on top of an existing RPC image without reprojecting the RPC image.
  • When the layer has been modified, the icon next to the layer name in the Layer Manager becomes shaded Dirty vector layer icon. The icon shading is removed once the layer is saved.
  • Save layer changes by right-clicking in the Image window view and selecting Save.
  • Save layer changes to a new file by right-clicking in the Image window and selecting Save As. Also use Save As when saving a new vector layer for the first time.
  • Saving the new layer creates a new attribute table, which consists of the numeric attribute RECORD_ID.
  • To hide a vector layer in a view, disable the check box for that layer in the Layer Manager. To show the layer, enable the check box. Or, right-click on the View icon in the Layer Manager and select Show All Layers and Hide All Layers to show/hide all layers at once.
  • To rename a layer, right-click its name and select Rename Item. Enter the new name in the Rename Item dialog and press the Enter key to accept it or press the Esc key to cancel. (Linux and Macintosh users should click the green check icon to accept the new name or click the red X icon to cancel.)
  • To remove a vector layer from the Layer Manager, right-click on the layer and select Remove. This removes the layer from the Layer Manager, but the file remains open and you can access it for redisplay from the Data Manager.
  • If you have multiple views displayed, you can drag-and-drop vector layers from the Layer Manager to any one of those views in the display or to the corresponding view icons in the Layer Manager. This creates a copy of the layer(s) to populate the views.
  • To add a vector layer to a new view, right-click on a filename in the Data Manager and select Open Selected Dataset in New View.
  • Each time you open a new vector file, the layer appears at the top of the Layer Manager and becomes the selected layer. The purpose of a selected layer is to allow you to apply a display enhancement (transparency, etc.) to that layer only, without affecting other layers. To select a layer, click its name in the Layer Manager.
  • If an Esri® shapefile is open in both ArcMap™ and ENVI and you change that layer in ArcMap (for example, move vertices), you can refresh the layer in ENVI to see the changes. To refresh in ENVI, the layer must first be saved in ArcMap. Refresh with one of the following:

  • In the Layer Manager, right-click the Esri layer and select Refresh.
  • In the Data Manager, right-click the Esri layer and select Refresh.

    The layer closes and reopens. Refreshing the layer moves it to the top of the order in the Layer Manager. If you have multiple views of the Esri layer open in the Image window, the layer will close in all views that contain that it and reopen in the active view.

Add Vectors


  • In the active layer, click the Vectors drop-down on the toolbar and select Vector Create, then click on the image where you want to add the vector.
  • Create polygons or polylines by clicking and dragging to draw them, or click at intervals to add vertices one at a time.
  • Use the right-click menu options to accept vectors when they are drawn.
  • Multipoint vectors can be added only to a vector file that is designated a multipoint file.
  • Group or ungroup vectors by selecting them and using the right-click menu options.
  • Editing a vector layer with an associated attribute table does not change the existing attribute values. Depending on the type of edits you make, this may mean the values in that record are no longer valid.
  • Vector layers originating from a geodatabase or referenced by an Esri® layer are not editable; however, you can access and edit the source data for an Esri layer.

Edit or Delete Vectors


Vector edit or delete options include: deleting a record, moving a polyline or polygon vertex, adding or deleting a polyline or polygon vertex, grouping or ungrouping records. joining polylines, merging or splitting polylines or polygons, smoothing polygons, rectangulating polygons. and removing polygon holes.

  • To edit or delete polygon or polyline records in the active layer, click the Vectors drop-down on the toolbar and select Vector Edit.
  • To edit or delete points in the active layer, click the Vectors drop-down on the toolbar and select Vertex Edit.
  • Select a record by clicking on it.
  • Select multiple records by using Ctrl+click, or by clicking and dragging to draw a box around the records.
  • Use the right-click menu to choose edit or delete options for the selected record(s).

Change Properties for Vectors 


To change the properties of a vector layer, double-click the layer name in the Layer Manager or right-click and select Properties.

To edit the display properties for a given attribute, select an attribute name from the Select Attribute drop-down list. The Attribute Values section on the left side of the Vector Properties dialog lists the unique values for that attribute.

  • Use the top table to edit the display properties of a selected attribute.
  • The Fill Interior property is disabled for any polygon layer that is the active layer, when the Vector Edit or Vertex Edit tool is in use.
  • When you display a vector file for the first time, the Vector Properties dialog assigns a default fill color of red for all attributes.
  • To change the fill color for all values for the selected attribute, select the Solid Color option from the Color Table drop-down list. Otherwise, select different color options as needed. For example, you could assign different colors to different road types such as dirt, multi-lane, etc. A preview of the currently selected color table is displayed below the drop-down list.
  • For polygon shapefiles, if the Fill Interior property is set to True and you select an option from the Color Table drop-down list (besides Solid Color), the Line Color property in the top table is automatically set to black. You can change this if needed. If the Fill Interior property is set to False and you select a color table, the outlines of the polygons are colored according to the selected color table.
  • If the Fill Interior property is set to True for polygon shapefiles, the fill is temporary disabled if you use the Pan, Fly, or Rotate tools to move around the display.
  • If the attribute has more than 256 unique values, the selected color table is equally divided among the number of attributes, creating a color gradient. Select the Cycle Color Table option if you want the color table to repeat itself with each iteration of 256 unique values.
  • Click Apply to commit your changes to the Image window.

Attribute Values

To edit the display properties of a specific attribute value, select the value in the Attribute Values list. Use the bottom table to edit the color properties for that value.

Here are some tips for working with vector files that have more than 256 unique attribute values:

  • The Attribute Values list only shows 256 values at a time. Click the and buttons to navigate through pages of attribute values. Or, click the and buttons to go to the first or last page of values. The window to the right of the buttons indicates the range of records you are currently viewing.
  • Clicking the Attribute Value Index button displays a dialog that divides all of the unique attribute values into smaller categories, to help you quickly locate a specific attribute value. The following example shows unique "name" attribute values for world airports. In the Attribute Value Index dialog, suppose you want to find the Hong Kong International Airport. Click on the value before Hong Kong, which in this case is Halifax Int'l. The Attribute Value Index dialog shows a more detailed level of values that start with that selection. Click Hong Kong Int'l. At this point, you can edit the vector properties for Hong Kong Int'l, or you can continue to find other attribute values. In the Attribute Value Index dialog, click the Prev Level button if needed to return to the previous group of values.

Save Vector Symbology

Once you have modified the display properties of a vector layer, you can save the symbology settings for later use. Click the Symbology drop-down list and select Save/Update Symbology File. ENVI saves the symbology to a .evs file with the same root name as the vector file. By default, the symbology file is written to the same directory as the vector file. However, when that directory is read-only, the symbology file is written to the Auxiliary File Directory.

Each time you reopen the vector file, ENVI applies the styles defined in the associated symbology file (if it is present). You can select Save/Update Symbology File after making further changes. Or, if you do not like the changes you have made, select Apply Default Symbology to revert back to the styles defined in the symbology file.

To delete the symbology file completely, select Delete Symbology File. The vector layer then uses ENVI's default colors and styles.

View Attributes for Vectors


If a vector or Esri feature class layer has an associated attribute table, you can open and view the attributes. Right-click on the layer name in the Layer Manager and select View Attributes to open the Attribute Viewer.

Zoom Options


  • To zoom to the full extent of a given vector layer, right-click on the layer name in the Layer Manager and select Zoom to Layer.
  • Selecting Full Extent from the Zoom drop-down menu or clicking the Zoom to Full Extent button in the main toolbar zooms to the combined extents of all layers for the current view.
  • If a vector layer is georeferenced, the Zoom To drop-down list in the main toolbar displays options for Map Scale:



© 2019 Harris Geospatial Solutions, Inc. |  Legal
My Account    |    Store    |    Contact Us