{"action":"created","comment":{"url":"https://api.github.com/repos/mapbox/mapbox-gl-js/pulls/comments/25235631","id":25235631,"diff_hunk":"@@ -324,7 +324,26 @@ SymbolBucket.prototype.placeFeatures = function(buffers) {\n     this.addToDebugBuffers();\n };\n \n-SymbolBucket.prototype.addSymbols = function(buffer, elementGroups, symbols, scale) {\n+SymbolBucket.prototype.addSymbols = function(buffer, elementGroups, symbols_original, scale) {\n+\n+    var pi = Math.PI\n+    var twoPi = 2 * pi;\n+    var halfPi = 0.5 * pi;\n+    var threeQuarterPi = 3 * pi / 2;\n+\n+    // Translate placement angle from [-π, π] to [0, 2π]\n+    var placementAngle = this.placement.angle + pi;\n+    var symbols = [];\n+    for (var i = 0; i < symbols_original.length; i++) {\n+      var symbol = symbols_original[i];\n+      var symbolAngle = symbol.angle;\n+      \n+      var angle = (symbolAngle + placementAngle) % twoPi;\n+      if (angle > halfPi && angle < threeQuarterPi) {\n+        symbols.push(symbol);\n+      }\n+\n+    }","path":"js/data/symbol_bucket.js","position":24,"original_position":24,"commit_id":"9ceb19e6923f58575d916b8d94fc2ee01127e463","original_commit_id":"9ceb19e6923f58575d916b8d94fc2ee01127e463","user":{"login":"mourner","id":25395,"avatar_url":"https://avatars.githubusercontent.com/u/25395?v=3","gravatar_id":"","url":"https://api.github.com/users/mourner","html_url":"https://github.com/mourner","followers_url":"https://api.github.com/users/mourner/followers","following_url":"https://api.github.com/users/mourner/following{/other_user}","gists_url":"https://api.github.com/users/mourner/gists{/gist_id}","starred_url":"https://api.github.com/users/mourner/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mourner/subscriptions","organizations_url":"https://api.github.com/users/mourner/orgs","repos_url":"https://api.github.com/users/mourner/repos","events_url":"https://api.github.com/users/mourner/events{/privacy}","received_events_url":"https://api.github.com/users/mourner/received_events","type":"User","site_admin":false},"body":"Please adhere to the JS code conventions of the rest of the repo. 4 spaces, camelCase, semicolons, and the build should pass.","created_at":"2015-02-24T08:36:02Z","updated_at":"2015-02-24T08:36:02Z","html_url":"https://github.com/mapbox/mapbox-gl-js/pull/1026#discussion_r25235631","pull_request_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/pulls/1026","_links":{"self":{"href":"https://api.github.com/repos/mapbox/mapbox-gl-js/pulls/comments/25235631"},"html":{"href":"https://github.com/mapbox/mapbox-gl-js/pull/1026#discussion_r25235631"},"pull_request":{"href":"https://api.github.com/repos/mapbox/mapbox-gl-js/pulls/1026"}}},"pull_request":{"url":"https://api.github.com/repos/mapbox/mapbox-gl-js/pulls/1026","id":29865718,"html_url":"https://github.com/mapbox/mapbox-gl-js/pull/1026","diff_url":"https://github.com/mapbox/mapbox-gl-js/pull/1026.diff","patch_url":"https://github.com/mapbox/mapbox-gl-js/pull/1026.patch","issue_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/issues/1026","number":1026,"state":"open","locked":false,"title":"Keep upright","user":{"login":"kapadia","id":581337,"avatar_url":"https://avatars.githubusercontent.com/u/581337?v=3","gravatar_id":"","url":"https://api.github.com/users/kapadia","html_url":"https://github.com/kapadia","followers_url":"https://api.github.com/users/kapadia/followers","following_url":"https://api.github.com/users/kapadia/following{/other_user}","gists_url":"https://api.github.com/users/kapadia/gists{/gist_id}","starred_url":"https://api.github.com/users/kapadia/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kapadia/subscriptions","organizations_url":"https://api.github.com/users/kapadia/orgs","repos_url":"https://api.github.com/users/kapadia/repos","events_url":"https://api.github.com/users/kapadia/events{/privacy}","received_events_url":"https://api.github.com/users/kapadia/received_events","type":"User","site_admin":false},"body":"Addresses https://github.com/mapbox/mapbox-gl-js/issues/1020 - only half the symbols are sent to the shader by filtering on map and symbol rotations.\r\n\r\n","created_at":"2015-02-24T02:16:42Z","updated_at":"2015-02-24T08:36:02Z","closed_at":null,"merged_at":null,"merge_commit_sha":"916cba843820c056f00581d980e6613e9ed70eb8","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/pulls/1026/commits","review_comments_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/pulls/1026/comments","review_comment_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/pulls/comments{/number}","comments_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/issues/1026/comments","statuses_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/statuses/9ceb19e6923f58575d916b8d94fc2ee01127e463","head":{"label":"mapbox:keep-upright","ref":"keep-upright","sha":"9ceb19e6923f58575d916b8d94fc2ee01127e463","user":{"login":"mapbox","id":600935,"avatar_url":"https://avatars.githubusercontent.com/u/600935?v=3","gravatar_id":"","url":"https://api.github.com/users/mapbox","html_url":"https://github.com/mapbox","followers_url":"https://api.github.com/users/mapbox/followers","following_url":"https://api.github.com/users/mapbox/following{/other_user}","gists_url":"https://api.github.com/users/mapbox/gists{/gist_id}","starred_url":"https://api.github.com/users/mapbox/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mapbox/subscriptions","organizations_url":"https://api.github.com/users/mapbox/orgs","repos_url":"https://api.github.com/users/mapbox/repos","events_url":"https://api.github.com/users/mapbox/events{/privacy}","received_events_url":"https://api.github.com/users/mapbox/received_events","type":"Organization","site_admin":false},"repo":{"id":8629417,"name":"mapbox-gl-js","full_name":"mapbox/mapbox-gl-js","owner":{"login":"mapbox","id":600935,"avatar_url":"https://avatars.githubusercontent.com/u/600935?v=3","gravatar_id":"","url":"https://api.github.com/users/mapbox","html_url":"https://github.com/mapbox","followers_url":"https://api.github.com/users/mapbox/followers","following_url":"https://api.github.com/users/mapbox/following{/other_user}","gists_url":"https://api.github.com/users/mapbox/gists{/gist_id}","starred_url":"https://api.github.com/users/mapbox/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mapbox/subscriptions","organizations_url":"https://api.github.com/users/mapbox/orgs","repos_url":"https://api.github.com/users/mapbox/repos","events_url":"https://api.github.com/users/mapbox/events{/privacy}","received_events_url":"https://api.github.com/users/mapbox/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mapbox/mapbox-gl-js","description":"JavaScript library for WebGL-based client-side vector maps","fork":false,"url":"https://api.github.com/repos/mapbox/mapbox-gl-js","forks_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/forks","keys_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/teams","hooks_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/hooks","issue_events_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/issues/events{/number}","events_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/events","assignees_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/assignees{/user}","branches_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/branches{/branch}","tags_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/tags","blobs_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/git/refs{/sha}","trees_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/statuses/{sha}","languages_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/languages","stargazers_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/stargazers","contributors_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/contributors","subscribers_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/subscribers","subscription_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/subscription","commits_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/commits{/sha}","git_commits_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/git/commits{/sha}","comments_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/comments{/number}","issue_comment_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/issues/comments{/number}","contents_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/contents/{+path}","compare_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/merges","archive_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/downloads","issues_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/issues{/number}","pulls_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/pulls{/number}","milestones_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/milestones{/number}","notifications_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/labels{/name}","releases_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/releases{/id}","created_at":"2013-03-07T14:45:24Z","updated_at":"2015-02-24T04:35:40Z","pushed_at":"2015-02-24T04:37:08Z","git_url":"git://github.com/mapbox/mapbox-gl-js.git","ssh_url":"git@github.com:mapbox/mapbox-gl-js.git","clone_url":"https://github.com/mapbox/mapbox-gl-js.git","svn_url":"https://github.com/mapbox/mapbox-gl-js","homepage":"https://www.mapbox.com/mapbox-gl/","size":21156,"stargazers_count":527,"watchers_count":527,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":48,"mirror_url":null,"open_issues_count":135,"forks":48,"open_issues":135,"watchers":527,"default_branch":"master"}},"base":{"label":"mapbox:placement","ref":"placement","sha":"4e2c209dbb91a4688445845a159c22afcaf67d7b","user":{"login":"mapbox","id":600935,"avatar_url":"https://avatars.githubusercontent.com/u/600935?v=3","gravatar_id":"","url":"https://api.github.com/users/mapbox","html_url":"https://github.com/mapbox","followers_url":"https://api.github.com/users/mapbox/followers","following_url":"https://api.github.com/users/mapbox/following{/other_user}","gists_url":"https://api.github.com/users/mapbox/gists{/gist_id}","starred_url":"https://api.github.com/users/mapbox/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mapbox/subscriptions","organizations_url":"https://api.github.com/users/mapbox/orgs","repos_url":"https://api.github.com/users/mapbox/repos","events_url":"https://api.github.com/users/mapbox/events{/privacy}","received_events_url":"https://api.github.com/users/mapbox/received_events","type":"Organization","site_admin":false},"repo":{"id":8629417,"name":"mapbox-gl-js","full_name":"mapbox/mapbox-gl-js","owner":{"login":"mapbox","id":600935,"avatar_url":"https://avatars.githubusercontent.com/u/600935?v=3","gravatar_id":"","url":"https://api.github.com/users/mapbox","html_url":"https://github.com/mapbox","followers_url":"https://api.github.com/users/mapbox/followers","following_url":"https://api.github.com/users/mapbox/following{/other_user}","gists_url":"https://api.github.com/users/mapbox/gists{/gist_id}","starred_url":"https://api.github.com/users/mapbox/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mapbox/subscriptions","organizations_url":"https://api.github.com/users/mapbox/orgs","repos_url":"https://api.github.com/users/mapbox/repos","events_url":"https://api.github.com/users/mapbox/events{/privacy}","received_events_url":"https://api.github.com/users/mapbox/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mapbox/mapbox-gl-js","description":"JavaScript library for WebGL-based client-side vector maps","fork":false,"url":"https://api.github.com/repos/mapbox/mapbox-gl-js","forks_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/forks","keys_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/teams","hooks_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/hooks","issue_events_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/issues/events{/number}","events_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/events","assignees_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/assignees{/user}","branches_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/branches{/branch}","tags_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/tags","blobs_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/git/refs{/sha}","trees_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/statuses/{sha}","languages_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/languages","stargazers_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/stargazers","contributors_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/contributors","subscribers_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/subscribers","subscription_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/subscription","commits_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/commits{/sha}","git_commits_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/git/commits{/sha}","comments_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/comments{/number}","issue_comment_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/issues/comments{/number}","contents_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/contents/{+path}","compare_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/merges","archive_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/downloads","issues_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/issues{/number}","pulls_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/pulls{/number}","milestones_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/milestones{/number}","notifications_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/labels{/name}","releases_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/releases{/id}","created_at":"2013-03-07T14:45:24Z","updated_at":"2015-02-24T04:35:40Z","pushed_at":"2015-02-24T04:37:08Z","git_url":"git://github.com/mapbox/mapbox-gl-js.git","ssh_url":"git@github.com:mapbox/mapbox-gl-js.git","clone_url":"https://github.com/mapbox/mapbox-gl-js.git","svn_url":"https://github.com/mapbox/mapbox-gl-js","homepage":"https://www.mapbox.com/mapbox-gl/","size":21156,"stargazers_count":527,"watchers_count":527,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":48,"mirror_url":null,"open_issues_count":135,"forks":48,"open_issues":135,"watchers":527,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/mapbox/mapbox-gl-js/pulls/1026"},"html":{"href":"https://github.com/mapbox/mapbox-gl-js/pull/1026"},"issue":{"href":"https://api.github.com/repos/mapbox/mapbox-gl-js/issues/1026"},"comments":{"href":"https://api.github.com/repos/mapbox/mapbox-gl-js/issues/1026/comments"},"review_comments":{"href":"https://api.github.com/repos/mapbox/mapbox-gl-js/pulls/1026/comments"},"review_comment":{"href":"https://api.github.com/repos/mapbox/mapbox-gl-js/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/mapbox/mapbox-gl-js/pulls/1026/commits"},"statuses":{"href":"https://api.github.com/repos/mapbox/mapbox-gl-js/statuses/9ceb19e6923f58575d916b8d94fc2ee01127e463"}}}}