{"action":"opened","number":1,"pull_request":{"url":"https://api.github.com/repos/savannahniles/Glyph/pulls/1","id":40307898,"html_url":"https://github.com/savannahniles/Glyph/pull/1","diff_url":"https://github.com/savannahniles/Glyph/pull/1.diff","patch_url":"https://github.com/savannahniles/Glyph/pull/1.patch","issue_url":"https://api.github.com/repos/savannahniles/Glyph/issues/1","number":1,"state":"open","locked":false,"title":"Online / On Disk video support ","user":{"login":"Syskaw","id":98829,"avatar_url":"https://avatars.githubusercontent.com/u/98829?v=3","gravatar_id":"","url":"https://api.github.com/users/Syskaw","html_url":"https://github.com/Syskaw","followers_url":"https://api.github.com/users/Syskaw/followers","following_url":"https://api.github.com/users/Syskaw/following{/other_user}","gists_url":"https://api.github.com/users/Syskaw/gists{/gist_id}","starred_url":"https://api.github.com/users/Syskaw/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Syskaw/subscriptions","organizations_url":"https://api.github.com/users/Syskaw/orgs","repos_url":"https://api.github.com/users/Syskaw/repos","events_url":"https://api.github.com/users/Syskaw/events{/privacy}","received_events_url":"https://api.github.com/users/Syskaw/received_events","type":"User","site_admin":false},"body":"it copies/downloads the video input into /static/video \r\ncreated a wrapper for ```var player``` for html5 video\r\n\r\nSometimes thumbnails take time to be generated. Depend of the video.\r\n\r\nI thought of a canvas hack : \r\n```javascript\r\ncurrentTime = player.getCurrentTime(); // keep the current time\r\n\r\n\r\n    var canvasStart = document.createElement('canvas');\r\n    var canvasEnd = document.createElement('canvas');\r\n\r\n    var video = document.getElementById('player-video');\r\n\r\n    player.seekTo(startTime);\r\n     canvasStart.getContext('2d')\r\n                .drawImage(video, 0, 0, video.videoWidth, video.videoHeight)\r\n    var startThumb = canvasStart.toDataURL(\"image/jpeg\", 0.5);\r\n\r\n    player.seekTo(endTime);\r\n    canvasEnd.getContext('2d')\r\n                .drawImage(video, 0, 0, video.videoWidth, video.videoHeight)\r\n    var endThumb = canvasEnd.toDataURL(\"image/jpeg\", 0.5);\r\n\r\n    player.seekTo(currentTime);\r\n\r\n    var startContainer = document.getElementById(\"startFrame\"),\r\n        endContainer = document.getElementById(\"endFrame\");\r\n\r\n    var startThumbnail = document.createElement(\"img\");\r\n  \tstartThumbnail.setAttribute('src', startThumb);\r\n  \tstartThumbnail.setAttribute('class', 'thumb');\r\n  \tvar endThumbnail = document.createElement(\"img\");\r\n  \tendThumbnail.setAttribute('src', endThumb);\r\n  \tendThumbnail.setAttribute('class', 'thumb');\r\n\r\n  \tstartContainer.innerHTML=\"\";\r\n  \tstartContainer.appendChild(startThumbnail);\r\n  \tendContainer.innerHTML=\"\";\r\n  \tendContainer.appendChild(endThumbnail);\r\n```","created_at":"2015-07-19T13:06:23Z","updated_at":"2015-07-19T13:06:23Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d12767ab3247a5bf540640fbc091561b666dcc98","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/savannahniles/Glyph/pulls/1/commits","review_comments_url":"https://api.github.com/repos/savannahniles/Glyph/pulls/1/comments","review_comment_url":"https://api.github.com/repos/savannahniles/Glyph/pulls/comments{/number}","comments_url":"https://api.github.com/repos/savannahniles/Glyph/issues/1/comments","statuses_url":"https://api.github.com/repos/savannahniles/Glyph/statuses/817b10e4b20f7aa0905734efba897e0389ac12e2","head":{"label":"Syskaw:master","ref":"master","sha":"817b10e4b20f7aa0905734efba897e0389ac12e2","user":{"login":"Syskaw","id":98829,"avatar_url":"https://avatars.githubusercontent.com/u/98829?v=3","gravatar_id":"","url":"https://api.github.com/users/Syskaw","html_url":"https://github.com/Syskaw","followers_url":"https://api.github.com/users/Syskaw/followers","following_url":"https://api.github.com/users/Syskaw/following{/other_user}","gists_url":"https://api.github.com/users/Syskaw/gists{/gist_id}","starred_url":"https://api.github.com/users/Syskaw/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Syskaw/subscriptions","organizations_url":"https://api.github.com/users/Syskaw/orgs","repos_url":"https://api.github.com/users/Syskaw/repos","events_url":"https://api.github.com/users/Syskaw/events{/privacy}","received_events_url":"https://api.github.com/users/Syskaw/received_events","type":"User","site_admin":false},"repo":{"id":39263197,"name":"Glyph","full_name":"Syskaw/Glyph","owner":{"login":"Syskaw","id":98829,"avatar_url":"https://avatars.githubusercontent.com/u/98829?v=3","gravatar_id":"","url":"https://api.github.com/users/Syskaw","html_url":"https://github.com/Syskaw","followers_url":"https://api.github.com/users/Syskaw/followers","following_url":"https://api.github.com/users/Syskaw/following{/other_user}","gists_url":"https://api.github.com/users/Syskaw/gists{/gist_id}","starred_url":"https://api.github.com/users/Syskaw/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Syskaw/subscriptions","organizations_url":"https://api.github.com/users/Syskaw/orgs","repos_url":"https://api.github.com/users/Syskaw/repos","events_url":"https://api.github.com/users/Syskaw/events{/privacy}","received_events_url":"https://api.github.com/users/Syskaw/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Syskaw/Glyph","description":"Glyph is a tool for Mac for generating seamlessly looping GIFs and cinemagraphs from videos. http://www.glyph.video/","fork":true,"url":"https://api.github.com/repos/Syskaw/Glyph","forks_url":"https://api.github.com/repos/Syskaw/Glyph/forks","keys_url":"https://api.github.com/repos/Syskaw/Glyph/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Syskaw/Glyph/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Syskaw/Glyph/teams","hooks_url":"https://api.github.com/repos/Syskaw/Glyph/hooks","issue_events_url":"https://api.github.com/repos/Syskaw/Glyph/issues/events{/number}","events_url":"https://api.github.com/repos/Syskaw/Glyph/events","assignees_url":"https://api.github.com/repos/Syskaw/Glyph/assignees{/user}","branches_url":"https://api.github.com/repos/Syskaw/Glyph/branches{/branch}","tags_url":"https://api.github.com/repos/Syskaw/Glyph/tags","blobs_url":"https://api.github.com/repos/Syskaw/Glyph/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Syskaw/Glyph/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Syskaw/Glyph/git/refs{/sha}","trees_url":"https://api.github.com/repos/Syskaw/Glyph/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Syskaw/Glyph/statuses/{sha}","languages_url":"https://api.github.com/repos/Syskaw/Glyph/languages","stargazers_url":"https://api.github.com/repos/Syskaw/Glyph/stargazers","contributors_url":"https://api.github.com/repos/Syskaw/Glyph/contributors","subscribers_url":"https://api.github.com/repos/Syskaw/Glyph/subscribers","subscription_url":"https://api.github.com/repos/Syskaw/Glyph/subscription","commits_url":"https://api.github.com/repos/Syskaw/Glyph/commits{/sha}","git_commits_url":"https://api.github.com/repos/Syskaw/Glyph/git/commits{/sha}","comments_url":"https://api.github.com/repos/Syskaw/Glyph/comments{/number}","issue_comment_url":"https://api.github.com/repos/Syskaw/Glyph/issues/comments{/number}","contents_url":"https://api.github.com/repos/Syskaw/Glyph/contents/{+path}","compare_url":"https://api.github.com/repos/Syskaw/Glyph/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Syskaw/Glyph/merges","archive_url":"https://api.github.com/repos/Syskaw/Glyph/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Syskaw/Glyph/downloads","issues_url":"https://api.github.com/repos/Syskaw/Glyph/issues{/number}","pulls_url":"https://api.github.com/repos/Syskaw/Glyph/pulls{/number}","milestones_url":"https://api.github.com/repos/Syskaw/Glyph/milestones{/number}","notifications_url":"https://api.github.com/repos/Syskaw/Glyph/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Syskaw/Glyph/labels{/name}","releases_url":"https://api.github.com/repos/Syskaw/Glyph/releases{/id}","created_at":"2015-07-17T16:13:22Z","updated_at":"2015-07-17T16:13:24Z","pushed_at":"2015-07-19T12:59:14Z","git_url":"git://github.com/Syskaw/Glyph.git","ssh_url":"git@github.com:Syskaw/Glyph.git","clone_url":"https://github.com/Syskaw/Glyph.git","svn_url":"https://github.com/Syskaw/Glyph","homepage":null,"size":36214,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"savannahniles:master","ref":"master","sha":"8cc8affac743fd92dbdc566f6aedb90e788ba4c5","user":{"login":"savannahniles","id":1447918,"avatar_url":"https://avatars.githubusercontent.com/u/1447918?v=3","gravatar_id":"","url":"https://api.github.com/users/savannahniles","html_url":"https://github.com/savannahniles","followers_url":"https://api.github.com/users/savannahniles/followers","following_url":"https://api.github.com/users/savannahniles/following{/other_user}","gists_url":"https://api.github.com/users/savannahniles/gists{/gist_id}","starred_url":"https://api.github.com/users/savannahniles/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/savannahniles/subscriptions","organizations_url":"https://api.github.com/users/savannahniles/orgs","repos_url":"https://api.github.com/users/savannahniles/repos","events_url":"https://api.github.com/users/savannahniles/events{/privacy}","received_events_url":"https://api.github.com/users/savannahniles/received_events","type":"User","site_admin":false},"repo":{"id":37939093,"name":"Glyph","full_name":"savannahniles/Glyph","owner":{"login":"savannahniles","id":1447918,"avatar_url":"https://avatars.githubusercontent.com/u/1447918?v=3","gravatar_id":"","url":"https://api.github.com/users/savannahniles","html_url":"https://github.com/savannahniles","followers_url":"https://api.github.com/users/savannahniles/followers","following_url":"https://api.github.com/users/savannahniles/following{/other_user}","gists_url":"https://api.github.com/users/savannahniles/gists{/gist_id}","starred_url":"https://api.github.com/users/savannahniles/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/savannahniles/subscriptions","organizations_url":"https://api.github.com/users/savannahniles/orgs","repos_url":"https://api.github.com/users/savannahniles/repos","events_url":"https://api.github.com/users/savannahniles/events{/privacy}","received_events_url":"https://api.github.com/users/savannahniles/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/savannahniles/Glyph","description":"Glyph is a tool for Mac for generating seamlessly looping GIFs and cinemagraphs from videos. http://www.glyph.video/","fork":false,"url":"https://api.github.com/repos/savannahniles/Glyph","forks_url":"https://api.github.com/repos/savannahniles/Glyph/forks","keys_url":"https://api.github.com/repos/savannahniles/Glyph/keys{/key_id}","collaborators_url":"https://api.github.com/repos/savannahniles/Glyph/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/savannahniles/Glyph/teams","hooks_url":"https://api.github.com/repos/savannahniles/Glyph/hooks","issue_events_url":"https://api.github.com/repos/savannahniles/Glyph/issues/events{/number}","events_url":"https://api.github.com/repos/savannahniles/Glyph/events","assignees_url":"https://api.github.com/repos/savannahniles/Glyph/assignees{/user}","branches_url":"https://api.github.com/repos/savannahniles/Glyph/branches{/branch}","tags_url":"https://api.github.com/repos/savannahniles/Glyph/tags","blobs_url":"https://api.github.com/repos/savannahniles/Glyph/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/savannahniles/Glyph/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/savannahniles/Glyph/git/refs{/sha}","trees_url":"https://api.github.com/repos/savannahniles/Glyph/git/trees{/sha}","statuses_url":"https://api.github.com/repos/savannahniles/Glyph/statuses/{sha}","languages_url":"https://api.github.com/repos/savannahniles/Glyph/languages","stargazers_url":"https://api.github.com/repos/savannahniles/Glyph/stargazers","contributors_url":"https://api.github.com/repos/savannahniles/Glyph/contributors","subscribers_url":"https://api.github.com/repos/savannahniles/Glyph/subscribers","subscription_url":"https://api.github.com/repos/savannahniles/Glyph/subscription","commits_url":"https://api.github.com/repos/savannahniles/Glyph/commits{/sha}","git_commits_url":"https://api.github.com/repos/savannahniles/Glyph/git/commits{/sha}","comments_url":"https://api.github.com/repos/savannahniles/Glyph/comments{/number}","issue_comment_url":"https://api.github.com/repos/savannahniles/Glyph/issues/comments{/number}","contents_url":"https://api.github.com/repos/savannahniles/Glyph/contents/{+path}","compare_url":"https://api.github.com/repos/savannahniles/Glyph/compare/{base}...{head}","merges_url":"https://api.github.com/repos/savannahniles/Glyph/merges","archive_url":"https://api.github.com/repos/savannahniles/Glyph/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/savannahniles/Glyph/downloads","issues_url":"https://api.github.com/repos/savannahniles/Glyph/issues{/number}","pulls_url":"https://api.github.com/repos/savannahniles/Glyph/pulls{/number}","milestones_url":"https://api.github.com/repos/savannahniles/Glyph/milestones{/number}","notifications_url":"https://api.github.com/repos/savannahniles/Glyph/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/savannahniles/Glyph/labels{/name}","releases_url":"https://api.github.com/repos/savannahniles/Glyph/releases{/id}","created_at":"2015-06-23T19:06:23Z","updated_at":"2015-07-18T07:31:25Z","pushed_at":"2015-07-19T13:06:24Z","git_url":"git://github.com/savannahniles/Glyph.git","ssh_url":"git@github.com:savannahniles/Glyph.git","clone_url":"https://github.com/savannahniles/Glyph.git","svn_url":"https://github.com/savannahniles/Glyph","homepage":null,"size":36256,"stargazers_count":4,"watchers_count":4,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":1,"forks":1,"open_issues":1,"watchers":4,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/savannahniles/Glyph/pulls/1"},"html":{"href":"https://github.com/savannahniles/Glyph/pull/1"},"issue":{"href":"https://api.github.com/repos/savannahniles/Glyph/issues/1"},"comments":{"href":"https://api.github.com/repos/savannahniles/Glyph/issues/1/comments"},"review_comments":{"href":"https://api.github.com/repos/savannahniles/Glyph/pulls/1/comments"},"review_comment":{"href":"https://api.github.com/repos/savannahniles/Glyph/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/savannahniles/Glyph/pulls/1/commits"},"statuses":{"href":"https://api.github.com/repos/savannahniles/Glyph/statuses/817b10e4b20f7aa0905734efba897e0389ac12e2"}},"merged":false,"mergeable":true,"mergeable_state":"clean","merged_by":null,"comments":0,"review_comments":0,"commits":12,"additions":276,"deletions":133,"changed_files":8}}