2

I am wondering if anyone knows if there is arcpy functionality available in ArcGIS 10.3 or can be coded easily to replicate the select visible rasters command (manually right clicking on a Mosaic Dataset Footprint in the table of contents in an ArcMap session).

enter image description here

matt wilkie
28.3k35 gold badges150 silver badges286 bronze badges
asked May 27, 2015 at 0:58

1 Answer 1

1

This is similar: Use ListDataFrames() to get current display extent and then MakeMosaicLayer() to create a temporary mosaic.

import arcpy
mxd = arcpy.mapping.MapDocument("CURRENT")
df = arcpy.mapping.ListDataFrames(mxd, "*")[0] # grab 1st dataframe in map
#df = arcpy.mapping.ListDataFrames(mxd, "Main")[0] # grab dataframe named 'Main'
arcpy.MakeMosaicLayer_management(
 'Orthophotos', # input mosaic
 'test_mosaic', # output mosaic
 '#', # Optional WHERE clause
 df.extent # clipping box coordinates
 )

Sources:

answered Jul 25, 2017 at 22:36

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.