{"action":"created","issue":{"url":"https://api.github.com/repos/KhronosGroup/glTF/issues/694","repository_url":"https://api.github.com/repos/KhronosGroup/glTF","labels_url":"https://api.github.com/repos/KhronosGroup/glTF/issues/694/labels{/name}","comments_url":"https://api.github.com/repos/KhronosGroup/glTF/issues/694/comments","events_url":"https://api.github.com/repos/KhronosGroup/glTF/issues/694/events","html_url":"https://github.com/KhronosGroup/glTF/issues/694","id":173227573,"number":694,"title":"Multiple meshes - No indices","user":{"login":"konashredbiker","id":8532131,"avatar_url":"https://avatars.githubusercontent.com/u/8532131?v=3","gravatar_id":"","url":"https://api.github.com/users/konashredbiker","html_url":"https://github.com/konashredbiker","followers_url":"https://api.github.com/users/konashredbiker/followers","following_url":"https://api.github.com/users/konashredbiker/following{/other_user}","gists_url":"https://api.github.com/users/konashredbiker/gists{/gist_id}","starred_url":"https://api.github.com/users/konashredbiker/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/konashredbiker/subscriptions","organizations_url":"https://api.github.com/users/konashredbiker/orgs","repos_url":"https://api.github.com/users/konashredbiker/repos","events_url":"https://api.github.com/users/konashredbiker/events{/privacy}","received_events_url":"https://api.github.com/users/konashredbiker/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2016-08-25T15:00:55Z","updated_at":"2016-08-26T12:32:44Z","closed_at":null,"body":"When using flatshading for all meshes, vertices have to be duplicated with one normal for each face. Then having indices doesn't make sense anymore, because it increases the file size.\r\nBut storing multiple meshes in one glTF without indices results in an error. Only one mesh shows up. While debugging Cesium, I can see that multiple meshes are loaded and this error message occurs while rendering:\r\n\r\n[.CommandBufferContext]GL ERROR :GL_INVALID_OPERATION : glDrawArrays: attempt to access out of range vertices in attribute 1\r\n\r\nWhen debugging Cesium in Context.js line 934 [context._gl.drawArrays(primitiveType, offset, count);]  a different offset is used than defined in the glTF file.\r\nIn the example three Cubes are saved, but when loading the file only the first one is rendered.\r\nIs this not possible in glTF or is it not implemented in Cesium? Or did I write the glTF wrong?\r\n\r\n[testMulti.zip](https://github.com/KhronosGroup/glTF/files/437310/testMulti.zip)"},"comment":{"url":"https://api.github.com/repos/KhronosGroup/glTF/issues/comments/242722983","html_url":"https://github.com/KhronosGroup/glTF/issues/694#issuecomment-242722983","issue_url":"https://api.github.com/repos/KhronosGroup/glTF/issues/694","id":242722983,"user":{"login":"konashredbiker","id":8532131,"avatar_url":"https://avatars.githubusercontent.com/u/8532131?v=3","gravatar_id":"","url":"https://api.github.com/users/konashredbiker","html_url":"https://github.com/konashredbiker","followers_url":"https://api.github.com/users/konashredbiker/followers","following_url":"https://api.github.com/users/konashredbiker/following{/other_user}","gists_url":"https://api.github.com/users/konashredbiker/gists{/gist_id}","starred_url":"https://api.github.com/users/konashredbiker/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/konashredbiker/subscriptions","organizations_url":"https://api.github.com/users/konashredbiker/orgs","repos_url":"https://api.github.com/users/konashredbiker/repos","events_url":"https://api.github.com/users/konashredbiker/events{/privacy}","received_events_url":"https://api.github.com/users/konashredbiker/received_events","type":"User","site_admin":false},"created_at":"2016-08-26T12:32:44Z","updated_at":"2016-08-26T12:32:44Z","body":"Thank you for testing it. I double checked it with the three.js loader and it didn't work, but maybe the loader doesn't support non indexed models at all.\r\nSo is this just a Cesium issue?\r\n\r\nThe slightly off positions and the resulting normals came from Blender or the export plugin for Blender. I fixed the input by hand and now the results are a bit nicer.\r\n[testMulti.zip](https://github.com/KhronosGroup/glTF/files/439238/testMulti.zip)\r\n"}}
{"actor":{"display_login":"konashredbiker"}}