{"action":"created","issue":{"url":"https://api.github.com/repos/videojs/videojs-vr/issues/142","repository_url":"https://api.github.com/repos/videojs/videojs-vr","labels_url":"https://api.github.com/repos/videojs/videojs-vr/issues/142/labels{/name}","comments_url":"https://api.github.com/repos/videojs/videojs-vr/issues/142/comments","events_url":"https://api.github.com/repos/videojs/videojs-vr/issues/142/events","html_url":"https://github.com/videojs/videojs-vr/issues/142","id":365620718,"node_id":"MDU6SXNzdWUzNjU2MjA3MTg=","number":142,"title":"Switching Video Sources between 360 and non 360 and back results in projection not occurring.","user":{"login":"AndrewStobie","id":28308300,"node_id":"MDQ6VXNlcjI4MzA4MzAw","avatar_url":"https://avatars1.githubusercontent.com/u/28308300?v=4","gravatar_id":"","url":"https://api.github.com/users/AndrewStobie","html_url":"https://github.com/AndrewStobie","followers_url":"https://api.github.com/users/AndrewStobie/followers","following_url":"https://api.github.com/users/AndrewStobie/following{/other_user}","gists_url":"https://api.github.com/users/AndrewStobie/gists{/gist_id}","starred_url":"https://api.github.com/users/AndrewStobie/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AndrewStobie/subscriptions","organizations_url":"https://api.github.com/users/AndrewStobie/orgs","repos_url":"https://api.github.com/users/AndrewStobie/repos","events_url":"https://api.github.com/users/AndrewStobie/events{/privacy}","received_events_url":"https://api.github.com/users/AndrewStobie/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":5,"created_at":"2018-10-01T20:04:08Z","updated_at":"2018-11-23T18:01:45Z","closed_at":"2018-11-07T15:56:37Z","author_association":"NONE","body":"## Description\r\nChanging between sources that are 360 projections and NONE projections and then back to 360 loads the 360 in the last step as NONE projection with no interactivity\r\n\r\n## Steps to reproduce\r\n\r\n1. Load a video with mediainfo.projection = '360' and vr({projection: 'AUTO'});\r\n2. Load a video with mediainfo.projection = 'NONE' and vr({projection: 'AUTO'});\r\n3. load again the first video setting mediainfo.projection = '360' and vr({projection: 'AUTO'});\r\n\r\n## Results\r\n### Expected\r\nTo see the same 360 projection on the 360 video\r\n\r\n### Actual\r\nthe flat non-projected equirectangular video with no tranformation\r\n\r\n### Error output\r\nNone specific to this issue\r\n\r\n## Additional Information\r\nPlease include any additional information necessary here. Including the following:\r\n\r\n### versions\r\n#### videojs\r\nwhat version of videojs does this occur with? 7.2.2 with http-streaming and videojs-vr 1.5.0\r\n\r\n#### browsers\r\nwhat browser are affected?\r\nchrome on mac, chrome on android pie, safari on mac, safari on iOS, haven't tested FF yet\r\n\r\n#### OSes\r\nwhat platforms (operating systems and devices) are affected?\r\nMac OS Mojave, iOS12, Android Pie at minimum\r\n\r\n### plugins\r\nare any videojs plugins being used on the page? If so, please list them below.\r\nvideojs-vr 1.5.0\r\n"},"comment":{"url":"https://api.github.com/repos/videojs/videojs-vr/issues/comments/441296458","html_url":"https://github.com/videojs/videojs-vr/issues/142#issuecomment-441296458","issue_url":"https://api.github.com/repos/videojs/videojs-vr/issues/142","id":441296458,"node_id":"MDEyOklzc3VlQ29tbWVudDQ0MTI5NjQ1OA==","user":{"login":"funkmeisterb","id":494074,"node_id":"MDQ6VXNlcjQ5NDA3NA==","avatar_url":"https://avatars0.githubusercontent.com/u/494074?v=4","gravatar_id":"","url":"https://api.github.com/users/funkmeisterb","html_url":"https://github.com/funkmeisterb","followers_url":"https://api.github.com/users/funkmeisterb/followers","following_url":"https://api.github.com/users/funkmeisterb/following{/other_user}","gists_url":"https://api.github.com/users/funkmeisterb/gists{/gist_id}","starred_url":"https://api.github.com/users/funkmeisterb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/funkmeisterb/subscriptions","organizations_url":"https://api.github.com/users/funkmeisterb/orgs","repos_url":"https://api.github.com/users/funkmeisterb/repos","events_url":"https://api.github.com/users/funkmeisterb/events{/privacy}","received_events_url":"https://api.github.com/users/funkmeisterb/received_events","type":"User","site_admin":false},"created_at":"2018-11-23T18:01:45Z","updated_at":"2018-11-23T18:01:45Z","author_association":"NONE","body":"Here is a quick fix:\r\n\r\n```\r\n    <script>\r\n    $(document).ready(function(){\r\n        $(\"#btn-vr\").click(function(){\r\n            console.log(\"LOAD VR!\");\r\n            var player = videojs('test-videojs');\r\n            player.src({ src: 'vr.mp4' });\r\n            player.mediainfo = player.mediainfo || {};\r\n            player.mediainfo.projection = '360';\r\n            player.vr({projection: 'AUTO', debug: false, forceCardboard: false});\r\n            player.play();\r\n            try {\r\n                player.vr().changeProjection_(\"Sphere\");\r\n            }\r\n            catch(err) {\r\n                console.log(\"Error caught!\");\r\n            }\r\n        });\r\n        $(\"#btn-2d\").click(function(){\r\n            console.log(\"LOAD 2D!\");\r\n            var player = videojs('test-videojs');\r\n            player.src({ src: 'BigBuckBunny.mp4' });\r\n            player.mediainfo = player.mediainfo || {};\r\n            player.mediainfo.projection = 'NONE';\r\n            player.vr({projection: 'AUTO', debug: false, forceCardboard: false});\r\n            player.play();\r\n        });\r\n    });\r\n    </script>\r\n```"}}
{"actor":{"display_login":"funkmeisterb"}}