0

I'm using the Project Raster tool via arcpy:

 arcpy.ProjectRaster_management(
     in_raster = clipped_raster,
     out_raster = projected_clipped_raster,
     out_coor_system = COORDINATE_SYSTEM_WGS_1984_WEB_MERCATOR,
     resampling_type = "CUBIC",
     geographic_transform = TRANSFORM_US_IFR_TO_WGS_1984_WEB_MERCATOR,
     in_coor_system = COORDINATE_SYSTEM_US_IFR)

Before the image has a white background:

enter image description here

But after the projection, its grey:

enter image description here

Any idea why this would be happening?

---- EDIT ----

Per the suggestion by @Fetzer, I check the Stretch setting. I see it has Percent Clip:

enter image description here

However, when I set it to None per his suggestion, the grey actually gets darker:

enter image description here

  • What about turning off Gamma Stretch? or adjusting the settings for min/max to 0.5 or something... – Fezter Apr 27 '16 at 23:03
  • @Fezter, turning off Gamma Stretch lightens the grey a little bit, adjusting min/max, also lightens the grey a tiny bit. Combining the 2 makes no additional difference... I did notice that, on the display tab, Contrast was set to 10% (original image was 0, so no clue why that got set to 10). When I changed it to 0, it got darker... So i changed it to 50, and the grey practically disappears. Any idea why that would be? Also, at the risk of sounding ignorant (which i am), what led you to think transparency/stretch in the first place? – Lucas Apr 28 '16 at 15:34
1

A couple things might be happening here.

  1. You have a transparency on the layer (unlikely).

  2. You have a stretch type defined in the symbology for the raster.

    This might be standard deviation: enter image description here

Set it to None and see if that makes any difference.

  • Yup, it does have a stretch. And it is set to Percent Clip. Setting it to None actually made the grey darker... (see edit above) – Lucas Apr 27 '16 at 22:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.