Using the IlvRasterASRPReader class to create images

Creating the reader

To create the IlvRasterASRPReaderIlvRaster :
  • Provide the name of the .GEN file describing the ASRP image:
    IlvRasterASRPReader imageReader = new IlvRasterASRPReader();
    imageReader.addMap(fileName);
    
The reader removes the extension, that is, the characters after the last period (.) at the end of the filename, and constructs the names of the .GEN, .IMG and .QAL files from that base name. Note that a field inside the .GEN file can possibly override this default mechanism.

Creating a data source

To create a data source and link it with the manager properties:
  • Define and insert the data source in the data source tree:
    
    IlvMapDataSource imageDataSource =
      IlvRasterDataSourceFactory.buildTiledImageDataSource(manager,imageReader,
        true,true,null);
    IlvMapDataSourceModel dataSourceModel =
      IlvMapDataSourceProperty.GetMapDataSourceModel(manager);
    dataSourceModel.insert(imageDataSource);
    

Reading the data

To start reading your data:
  • Start the data source:
    dataSourceModel.start();
    
Starting the data source creates the necessary tiled layers, tile managers, and IlvRasterIcon instances to manage the pixel-on-demand feature and the progressive display of the geo-referenced image.
For further information, see: