WorldWind Source Analysis Series: Terrain accessor class Terrainaccessor

Source: Internet
Author: User

The terrain accessor class Terrainaccessor provides a variety of interface interface for terrain (elevation) Terrain (elevation) access, and is the base class for Nltterrainaccessor classes. The class diagram is as follows.

The main processing methods provided by the base class Terrainaccessor are briefly described below:

protected string M_name; Terrain Model Name

protected double M_north; Terrain North Border

protected double M_south; Terrain Southern Border

protected double m_east; Eastern boundary of terrain

protected double m_west; Western border of topography

public abstract float Getelevationat (double latitude, double longitude, double targetsamplesperdegree), abstract function with a given longitude, Latitude and the resolution precision of the reference frame at that location to obtain a floating-point elevation value. Returns 0 if no tiles are available on the disk. The derived class must implement the function.

The public virtual float Getelevationat (double latitude, double longitude) virtual function obtains floating-point elevation values with a given latitude and longitude. Returns 0 if no tiles are available on the disk. The inside is actually called the above abstract function. Derived classes can overload the function to suit their needs.

Public virtual Terraintile Getelevationarray (double North, double south, double west, double east, int samples) virtual functions through the given terrain area Domain bounding box and resolution to get an array of elevations. Returns tiles representing the elevation of the specified terrain. Derived classes can overload the function to suit their needs.

The derived class nltterrainaccessor is used to read the terrain/elevation data NLT stored in the Bil file.

WorldWind Source Analysis Series: Terrain accessor class Terrainaccessor

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.