{"action":"created","comment":{"url":"https://api.github.com/repos/googlesamples/android-ndk/pulls/comments/36503633","id":36503633,"diff_hunk":"@@ -0,0 +1,205 @@\n+Endless Tunnel\n+==============\n+Endless Tunnel is a sample game that shows how to:\n+- use the Android Studio C++ support\n+- implement a game using Android native glue\n+- implement joystick support, including robust DPAD navigation for no-touch screens\n+\n+It is NOT the goal of this sample to show the best way to write the\n+game logic, load resources, etc. The game itself was intentionally\n+kept rudimentary in order to keep the focus on the Android Studio C++\n+integration. For example, this game contains textures and geometry\n+hard-coded in code, which works for small demo games like this one,\n+but doesn't scale well to real games.\n+\n+Pre-requisites\n+--------------\n+- Android Studio 1.3 with [NDK](https://developer.android.com/ndk/) bundle.\n+\n+Getting Started\n+---------------\n+1. [Download Android Studio](http://developer.android.com/sdk/index.html)\n+1. Launch Android Studio.\n+1. Open the sample directory.\n+1. Open *File/Project Structure...*\n+  1. Click *Download* or *Select NDK location*.\n+  1. Click *Tools/Android/Sync Project with Gradle Files*.\n+  1. Click *Run/Run 'app'*.\n+\n+Screenshots\n+-----------\n+![screenshot](screenshot.png)\n+\n+Dependencies\n+------------\n+### GLM LIBRARY\n+\n+This project uses the OpenGL Mathematics (GLM) library, available at:\n+\n+    http://glm.g-truc.net/\n+\n+For more information about this library and its license, please see\n+Tunnel/jni/glm/readme.txt and Tunnel/jni/glm/copying.txt.\n+\n+Acknowledgements\n+----------------\n+Most of this code was written by [Bruno Oliveira](https://plus.google.com/+BrunoOliveira).\n+\n+Walkthrough\n+-----------\n+Source code are under app, it only contains C++ code, which is\n+sitting at its default location (same as for other samples) at\n+app/jni.\n+\n+The game starts at the android_main function in \n+jni/engine/native-activity.app, like any standard NDK game.\n+\n+### Scenes And The Scene Manager\n+\n+We have a singleton class called SceneManager. As the name says, it's\n+the class that manages scenes. There's always an active Scene, and\n+the scene determines what's visible onscreen and how the game reacts\n+to input. The main menu is a scene, the gameplay is another scene.\n+\n+As the game runs, the display might be initialized and terminated\n+multiple times, corresponding, for example, to the app losing focus\n+and being brought back into focus. This is why the SceneManager\n+(and the Scene's) have the notion of StartGraphics() and KillGraphics().\n+These two methods may be called multiple times along the lifetime of\n+a scene. So everything that has to do with graphics context (like\n+shaders, textures, etc) has to be initialized in StartGraphics(), \n+and has to be torn down in KillGraphics().\n+\n+The engine_init_display function is where we set up OpenGL\n+for our game, and call StartGraphics() on the active scene.\n+The engine_term_display is where we call KillGraphics() on the active\n+scene.\n+\n+Input arrives by way of the engine_handle_input function, which\n+does some basic input classification and delivers the input to\n+the scene manager. Incidentally, here we also synthethise DPAD events based","path":"endless-tunnel/README.md","position":null,"original_position":80,"commit_id":"0adc558a1081d1ee43cfbc875f23df0d9fcc8f66","original_commit_id":"a7b527fa5eaf2532c73c63b48fec932043c1b6c8","user":{"login":"proppy","id":5268,"avatar_url":"https://avatars.githubusercontent.com/u/5268?v=3","gravatar_id":"","url":"https://api.github.com/users/proppy","html_url":"https://github.com/proppy","followers_url":"https://api.github.com/users/proppy/followers","following_url":"https://api.github.com/users/proppy/following{/other_user}","gists_url":"https://api.github.com/users/proppy/gists{/gist_id}","starred_url":"https://api.github.com/users/proppy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/proppy/subscriptions","organizations_url":"https://api.github.com/users/proppy/orgs","repos_url":"https://api.github.com/users/proppy/repos","events_url":"https://api.github.com/users/proppy/events{/privacy}","received_events_url":"https://api.github.com/users/proppy/received_events","type":"User","site_admin":false},"body":"Done.","created_at":"2015-08-07T09:25:14Z","updated_at":"2015-08-07T09:25:14Z","html_url":"https://github.com/googlesamples/android-ndk/pull/54#discussion_r36503633","pull_request_url":"https://api.github.com/repos/googlesamples/android-ndk/pulls/54","_links":{"self":{"href":"https://api.github.com/repos/googlesamples/android-ndk/pulls/comments/36503633"},"html":{"href":"https://github.com/googlesamples/android-ndk/pull/54#discussion_r36503633"},"pull_request":{"href":"https://api.github.com/repos/googlesamples/android-ndk/pulls/54"}}},"pull_request":{"url":"https://api.github.com/repos/googlesamples/android-ndk/pulls/54","id":41760401,"html_url":"https://github.com/googlesamples/android-ndk/pull/54","diff_url":"https://github.com/googlesamples/android-ndk/pull/54.diff","patch_url":"https://github.com/googlesamples/android-ndk/pull/54.patch","issue_url":"https://api.github.com/repos/googlesamples/android-ndk/issues/54","number":54,"state":"open","locked":false,"title":"Update README for all samples","user":{"login":"proppy","id":5268,"avatar_url":"https://avatars.githubusercontent.com/u/5268?v=3","gravatar_id":"","url":"https://api.github.com/users/proppy","html_url":"https://github.com/proppy","followers_url":"https://api.github.com/users/proppy/followers","following_url":"https://api.github.com/users/proppy/following{/other_user}","gists_url":"https://api.github.com/users/proppy/gists{/gist_id}","starred_url":"https://api.github.com/users/proppy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/proppy/subscriptions","organizations_url":"https://api.github.com/users/proppy/orgs","repos_url":"https://api.github.com/users/proppy/repos","events_url":"https://api.github.com/users/proppy/events{/privacy}","received_events_url":"https://api.github.com/users/proppy/received_events","type":"User","site_admin":false},"body":"Fixes #11\r\n\r\n/cc @ggfan @hak \r\n\r\n@thedmail do you have time to take a look at this and proof read the prose (esp. for the first paragraph of each sample)? Not being an english native speaker, I often have doubt about my formulation.\r\n","created_at":"2015-08-06T07:50:35Z","updated_at":"2015-08-07T09:25:14Z","closed_at":null,"merged_at":null,"merge_commit_sha":"74e17034f3312443b3be835f74ca3491f6e91942","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/googlesamples/android-ndk/pulls/54/commits","review_comments_url":"https://api.github.com/repos/googlesamples/android-ndk/pulls/54/comments","review_comment_url":"https://api.github.com/repos/googlesamples/android-ndk/pulls/comments{/number}","comments_url":"https://api.github.com/repos/googlesamples/android-ndk/issues/54/comments","statuses_url":"https://api.github.com/repos/googlesamples/android-ndk/statuses/0adc558a1081d1ee43cfbc875f23df0d9fcc8f66","head":{"label":"proppy:update-readme","ref":"update-readme","sha":"0adc558a1081d1ee43cfbc875f23df0d9fcc8f66","user":{"login":"proppy","id":5268,"avatar_url":"https://avatars.githubusercontent.com/u/5268?v=3","gravatar_id":"","url":"https://api.github.com/users/proppy","html_url":"https://github.com/proppy","followers_url":"https://api.github.com/users/proppy/followers","following_url":"https://api.github.com/users/proppy/following{/other_user}","gists_url":"https://api.github.com/users/proppy/gists{/gist_id}","starred_url":"https://api.github.com/users/proppy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/proppy/subscriptions","organizations_url":"https://api.github.com/users/proppy/orgs","repos_url":"https://api.github.com/users/proppy/repos","events_url":"https://api.github.com/users/proppy/events{/privacy}","received_events_url":"https://api.github.com/users/proppy/received_events","type":"User","site_admin":false},"repo":{"id":37485183,"name":"android-ndk","full_name":"proppy/android-ndk","owner":{"login":"proppy","id":5268,"avatar_url":"https://avatars.githubusercontent.com/u/5268?v=3","gravatar_id":"","url":"https://api.github.com/users/proppy","html_url":"https://github.com/proppy","followers_url":"https://api.github.com/users/proppy/followers","following_url":"https://api.github.com/users/proppy/following{/other_user}","gists_url":"https://api.github.com/users/proppy/gists{/gist_id}","starred_url":"https://api.github.com/users/proppy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/proppy/subscriptions","organizations_url":"https://api.github.com/users/proppy/orgs","repos_url":"https://api.github.com/users/proppy/repos","events_url":"https://api.github.com/users/proppy/events{/privacy}","received_events_url":"https://api.github.com/users/proppy/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/proppy/android-ndk","description":"","fork":true,"url":"https://api.github.com/repos/proppy/android-ndk","forks_url":"https://api.github.com/repos/proppy/android-ndk/forks","keys_url":"https://api.github.com/repos/proppy/android-ndk/keys{/key_id}","collaborators_url":"https://api.github.com/repos/proppy/android-ndk/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/proppy/android-ndk/teams","hooks_url":"https://api.github.com/repos/proppy/android-ndk/hooks","issue_events_url":"https://api.github.com/repos/proppy/android-ndk/issues/events{/number}","events_url":"https://api.github.com/repos/proppy/android-ndk/events","assignees_url":"https://api.github.com/repos/proppy/android-ndk/assignees{/user}","branches_url":"https://api.github.com/repos/proppy/android-ndk/branches{/branch}","tags_url":"https://api.github.com/repos/proppy/android-ndk/tags","blobs_url":"https://api.github.com/repos/proppy/android-ndk/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/proppy/android-ndk/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/proppy/android-ndk/git/refs{/sha}","trees_url":"https://api.github.com/repos/proppy/android-ndk/git/trees{/sha}","statuses_url":"https://api.github.com/repos/proppy/android-ndk/statuses/{sha}","languages_url":"https://api.github.com/repos/proppy/android-ndk/languages","stargazers_url":"https://api.github.com/repos/proppy/android-ndk/stargazers","contributors_url":"https://api.github.com/repos/proppy/android-ndk/contributors","subscribers_url":"https://api.github.com/repos/proppy/android-ndk/subscribers","subscription_url":"https://api.github.com/repos/proppy/android-ndk/subscription","commits_url":"https://api.github.com/repos/proppy/android-ndk/commits{/sha}","git_commits_url":"https://api.github.com/repos/proppy/android-ndk/git/commits{/sha}","comments_url":"https://api.github.com/repos/proppy/android-ndk/comments{/number}","issue_comment_url":"https://api.github.com/repos/proppy/android-ndk/issues/comments{/number}","contents_url":"https://api.github.com/repos/proppy/android-ndk/contents/{+path}","compare_url":"https://api.github.com/repos/proppy/android-ndk/compare/{base}...{head}","merges_url":"https://api.github.com/repos/proppy/android-ndk/merges","archive_url":"https://api.github.com/repos/proppy/android-ndk/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/proppy/android-ndk/downloads","issues_url":"https://api.github.com/repos/proppy/android-ndk/issues{/number}","pulls_url":"https://api.github.com/repos/proppy/android-ndk/pulls{/number}","milestones_url":"https://api.github.com/repos/proppy/android-ndk/milestones{/number}","notifications_url":"https://api.github.com/repos/proppy/android-ndk/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/proppy/android-ndk/labels{/name}","releases_url":"https://api.github.com/repos/proppy/android-ndk/releases{/id}","created_at":"2015-06-15T19:03:21Z","updated_at":"2015-06-15T19:03:21Z","pushed_at":"2015-08-07T09:24:51Z","git_url":"git://github.com/proppy/android-ndk.git","ssh_url":"git@github.com:proppy/android-ndk.git","clone_url":"https://github.com/proppy/android-ndk.git","svn_url":"https://github.com/proppy/android-ndk","homepage":null,"size":38164,"stargazers_count":0,"watchers_count":0,"language":"C++","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":"googlesamples:master","ref":"master","sha":"da8d432aef4dddbfe81961ca5d8f48c765ef5d7f","user":{"login":"googlesamples","id":7378196,"avatar_url":"https://avatars.githubusercontent.com/u/7378196?v=3","gravatar_id":"","url":"https://api.github.com/users/googlesamples","html_url":"https://github.com/googlesamples","followers_url":"https://api.github.com/users/googlesamples/followers","following_url":"https://api.github.com/users/googlesamples/following{/other_user}","gists_url":"https://api.github.com/users/googlesamples/gists{/gist_id}","starred_url":"https://api.github.com/users/googlesamples/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/googlesamples/subscriptions","organizations_url":"https://api.github.com/users/googlesamples/orgs","repos_url":"https://api.github.com/users/googlesamples/repos","events_url":"https://api.github.com/users/googlesamples/events{/privacy}","received_events_url":"https://api.github.com/users/googlesamples/received_events","type":"Organization","site_admin":false},"repo":{"id":35718695,"name":"android-ndk","full_name":"googlesamples/android-ndk","owner":{"login":"googlesamples","id":7378196,"avatar_url":"https://avatars.githubusercontent.com/u/7378196?v=3","gravatar_id":"","url":"https://api.github.com/users/googlesamples","html_url":"https://github.com/googlesamples","followers_url":"https://api.github.com/users/googlesamples/followers","following_url":"https://api.github.com/users/googlesamples/following{/other_user}","gists_url":"https://api.github.com/users/googlesamples/gists{/gist_id}","starred_url":"https://api.github.com/users/googlesamples/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/googlesamples/subscriptions","organizations_url":"https://api.github.com/users/googlesamples/orgs","repos_url":"https://api.github.com/users/googlesamples/repos","events_url":"https://api.github.com/users/googlesamples/events{/privacy}","received_events_url":"https://api.github.com/users/googlesamples/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/googlesamples/android-ndk","description":"","fork":false,"url":"https://api.github.com/repos/googlesamples/android-ndk","forks_url":"https://api.github.com/repos/googlesamples/android-ndk/forks","keys_url":"https://api.github.com/repos/googlesamples/android-ndk/keys{/key_id}","collaborators_url":"https://api.github.com/repos/googlesamples/android-ndk/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/googlesamples/android-ndk/teams","hooks_url":"https://api.github.com/repos/googlesamples/android-ndk/hooks","issue_events_url":"https://api.github.com/repos/googlesamples/android-ndk/issues/events{/number}","events_url":"https://api.github.com/repos/googlesamples/android-ndk/events","assignees_url":"https://api.github.com/repos/googlesamples/android-ndk/assignees{/user}","branches_url":"https://api.github.com/repos/googlesamples/android-ndk/branches{/branch}","tags_url":"https://api.github.com/repos/googlesamples/android-ndk/tags","blobs_url":"https://api.github.com/repos/googlesamples/android-ndk/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/googlesamples/android-ndk/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/googlesamples/android-ndk/git/refs{/sha}","trees_url":"https://api.github.com/repos/googlesamples/android-ndk/git/trees{/sha}","statuses_url":"https://api.github.com/repos/googlesamples/android-ndk/statuses/{sha}","languages_url":"https://api.github.com/repos/googlesamples/android-ndk/languages","stargazers_url":"https://api.github.com/repos/googlesamples/android-ndk/stargazers","contributors_url":"https://api.github.com/repos/googlesamples/android-ndk/contributors","subscribers_url":"https://api.github.com/repos/googlesamples/android-ndk/subscribers","subscription_url":"https://api.github.com/repos/googlesamples/android-ndk/subscription","commits_url":"https://api.github.com/repos/googlesamples/android-ndk/commits{/sha}","git_commits_url":"https://api.github.com/repos/googlesamples/android-ndk/git/commits{/sha}","comments_url":"https://api.github.com/repos/googlesamples/android-ndk/comments{/number}","issue_comment_url":"https://api.github.com/repos/googlesamples/android-ndk/issues/comments{/number}","contents_url":"https://api.github.com/repos/googlesamples/android-ndk/contents/{+path}","compare_url":"https://api.github.com/repos/googlesamples/android-ndk/compare/{base}...{head}","merges_url":"https://api.github.com/repos/googlesamples/android-ndk/merges","archive_url":"https://api.github.com/repos/googlesamples/android-ndk/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/googlesamples/android-ndk/downloads","issues_url":"https://api.github.com/repos/googlesamples/android-ndk/issues{/number}","pulls_url":"https://api.github.com/repos/googlesamples/android-ndk/pulls{/number}","milestones_url":"https://api.github.com/repos/googlesamples/android-ndk/milestones{/number}","notifications_url":"https://api.github.com/repos/googlesamples/android-ndk/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/googlesamples/android-ndk/labels{/name}","releases_url":"https://api.github.com/repos/googlesamples/android-ndk/releases{/id}","created_at":"2015-05-16T10:02:15Z","updated_at":"2015-08-07T08:38:24Z","pushed_at":"2015-08-07T09:24:52Z","git_url":"git://github.com/googlesamples/android-ndk.git","ssh_url":"git@github.com:googlesamples/android-ndk.git","clone_url":"https://github.com/googlesamples/android-ndk.git","svn_url":"https://github.com/googlesamples/android-ndk","homepage":null,"size":17321,"stargazers_count":227,"watchers_count":227,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":45,"mirror_url":null,"open_issues_count":17,"forks":45,"open_issues":17,"watchers":227,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/googlesamples/android-ndk/pulls/54"},"html":{"href":"https://github.com/googlesamples/android-ndk/pull/54"},"issue":{"href":"https://api.github.com/repos/googlesamples/android-ndk/issues/54"},"comments":{"href":"https://api.github.com/repos/googlesamples/android-ndk/issues/54/comments"},"review_comments":{"href":"https://api.github.com/repos/googlesamples/android-ndk/pulls/54/comments"},"review_comment":{"href":"https://api.github.com/repos/googlesamples/android-ndk/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/googlesamples/android-ndk/pulls/54/commits"},"statuses":{"href":"https://api.github.com/repos/googlesamples/android-ndk/statuses/0adc558a1081d1ee43cfbc875f23df0d9fcc8f66"}}}}