{"action":"opened","issue":{"url":"https://api.github.com/repos/processing/p5.js/issues/1545","repository_url":"https://api.github.com/repos/processing/p5.js","labels_url":"https://api.github.com/repos/processing/p5.js/issues/1545/labels{/name}","comments_url":"https://api.github.com/repos/processing/p5.js/issues/1545/comments","events_url":"https://api.github.com/repos/processing/p5.js/issues/1545/events","html_url":"https://github.com/processing/p5.js/issues/1545","id":168757244,"number":1545,"title":"Different origin of coordinates in p2d and webgl mode","user":{"login":"roocster","id":6066648,"avatar_url":"https://avatars.githubusercontent.com/u/6066648?v=3","gravatar_id":"","url":"https://api.github.com/users/roocster","html_url":"https://github.com/roocster","followers_url":"https://api.github.com/users/roocster/followers","following_url":"https://api.github.com/users/roocster/following{/other_user}","gists_url":"https://api.github.com/users/roocster/gists{/gist_id}","starred_url":"https://api.github.com/users/roocster/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/roocster/subscriptions","organizations_url":"https://api.github.com/users/roocster/orgs","repos_url":"https://api.github.com/users/roocster/repos","events_url":"https://api.github.com/users/roocster/events{/privacy}","received_events_url":"https://api.github.com/users/roocster/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2016-08-01T22:29:01Z","updated_at":"2016-08-01T22:29:01Z","closed_at":null,"body":"The origin of coordinate system in p2d mode is in the upper left corner. But in webgl mode it is in the center of the canvas.\r\n\r\n```javascript\r\nfunction setup() {\r\n  createCanvas(150, 150);\r\n}\r\n\r\nfunction draw() {\r\n  background(0);\r\n  fill(255);\r\n  rect(0, 0, 10, 10);\r\n}\r\n```\r\n![p2d](https://cloud.githubusercontent.com/assets/6066648/17310933/42c8d822-5850-11e6-8aa3-f89461726222.png)\r\n\r\n```javascript\r\nfunction setup() {\r\n  createCanvas(150, 150, WEBGL);\r\n}\r\n\r\nfunction draw() {\r\n  background(0);\r\n  fill(255);\r\n  rect(0, 0, 10, 10);\r\n}\r\n```\r\n![webgl](https://cloud.githubusercontent.com/assets/6066648/17310947/58f641c0-5850-11e6-9424-57cfbbbf7b3b.png)\r\n"}}
{"actor":{"display_login":"roocster"}}