{"action":"opened","number":649,"pull_request":{"url":"https://api.github.com/repos/OpenGeoscience/geojs/pulls/649","id":94621029,"html_url":"https://github.com/OpenGeoscience/geojs/pull/649","diff_url":"https://github.com/OpenGeoscience/geojs/pull/649.diff","patch_url":"https://github.com/OpenGeoscience/geojs/pull/649.patch","issue_url":"https://api.github.com/repos/OpenGeoscience/geojs/issues/649","number":649,"state":"open","locked":false,"title":"Refactor GL line rendering","user":{"login":"manthey","id":8781639,"avatar_url":"https://avatars.githubusercontent.com/u/8781639?v=3","gravatar_id":"","url":"https://api.github.com/users/manthey","html_url":"https://github.com/manthey","followers_url":"https://api.github.com/users/manthey/followers","following_url":"https://api.github.com/users/manthey/following{/other_user}","gists_url":"https://api.github.com/users/manthey/gists{/gist_id}","starred_url":"https://api.github.com/users/manthey/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/manthey/subscriptions","organizations_url":"https://api.github.com/users/manthey/orgs","repos_url":"https://api.github.com/users/manthey/repos","events_url":"https://api.github.com/users/manthey/events{/privacy}","received_events_url":"https://api.github.com/users/manthey/received_events","type":"User","site_admin":false},"body":"This resolves issues #204 and #596.\r\n\r\nPreviously, lines were not rendered correctly for several conditions: (a) miter locations were sometimes miscalculated, resulting in inconsistent line widths.  (b) when the miter limit was exceeded, an attempt to prevent an excessively long line produced skewed segments.  (c) On the inside of acute angles on short line segments, some of the triangles used to render lines were twisted.  (d) when lines overlap, the overlap was inconsistent.\r\n\r\nAll of this has been fixed.  Additionally, we now support:\r\n- line caps: butt (default and what was avaulable before), round, square.  These can vary by point.\r\n- line joins: miter (default), round, bevel, miter-clip.  These can vary by point.  Miter and miter-clip have a configurable miter limit (one value for the whole feature) which, if the miter would be longer than this, switches to using a bevel or a clipped miter.\r\n- antialiasing on edges and end caps.  This can be specified for the whole feature.\r\n- strokeOffset: This can vary from -1 (shift left) to 1 (shift right), where 0 is the line centered on the vertices, and 1 is with the edge of the line on the vertices.\r\n\r\nAll of this is done by rendering two triangles per line segment and performing much of the computation in the vertex and fragment shaders.\r\n\r\nThere are a few limitations to the current implementation:\r\n- there is finite precision in the calculations, resulting in occasional artifacts along miter joins.  These are mostly only noticeable on very wide lines using stroke offsets, and, even then, are subtle.\r\n- When the line width changes per vertex, sometimes the inside joins are not technically correct.  Instead of using the angle of the lines meeting, the angle of the edges of the lines meeting would need to be calculated.\r\n- On short line segments, one edge of the miter can be by itself, which would ideally either be antialiased or wouldn't be trimmed.  Currently, on wide short lines with multiple segments, the mitered edge can look blocky in limited instances.\r\n- When a line segment has zero length in screen space, it is not drawn at all.  Adjacent line segments may not be drawn exactly as expected.  Also, if line caps are used, perhaps zero-length segments should still be visible.\r\n\r\nThis method uses 18/15 as much memory as lines used before.\r\n\r\nThere is a debug flag to show all of the pixels sent to the fragment shader.  If debug is not specified when the feature is created, the debug code is not even compiled into the fragment shader.\r\n\r\nThere could be some efficiency improvements in the shaders.  For instance, it might worth it to have a quick test for simple line segments without joins.\r\n\r\nThe new features and changes are exposed in one of the selenium tests (test/selenium/glLines/?wide=true), which can take a variety of query options, such as strokeOffset, lineCap, lineJoin, miterLimit, antialiasing, strokeWidth, strokeColor, strokeOpacity, and debug.  This should be turned into an example that also tests number of lines.","created_at":"2016-11-21T14:05:52Z","updated_at":"2016-11-21T14:05:52Z","closed_at":null,"merged_at":null,"merge_commit_sha":"08a2a1541aa06c84cf2fa9e08960105eabfdfbe8","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/OpenGeoscience/geojs/pulls/649/commits","review_comments_url":"https://api.github.com/repos/OpenGeoscience/geojs/pulls/649/comments","review_comment_url":"https://api.github.com/repos/OpenGeoscience/geojs/pulls/comments{/number}","comments_url":"https://api.github.com/repos/OpenGeoscience/geojs/issues/649/comments","statuses_url":"https://api.github.com/repos/OpenGeoscience/geojs/statuses/484ae97f0ad4f80de8f9962d199f0b9fa6c159d2","head":{"label":"OpenGeoscience:line-rendering","ref":"line-rendering","sha":"484ae97f0ad4f80de8f9962d199f0b9fa6c159d2","user":{"login":"OpenGeoscience","id":3434706,"avatar_url":"https://avatars.githubusercontent.com/u/3434706?v=3","gravatar_id":"","url":"https://api.github.com/users/OpenGeoscience","html_url":"https://github.com/OpenGeoscience","followers_url":"https://api.github.com/users/OpenGeoscience/followers","following_url":"https://api.github.com/users/OpenGeoscience/following{/other_user}","gists_url":"https://api.github.com/users/OpenGeoscience/gists{/gist_id}","starred_url":"https://api.github.com/users/OpenGeoscience/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/OpenGeoscience/subscriptions","organizations_url":"https://api.github.com/users/OpenGeoscience/orgs","repos_url":"https://api.github.com/users/OpenGeoscience/repos","events_url":"https://api.github.com/users/OpenGeoscience/events{/privacy}","received_events_url":"https://api.github.com/users/OpenGeoscience/received_events","type":"Organization","site_admin":false},"repo":{"id":12960038,"name":"geojs","full_name":"OpenGeoscience/geojs","owner":{"login":"OpenGeoscience","id":3434706,"avatar_url":"https://avatars.githubusercontent.com/u/3434706?v=3","gravatar_id":"","url":"https://api.github.com/users/OpenGeoscience","html_url":"https://github.com/OpenGeoscience","followers_url":"https://api.github.com/users/OpenGeoscience/followers","following_url":"https://api.github.com/users/OpenGeoscience/following{/other_user}","gists_url":"https://api.github.com/users/OpenGeoscience/gists{/gist_id}","starred_url":"https://api.github.com/users/OpenGeoscience/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/OpenGeoscience/subscriptions","organizations_url":"https://api.github.com/users/OpenGeoscience/orgs","repos_url":"https://api.github.com/users/OpenGeoscience/repos","events_url":"https://api.github.com/users/OpenGeoscience/events{/privacy}","received_events_url":"https://api.github.com/users/OpenGeoscience/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/OpenGeoscience/geojs","description":"High performance visualization and analysis for geospatial and biomedical domain","fork":false,"url":"https://api.github.com/repos/OpenGeoscience/geojs","forks_url":"https://api.github.com/repos/OpenGeoscience/geojs/forks","keys_url":"https://api.github.com/repos/OpenGeoscience/geojs/keys{/key_id}","collaborators_url":"https://api.github.com/repos/OpenGeoscience/geojs/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/OpenGeoscience/geojs/teams","hooks_url":"https://api.github.com/repos/OpenGeoscience/geojs/hooks","issue_events_url":"https://api.github.com/repos/OpenGeoscience/geojs/issues/events{/number}","events_url":"https://api.github.com/repos/OpenGeoscience/geojs/events","assignees_url":"https://api.github.com/repos/OpenGeoscience/geojs/assignees{/user}","branches_url":"https://api.github.com/repos/OpenGeoscience/geojs/branches{/branch}","tags_url":"https://api.github.com/repos/OpenGeoscience/geojs/tags","blobs_url":"https://api.github.com/repos/OpenGeoscience/geojs/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/OpenGeoscience/geojs/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/OpenGeoscience/geojs/git/refs{/sha}","trees_url":"https://api.github.com/repos/OpenGeoscience/geojs/git/trees{/sha}","statuses_url":"https://api.github.com/repos/OpenGeoscience/geojs/statuses/{sha}","languages_url":"https://api.github.com/repos/OpenGeoscience/geojs/languages","stargazers_url":"https://api.github.com/repos/OpenGeoscience/geojs/stargazers","contributors_url":"https://api.github.com/repos/OpenGeoscience/geojs/contributors","subscribers_url":"https://api.github.com/repos/OpenGeoscience/geojs/subscribers","subscription_url":"https://api.github.com/repos/OpenGeoscience/geojs/subscription","commits_url":"https://api.github.com/repos/OpenGeoscience/geojs/commits{/sha}","git_commits_url":"https://api.github.com/repos/OpenGeoscience/geojs/git/commits{/sha}","comments_url":"https://api.github.com/repos/OpenGeoscience/geojs/comments{/number}","issue_comment_url":"https://api.github.com/repos/OpenGeoscience/geojs/issues/comments{/number}","contents_url":"https://api.github.com/repos/OpenGeoscience/geojs/contents/{+path}","compare_url":"https://api.github.com/repos/OpenGeoscience/geojs/compare/{base}...{head}","merges_url":"https://api.github.com/repos/OpenGeoscience/geojs/merges","archive_url":"https://api.github.com/repos/OpenGeoscience/geojs/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/OpenGeoscience/geojs/downloads","issues_url":"https://api.github.com/repos/OpenGeoscience/geojs/issues{/number}","pulls_url":"https://api.github.com/repos/OpenGeoscience/geojs/pulls{/number}","milestones_url":"https://api.github.com/repos/OpenGeoscience/geojs/milestones{/number}","notifications_url":"https://api.github.com/repos/OpenGeoscience/geojs/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/OpenGeoscience/geojs/labels{/name}","releases_url":"https://api.github.com/repos/OpenGeoscience/geojs/releases{/id}","deployments_url":"https://api.github.com/repos/OpenGeoscience/geojs/deployments","created_at":"2013-09-19T21:39:25Z","updated_at":"2016-11-15T09:37:31Z","pushed_at":"2016-11-21T14:05:52Z","git_url":"git://github.com/OpenGeoscience/geojs.git","ssh_url":"git@github.com:OpenGeoscience/geojs.git","clone_url":"https://github.com/OpenGeoscience/geojs.git","svn_url":"https://github.com/OpenGeoscience/geojs","homepage":"","size":49294,"stargazers_count":58,"watchers_count":58,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":18,"mirror_url":null,"open_issues_count":69,"forks":18,"open_issues":69,"watchers":58,"default_branch":"master"}},"base":{"label":"OpenGeoscience:master","ref":"master","sha":"73e8285b0c72c0e8746dd57cb50d70e69008ee27","user":{"login":"OpenGeoscience","id":3434706,"avatar_url":"https://avatars.githubusercontent.com/u/3434706?v=3","gravatar_id":"","url":"https://api.github.com/users/OpenGeoscience","html_url":"https://github.com/OpenGeoscience","followers_url":"https://api.github.com/users/OpenGeoscience/followers","following_url":"https://api.github.com/users/OpenGeoscience/following{/other_user}","gists_url":"https://api.github.com/users/OpenGeoscience/gists{/gist_id}","starred_url":"https://api.github.com/users/OpenGeoscience/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/OpenGeoscience/subscriptions","organizations_url":"https://api.github.com/users/OpenGeoscience/orgs","repos_url":"https://api.github.com/users/OpenGeoscience/repos","events_url":"https://api.github.com/users/OpenGeoscience/events{/privacy}","received_events_url":"https://api.github.com/users/OpenGeoscience/received_events","type":"Organization","site_admin":false},"repo":{"id":12960038,"name":"geojs","full_name":"OpenGeoscience/geojs","owner":{"login":"OpenGeoscience","id":3434706,"avatar_url":"https://avatars.githubusercontent.com/u/3434706?v=3","gravatar_id":"","url":"https://api.github.com/users/OpenGeoscience","html_url":"https://github.com/OpenGeoscience","followers_url":"https://api.github.com/users/OpenGeoscience/followers","following_url":"https://api.github.com/users/OpenGeoscience/following{/other_user}","gists_url":"https://api.github.com/users/OpenGeoscience/gists{/gist_id}","starred_url":"https://api.github.com/users/OpenGeoscience/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/OpenGeoscience/subscriptions","organizations_url":"https://api.github.com/users/OpenGeoscience/orgs","repos_url":"https://api.github.com/users/OpenGeoscience/repos","events_url":"https://api.github.com/users/OpenGeoscience/events{/privacy}","received_events_url":"https://api.github.com/users/OpenGeoscience/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/OpenGeoscience/geojs","description":"High performance visualization and analysis for geospatial and biomedical domain","fork":false,"url":"https://api.github.com/repos/OpenGeoscience/geojs","forks_url":"https://api.github.com/repos/OpenGeoscience/geojs/forks","keys_url":"https://api.github.com/repos/OpenGeoscience/geojs/keys{/key_id}","collaborators_url":"https://api.github.com/repos/OpenGeoscience/geojs/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/OpenGeoscience/geojs/teams","hooks_url":"https://api.github.com/repos/OpenGeoscience/geojs/hooks","issue_events_url":"https://api.github.com/repos/OpenGeoscience/geojs/issues/events{/number}","events_url":"https://api.github.com/repos/OpenGeoscience/geojs/events","assignees_url":"https://api.github.com/repos/OpenGeoscience/geojs/assignees{/user}","branches_url":"https://api.github.com/repos/OpenGeoscience/geojs/branches{/branch}","tags_url":"https://api.github.com/repos/OpenGeoscience/geojs/tags","blobs_url":"https://api.github.com/repos/OpenGeoscience/geojs/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/OpenGeoscience/geojs/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/OpenGeoscience/geojs/git/refs{/sha}","trees_url":"https://api.github.com/repos/OpenGeoscience/geojs/git/trees{/sha}","statuses_url":"https://api.github.com/repos/OpenGeoscience/geojs/statuses/{sha}","languages_url":"https://api.github.com/repos/OpenGeoscience/geojs/languages","stargazers_url":"https://api.github.com/repos/OpenGeoscience/geojs/stargazers","contributors_url":"https://api.github.com/repos/OpenGeoscience/geojs/contributors","subscribers_url":"https://api.github.com/repos/OpenGeoscience/geojs/subscribers","subscription_url":"https://api.github.com/repos/OpenGeoscience/geojs/subscription","commits_url":"https://api.github.com/repos/OpenGeoscience/geojs/commits{/sha}","git_commits_url":"https://api.github.com/repos/OpenGeoscience/geojs/git/commits{/sha}","comments_url":"https://api.github.com/repos/OpenGeoscience/geojs/comments{/number}","issue_comment_url":"https://api.github.com/repos/OpenGeoscience/geojs/issues/comments{/number}","contents_url":"https://api.github.com/repos/OpenGeoscience/geojs/contents/{+path}","compare_url":"https://api.github.com/repos/OpenGeoscience/geojs/compare/{base}...{head}","merges_url":"https://api.github.com/repos/OpenGeoscience/geojs/merges","archive_url":"https://api.github.com/repos/OpenGeoscience/geojs/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/OpenGeoscience/geojs/downloads","issues_url":"https://api.github.com/repos/OpenGeoscience/geojs/issues{/number}","pulls_url":"https://api.github.com/repos/OpenGeoscience/geojs/pulls{/number}","milestones_url":"https://api.github.com/repos/OpenGeoscience/geojs/milestones{/number}","notifications_url":"https://api.github.com/repos/OpenGeoscience/geojs/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/OpenGeoscience/geojs/labels{/name}","releases_url":"https://api.github.com/repos/OpenGeoscience/geojs/releases{/id}","deployments_url":"https://api.github.com/repos/OpenGeoscience/geojs/deployments","created_at":"2013-09-19T21:39:25Z","updated_at":"2016-11-15T09:37:31Z","pushed_at":"2016-11-21T14:05:52Z","git_url":"git://github.com/OpenGeoscience/geojs.git","ssh_url":"git@github.com:OpenGeoscience/geojs.git","clone_url":"https://github.com/OpenGeoscience/geojs.git","svn_url":"https://github.com/OpenGeoscience/geojs","homepage":"","size":49294,"stargazers_count":58,"watchers_count":58,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":18,"mirror_url":null,"open_issues_count":69,"forks":18,"open_issues":69,"watchers":58,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/OpenGeoscience/geojs/pulls/649"},"html":{"href":"https://github.com/OpenGeoscience/geojs/pull/649"},"issue":{"href":"https://api.github.com/repos/OpenGeoscience/geojs/issues/649"},"comments":{"href":"https://api.github.com/repos/OpenGeoscience/geojs/issues/649/comments"},"review_comments":{"href":"https://api.github.com/repos/OpenGeoscience/geojs/pulls/649/comments"},"review_comment":{"href":"https://api.github.com/repos/OpenGeoscience/geojs/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/OpenGeoscience/geojs/pulls/649/commits"},"statuses":{"href":"https://api.github.com/repos/OpenGeoscience/geojs/statuses/484ae97f0ad4f80de8f9962d199f0b9fa6c159d2"}},"merged":false,"mergeable":true,"mergeable_state":"unstable","merged_by":null,"comments":0,"review_comments":0,"commits":1,"additions":492,"deletions":71,"changed_files":5}}
{"actor":{"display_login":"manthey"}}