ImportFromFloat |
|
|
Release 9.2
Last modified January 3, 2008 |
Print all topics in : "Conversion (Spatial Analyst)" |
Converts a file of binary floating-point numbers to a raster.
Usage tips
ArcObjects
The input file is an IEEE floating-point format, 32-bit signed binary file.
In addition to the binary floating-point file, an ASCII header file named <in_file>.hdr is required.
The ASCII header file consists of header information containing a set of keywords. The file format is
NCOLS xxx
NROWS xxx
XLLCENTER xxx | XLLCORNER xxx
YLLCENTER xxx | YLLCORNER xxx
CELLSIZE xxx
NODATA_VALUE xxx
BYTEORDER <MSBFIRST | LSBFIRST | VMS_FFLOAT>
where xxx is a number, and the keyword NODATA_VALUE is optional.
The NODATA_VALUE is the value in the input file that determines which cells should be assigned the value of NoData in the output raster. NoData is normally reserved for those cells whose true value is unknown.
Command line syntax
See Float to Raster
Scripting syntax
See Float to Raster
Map Algebra syntax
See FloatGrid
ArcObjects syntax
IRasterConversionOp::ImportFromFloat (floatFile As String, OutWorkspace As IWorkspace, outRasterName As String, OutRasterFormat As String) As IRasterDataset
| Parameter | Explanation |
| floatFile | An input floating-point binary file. |
| OutWorkspace | An object specifying the directory or subdirectory to contain the output raster dataset. |
| outRasterName | The name of the output raster. |
| OutRasterFormat | ESRI GRID, ERDAS IMAGINE, or TIFF formats are supported. The strings for outRasterFormat are GRID, IMAGINE Image, and TIFF respectively. They are case sensitive.
The format string GRID creates an output ESRI GRID with no file extension. The format string TIFF creates a TIFF file with a .tif extension. ArcGIS also supports the TIFF format with .tiff and .tff extensions. A format string TIF creates a TIFF file with a .tiff extension, and a format string TFF creates a TIFF file with a .tff extension. The format string IMAGINE Image creates a raster output with a .img file extension. |
' Imports a Float GRID file into a RasterDataset.
' Member of esriGeoAnalyst.IRasterImportOp.
'
' Function ImportFromFloat(ByVal asciiFile As String, _
' ByVal OutWorkspace As esriGeoDatabase.IWorkspace,
' ByVal outRasterName As String, ByVal OutRasterFormat As String, _
' ByVal isInteger As Boolean) As esriGeoDatabase.IRasterDataset
Dim pRasterImportOp As IRasterImportOp
Set pRasterImportOp = New RasterConversionOp
Dim pRasterWS As IWorkspace
Dim pRasterWSFact As IWorkspaceFactory
Set pRasterWSFact = New RasterWorkspaceFactory
Set pRasterWS = pRasterWSFact.OpenFromFile("c:\myDirectory"", 0)
Dim pRasOut As IRasterDataset
Set pRasOut = pRasterImportOp.ImportFromASCII("inFile.flt", pRasterWS, "mrGrid", "GRID", True)