moccand78

Change Raster rendering to "composite RGB"

Discussion created by moccand78 on Jul 21, 2011
Latest reply on Jul 10, 2012 by chungcf
Dear all,

i need to load a Raster (jp2) in a mxd but without using lyr files.
here is my code (it works fine)

mxd2 = arcpy.mapping.MapDocument(mxdTemplate)
...
df2 = arcpy.mapping.ListDataFrames(mxd2)[0]
...
addlayer = arcpy.mapping.Layer("c:\toto.jp2")
arcpy.mapping.AddLayer(df2, addlayer, "BOTTOM")
rasterExtent = addlayer.getExtent()
df2.extent = rasterExtent
...
mxd2.saveACopy (nouveauMXD)

but the Raster is rendered "streched" ... i need to get it as it should : in composite RGB.

Any idea about doing this in arcpy ?

Thanks in advance

Guillaume

Outcomes