{"action":"created","issue":{"url":"https://api.github.com/repos/adamwulf/JotUI/issues/38","repository_url":"https://api.github.com/repos/adamwulf/JotUI","labels_url":"https://api.github.com/repos/adamwulf/JotUI/issues/38/labels{/name}","comments_url":"https://api.github.com/repos/adamwulf/JotUI/issues/38/comments","events_url":"https://api.github.com/repos/adamwulf/JotUI/issues/38/events","html_url":"https://github.com/adamwulf/JotUI/issues/38","id":408422424,"node_id":"MDU6SXNzdWU0MDg0MjI0MjQ=","number":38,"title":"Crashed on OpenGLException: currentContext must be a JotGLContext'","user":{"login":"OrcaData","id":9023044,"node_id":"MDQ6VXNlcjkwMjMwNDQ=","avatar_url":"https://avatars1.githubusercontent.com/u/9023044?v=4","gravatar_id":"","url":"https://api.github.com/users/OrcaData","html_url":"https://github.com/OrcaData","followers_url":"https://api.github.com/users/OrcaData/followers","following_url":"https://api.github.com/users/OrcaData/following{/other_user}","gists_url":"https://api.github.com/users/OrcaData/gists{/gist_id}","starred_url":"https://api.github.com/users/OrcaData/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/OrcaData/subscriptions","organizations_url":"https://api.github.com/users/OrcaData/orgs","repos_url":"https://api.github.com/users/OrcaData/repos","events_url":"https://api.github.com/users/OrcaData/events{/privacy}","received_events_url":"https://api.github.com/users/OrcaData/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2019-02-09T11:20:42Z","updated_at":"2019-02-11T08:40:33Z","closed_at":null,"author_association":"NONE","body":"Hello Adam,\r\n\r\n\r\n\r\nMy project creates a viewController for user to draw, and a button on the view to call self.dismissViewControllerAnimated to close it and save to disk. When I use saveImage and dismiss the viewController, the next time I create a new viewController, the crash happened. Without saveImage executed, everything works fine. \r\n\r\n*** Terminating app due to uncaught exception 'OpenGLException', reason: 'currentContext must be a JotGLContext'\r\n\r\nI found that whenever saveImage get called, the next time below lines of code runs cause the problem.\r\n  [paperState loadJotStateAsynchronously:NO withSize:jotView.bounds.size andScale:[[UIScreen mainScreen] scale] andContext:jotView.context andBufferManager:[JotBufferManager sharedInstance]];\r\n\r\nAny suggestions on finding solutions about this issue? Many thanks."},"comment":{"url":"https://api.github.com/repos/adamwulf/JotUI/issues/comments/462251460","html_url":"https://github.com/adamwulf/JotUI/issues/38#issuecomment-462251460","issue_url":"https://api.github.com/repos/adamwulf/JotUI/issues/38","id":462251460,"node_id":"MDEyOklzc3VlQ29tbWVudDQ2MjI1MTQ2MA==","user":{"login":"OrcaData","id":9023044,"node_id":"MDQ6VXNlcjkwMjMwNDQ=","avatar_url":"https://avatars1.githubusercontent.com/u/9023044?v=4","gravatar_id":"","url":"https://api.github.com/users/OrcaData","html_url":"https://github.com/OrcaData","followers_url":"https://api.github.com/users/OrcaData/followers","following_url":"https://api.github.com/users/OrcaData/following{/other_user}","gists_url":"https://api.github.com/users/OrcaData/gists{/gist_id}","starred_url":"https://api.github.com/users/OrcaData/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/OrcaData/subscriptions","organizations_url":"https://api.github.com/users/OrcaData/orgs","repos_url":"https://api.github.com/users/OrcaData/repos","events_url":"https://api.github.com/users/OrcaData/events{/privacy}","received_events_url":"https://api.github.com/users/OrcaData/received_events","type":"User","site_admin":false},"created_at":"2019-02-11T08:40:33Z","updated_at":"2019-02-11T08:40:33Z","author_association":"NONE","body":"Thanks, Adam. I tried building a MainViewController and assigned a button present the JotViewController to perform drawing. And when I dismissed the JotView and opens another JotViewController, the memory increased 50MB. Every time I call a new JotView, it eats 50MB - 80MB. I'm using ARC, so the ViewController should be deallocated. I'm wondering if I can call some method to release memory usage. Is that something to do with JotBufferManager?"}}
{"actor":{"display_login":"OrcaData"}}