Ejemplo n.º 1
0
        public static ILayer CreateCityHoverPoints()
        {
            var features = WorldCities.GenerateTop100();

            return(new MemoryLayer
            {
                Features = features,
                Style = CreateCityStyle(),
                Name = "Points",
                IsMapInfoLayer = true
            });
        }
Ejemplo n.º 2
0
        public static ILayer CreateCityHoverPoints()
        {
            var features = WorldCities.GenerateTop100();

            return(new MemoryLayer
            {
                DataSource = new MemoryProvider <IFeature>(features),
                Style = CreateCityStyle(),
                Name = "Points",
                IsMapInfoLayer = true
            });
        }
Ejemplo n.º 3
0
        public static Layer CreateWorldCitiesLayer()
        {
            var features = WorldCities.GenerateTop100();

            var memoryProvider = new MemoryProvider <IFeature>(features)
            {
                CRS = "EPSG:4326" // The DataSource CRS needs to be set
            };

            var dataSource = new ProjectingProvider(memoryProvider)
            {
                CRS = "EPSG:3857"
            };

            return(new Layer
            {
                DataSource = dataSource,
                Name = "Cities",
                Style = CreateCityStyle(),
                IsMapInfoLayer = true
            });
        }