This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
OpenLayers.Util.QuickHull = (function() { | |
var buildConvexHull = function (baseLine, points, allBaseLines) { | |
var convexHullBaseLines = [], | |
maxDistance = 0, | |
maxPoint = [], | |
newPoints = [], | |
point, distance, i, vY, vX; | |
for (i = 0; i < points.length; i++) { | |
point = points[i]; | |
vY = baseLine[1][0] - baseLine[0][0]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pprint | |
import operator | |
plugin_load_times= qgis.utils.plugin_times | |
sorted_load_times = sorted(plugin_load_times.items(), key=operator.itemgetter(1)) | |
pprint.pprint(sorted_load_times) | |
# in addition to: https://gis.stackexchange.com/questions/209129/how-to-tell-which-qgis-plugins-are-slow-to-load?stw=2 | |
# helpt to sort dictionary from: https://stackoverflow.com/questions/613183/sort-a-python-dictionary-by-value |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CREATE TABLE label_point ( | |
gid serial NOT NULL, | |
geom geometry(point, 3857), | |
label_sample varchar(255), | |
CONSTRAINT label_point_pkey PRIMARY KEY (gid) | |
); | |
CREATE TABLE soil ( | |
gid serial NOT NULL, | |
geom geometry(polygon, 3857), |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
BEGIN; | |
------------------------------------------------------- | |
-- CREATE test tables | |
CREATE TABLE label_point ( | |
gid serial NOT NULL, | |
geom geometry(point, 3857), | |
label_sample varchar(255), |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CREATE TABLE public.testpolygons1 | |
( | |
gid serial PRIMARY KEY, | |
geom geometry(Polygon,3857) | |
); | |
CREATE TABLE public.testpolygons2 | |
( | |
gid serial PRIMARY KEY, | |
geom geometry(Polygon,3857) |
OlderNewer