Table of Contents

Class GeoTiffRasterSource

Namespace
ThinkGeo.Core
Assembly
ThinkGeo.Core.dll
public class GeoTiffRasterSource : RasterSource
Inheritance
GeoTiffRasterSource
Inherited Members

Constructors

GeoTiffRasterSource(string)

Initializes a new instance of the GeoTiffRasterSource class.

public GeoTiffRasterSource(string imagePathFilename)

Parameters

imagePathFilename string

The image path filename.

See Also

GeoTiffRasterSource(string, string)

Initializes a new instance of the GeoTiffRasterSource class.

public GeoTiffRasterSource(string imagePathFilename, string worldFilePathFilename)

Parameters

imagePathFilename string

The image path filename.

worldFilePathFilename string

The world file path filename.

See Also

GeoTiffRasterSource(string, RectangleShape)

Initializes a new instance of the GeoTiffRasterSource class.

public GeoTiffRasterSource(string imagePathFilename, RectangleShape imageExtent)

Parameters

imagePathFilename string

The image path filename.

imageExtent RectangleShape

The image extent.

See Also

Properties

ImagePathFilename

Gets or sets the image path filename.

public string ImagePathFilename { get; set; }

Property Value

string

The image path filename.

See Also

Methods

CloseCore()

This method opens the RasterSource so that it is initialized and ready to use.

protected override void CloseCore()

Remarks

This protected virtual method is called from the concrete public method Close. The Close method plays an important role in the life cycle of the RasterSource. It may be called after drawing to release any memory and other resources that were allocated since the Open method was called.

If you override this method, it is recommended that you take the following things into account: This method may be called multiple times, so we suggest you write the method so that that a call to a closed RasterSource is ignored and does not generate an error. We also suggest that in the Close you free all resources that have been opened. Remember that the object will not be destroyed, but will be re-opened possibly in the near future.

See Also

GetBoundingBoxCore()

This method returns the bounding box of the RasterSource.

protected override RectangleShape GetBoundingBoxCore()

Returns

RectangleShape

This method returns the bounding box of the RasterSource.

Remarks

This method returns the bounding box of the RasterSource.

See Also

GetImageCore(RectangleShape, int, int)

This method returns an image based on the worldExtent and image width and height.

protected override GeoImage GetImageCore(RectangleShape worldExtent, int canvasWidth, int canvasHeight)

Parameters

worldExtent RectangleShape

This parameter represents the worldExtent you want to draw.

canvasWidth int

This parameter represents the width of the image you want to draw.

canvasHeight int

This parameter represents the height of the image you want to draw.

Returns

GeoImage

This method returns an image based on the worldExtent and image width and height.

Remarks

This method is responsible for returning the image based on the parameters passed in. As the core version of this method is abstract, you will need to override it when creating our own RasterSource.

See Also

GetImageHeightCore()

This method returns the height of the image in screen coordinates.

protected override int GetImageHeightCore()

Returns

int

This method returns the height of the image in screen coordinates.

Remarks

This abstract method is called from the concrete method GetImageHeight. You need to override it if you inherit from the RasterSource to return the height of your image. It returns the height of the image in screen coordinates.

See Also

GetImageWidthCore()

This method returns the width of the image in screen coordinates.

protected override int GetImageWidthCore()

Returns

int

This method returns the width of the image in screen coordinates.

Remarks

This abstract method is called from the concrete method GetImageWidth. You need to override it if you inherit from the RasterSource to return the width of your image. It returns the width of the image in screen coordinates.

See Also

OpenCore()

This method opens the RasterSource so that it is initialized and ready to use.

protected override void OpenCore()

Remarks

This protected virtual method is called from the concrete public method Open. The Open method plays an important role, as it is responsible for initializing the RasterSource. Most methods on the RasterSource will throw an exception if the state of the RasterSource is not opened. When the map draws each layer, it will open the RasterSource as one of its first steps; then, after it is finished drawing with that layer, it will close it. In this way, we are sure to release all resources used by the RasterSource.

When implementing this abstract method, consider opening files for file-based sources, connecting to databases in the database-based sources and so on. You will get a chance to close these in the Close method of the RasterSource.

See Also

See Also