{"action":"created","issue":{"url":"https://api.github.com/repos/AnalyticalGraphicsInc/cesium/issues/4684","repository_url":"https://api.github.com/repos/AnalyticalGraphicsInc/cesium","labels_url":"https://api.github.com/repos/AnalyticalGraphicsInc/cesium/issues/4684/labels{/name}","comments_url":"https://api.github.com/repos/AnalyticalGraphicsInc/cesium/issues/4684/comments","events_url":"https://api.github.com/repos/AnalyticalGraphicsInc/cesium/issues/4684/events","html_url":"https://github.com/AnalyticalGraphicsInc/cesium/pull/4684","id":191760056,"number":4684,"title":"3D Tiles: Make KHR_Materials_Common work with batch tables and CESIUM_RTC extensions","user":{"login":"JDepooter","id":1085125,"avatar_url":"https://avatars.githubusercontent.com/u/1085125?v=3","gravatar_id":"","url":"https://api.github.com/users/JDepooter","html_url":"https://github.com/JDepooter","followers_url":"https://api.github.com/users/JDepooter/followers","following_url":"https://api.github.com/users/JDepooter/following{/other_user}","gists_url":"https://api.github.com/users/JDepooter/gists{/gist_id}","starred_url":"https://api.github.com/users/JDepooter/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JDepooter/subscriptions","organizations_url":"https://api.github.com/users/JDepooter/orgs","repos_url":"https://api.github.com/users/JDepooter/repos","events_url":"https://api.github.com/users/JDepooter/events{/privacy}","received_events_url":"https://api.github.com/users/JDepooter/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2016-11-25T20:04:42Z","updated_at":"2016-12-02T20:41:04Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/AnalyticalGraphicsInc/cesium/pulls/4684","html_url":"https://github.com/AnalyticalGraphicsInc/cesium/pull/4684","diff_url":"https://github.com/AnalyticalGraphicsInc/cesium/pull/4684.diff","patch_url":"https://github.com/AnalyticalGraphicsInc/cesium/pull/4684.patch"},"body":"Addresses the problem described in #4669 \r\n\r\nI've updated the code which generates shaders for the KHR_Materials_Common extension. The update addresses two related issues:\r\n- When a batch table is used, a batch id attribute and parameter are needed in the generated vertex shader.\r\n- When the CESIUM_RTC extension is used, the generated shader should use the `CESIUM_RTC_MODELVIEW` semantic for the model view matrix. This change also fixes the shader generation for glTF models loaded via the `Model::fromGltf()` function.\r\n\r\nOne thing I'm not certain is correct is the type of the BATCHID shader parameter. I've set it to `WebGLConstants.UNSIGNED_SHORT`, based on [this link](https://github.com/AnalyticalGraphicsInc/3d-tiles/blob/master/TileFormats/Batched3DModel/README.md). Could anybody comment whether this needs to be adjusted based on the actual data type of the batch id values in the glTF buffer?"},"comment":{"url":"https://api.github.com/repos/AnalyticalGraphicsInc/cesium/issues/comments/264557249","html_url":"https://github.com/AnalyticalGraphicsInc/cesium/pull/4684#issuecomment-264557249","issue_url":"https://api.github.com/repos/AnalyticalGraphicsInc/cesium/issues/4684","id":264557249,"user":{"login":"JDepooter","id":1085125,"avatar_url":"https://avatars.githubusercontent.com/u/1085125?v=3","gravatar_id":"","url":"https://api.github.com/users/JDepooter","html_url":"https://github.com/JDepooter","followers_url":"https://api.github.com/users/JDepooter/followers","following_url":"https://api.github.com/users/JDepooter/following{/other_user}","gists_url":"https://api.github.com/users/JDepooter/gists{/gist_id}","starred_url":"https://api.github.com/users/JDepooter/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JDepooter/subscriptions","organizations_url":"https://api.github.com/users/JDepooter/orgs","repos_url":"https://api.github.com/users/JDepooter/repos","events_url":"https://api.github.com/users/JDepooter/events{/privacy}","received_events_url":"https://api.github.com/users/JDepooter/received_events","type":"User","site_admin":false},"created_at":"2016-12-02T20:41:04Z","updated_at":"2016-12-02T20:41:04Z","body":"@lilleyse I've updated the formatting as requested.\r\n\r\nWith respect to the type of the BATCHID parameter, if the parameter type must match the data type stored in the buffer, there could be situations where multiple shaders would need to be generated per material. If two primitives use the same material, but have different batch id types, they would need different shaders."}}
{"actor":{"display_login":"JDepooter"}}