Here is the script I was referring to earlier.... wow, is it aging - I need to update it for arcpy, but I'm pretty certain it still works in 10.Substitute your variable pathnames, etc., in the spaces denoted by '< insert *** param here >':
import arcgisscripting
gp = arcgisscripting.create(9.3)
gp.overwriteoutput = 'true'
# here's where you need to define some variables, only 4:
gp.workspace = r'< insert full root path to directory containing image tiles >'
coord_system = 'PROJCS[< insert coord sys params here >]'
GridName = '< your shapefile (you can convert to fc later, as you wish) >'
IMAGEfldLen = < your numeric length value for the image name field (suggest 50 or less) >
gp.CreateFeatureClass_management(gp.workspace, GridName, 'POLYGON', '', '', '', coord_system)
fields = ['IMAGE', 'XMIN', 'XMAX', 'YMIN', 'YMAX']
gp.AddField_management(GridName, fields[0], 'TEXT', '', '', IMAGEfldLen)
for i in range(1, 5):
gp.AddField_management(GridName, fields, 'DOUBLE', 18, 17)
print "added field: " + fields
rasters = gp.ListRasters()
arrayObj = gp.CreateObject('Array')
outRows = gp.InsertCursor(GridName)
for raster in rasters:
extent = gp.describe(raster).extent
arrayObj.add(extent.lowerleft)
arrayObj.add(extent.lowerright)
arrayObj.add(extent.upperright)
arrayObj.add(extent.upperleft)
arrayObj.add(extent.lowerleft)
feat = outRows.NewRow()
feat.Shape = arrayObj
image = '.\\' + raster
feat.SetValue('IMAGE', image)
feat.SetValue('XMIN', extent.xmin)
feat.SetValue('YMIN', extent.ymin)
feat.SetValue('XMAX', extent.xmax)
feat.SetValue('YMAX', extent.ymax)
outRows.InsertRow(feat)
arrayObj.RemoveAll()
del outRows
That should do it - if I get more time at a later date, I'll update this to use arcpy, use the da module cursor processing if possible, and add a script tool interface. As it is, you'll have to open the file in, say, a text editor, and change your params where instructed.Hope that works well for you![Note: If I'm not mistaken, you may have to build a spatial index to view it properly (it's in the Toolbox) or if importing the resultant shp into a gdb, one will be built for you.]-Wayne