X
PrevPrev Go to previous topic
NextNext Go to next topic
Last Post 06 Feb 2017 08:47 PM by  anon
Layer stacking from metadata
 1 Replies
Sort:
You are not authorized to post a reply.
Author Messages

anon



New Member


Posts:1
New Member


--
06 Feb 2017 08:47 PM
    Hi everyone, I want to layer stack from the metadata file, is it possible? I already read the metadata using this code: pro landsat8 e = ENVI() ; Open a Landsat-8 file file = 'F:\Citra\LANDSAT\\20140127\LC81190652014027LGN00\LC81190652014027LGN00_MTL.txt' raster = e.OpenRaster(file) ; Landsat-8 images are stored in a five-element array. ; Multispectral bands from the OLI sensor are stored in ; the first array element. You do not need to perform this ; step with most multispectral sensors. OLIBands = raster[0] ; Radiometric calibration and atmospheric correction ; steps would normally go here. ; Get the actual data values for each band CoastalAerosol = OLIBands.GetData(BANDS=[0]) Blue = OLIBands.GetData(BANDS=[1]) Green = OLIBands.GetData(BANDS=[2]) Red = OLIBands.GetData(BANDS=[3]) NIR = OLIBands.GetData(BANDS=[4]) SWIR1 = OLIBands.GetData(BANDS=[5]) SWIR2 = OLIBands.GetData(BANDS=[6]) Panc = OLIBands.GetData(BANDS=[7]) Cirr = OLIBands.GetData(BANDS=[8]) Thrm1 = OLIBands.GetData(BANDS=[9]) Thrm2 = OLIBands.GetData(BANDS=[10]) Qty = OLIBands.GetData(BANDS=[11]) end This script I use ENVI+IDL so that in ENVI can see. But I cant open this file in ENVI Classic, why? I also want to layer stack also. Thank you.

    MariM



    Veteran Member


    Posts:2396
    Veteran Member


    --
    07 Feb 2017 09:01 AM
    I would follow the example code for using ENVILayerStackRaster. This example uses Sentinel-2 data but it would be very similar for Landsat-8: https://www.harrisgeospatial.com/docs...
    You are not authorized to post a reply.