{"action":"created","issue":{"url":"https://api.github.com/repos/KhronosGroup/glTF/issues/1287","repository_url":"https://api.github.com/repos/KhronosGroup/glTF","labels_url":"https://api.github.com/repos/KhronosGroup/glTF/issues/1287/labels{/name}","comments_url":"https://api.github.com/repos/KhronosGroup/glTF/issues/1287/comments","events_url":"https://api.github.com/repos/KhronosGroup/glTF/issues/1287/events","html_url":"https://github.com/KhronosGroup/glTF/issues/1287","id":305222007,"number":1287,"title":"Animations targeting matrix nodes","user":{"login":"emackey","id":1235080,"avatar_url":"https://avatars2.githubusercontent.com/u/1235080?v=4","gravatar_id":"","url":"https://api.github.com/users/emackey","html_url":"https://github.com/emackey","followers_url":"https://api.github.com/users/emackey/followers","following_url":"https://api.github.com/users/emackey/following{/other_user}","gists_url":"https://api.github.com/users/emackey/gists{/gist_id}","starred_url":"https://api.github.com/users/emackey/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/emackey/subscriptions","organizations_url":"https://api.github.com/users/emackey/orgs","repos_url":"https://api.github.com/users/emackey/repos","events_url":"https://api.github.com/users/emackey/events{/privacy}","received_events_url":"https://api.github.com/users/emackey/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2018-03-14T15:59:22Z","updated_at":"2018-03-14T20:42:57Z","closed_at":null,"author_association":"MEMBER","body":"Our sample models all seem to have animations that target existing properties in nodes.  For example, [AnimatedTriangle line 11](https://github.com/KhronosGroup/glTF-Sample-Models/blob/c589f377c84b4767ef1532e51e92173f47b1eb42/2.0/AnimatedTriangle/glTF-Embedded/AnimatedTriangle.gltf#L11) shows the identity rotation:\r\n\r\n```\r\n\"nodes\" : [\r\n    {\r\n      \"mesh\" : 0,\r\n      \"rotation\" : [ 0.0, 0.0, 0.0, 1.0 ]\r\n    }\r\n  ],\r\n```\r\n\r\nThis `rotation` serves no purpose, but it is the target of an animation that happens later in the same file.\r\n\r\nThe Khronos Blender exporter produces files that don't have this explicit target, and can for example produce an animation that targets a node's rotation, without explicitly including a rotation field in the node in question.\r\n\r\nIs this allowed?  Seems like it should be, and I filed an issue with Cesium to add support for it: https://github.com/AnalyticalGraphicsInc/cesium/issues/6323\r\n\r\nThis raised another question though:  What if the target node uses a `matrix` for orientation, but still has animations targeting things like `rotation`?  The spec disallows use of both in the node definition, but I don't think we disallow an animation from targeting a rotation on a node that only contains a matrix.  Perhaps this is something the validator could look for (or already does?)"},"comment":{"url":"https://api.github.com/repos/KhronosGroup/glTF/issues/comments/373167795","html_url":"https://github.com/KhronosGroup/glTF/issues/1287#issuecomment-373167795","issue_url":"https://api.github.com/repos/KhronosGroup/glTF/issues/1287","id":373167795,"user":{"login":"emackey","id":1235080,"avatar_url":"https://avatars2.githubusercontent.com/u/1235080?v=4","gravatar_id":"","url":"https://api.github.com/users/emackey","html_url":"https://github.com/emackey","followers_url":"https://api.github.com/users/emackey/followers","following_url":"https://api.github.com/users/emackey/following{/other_user}","gists_url":"https://api.github.com/users/emackey/gists{/gist_id}","starred_url":"https://api.github.com/users/emackey/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/emackey/subscriptions","organizations_url":"https://api.github.com/users/emackey/orgs","repos_url":"https://api.github.com/users/emackey/repos","events_url":"https://api.github.com/users/emackey/events{/privacy}","received_events_url":"https://api.github.com/users/emackey/received_events","type":"User","site_admin":false},"created_at":"2018-03-14T20:42:57Z","updated_at":"2018-03-14T20:42:57Z","author_association":"MEMBER","body":"Good question.  If it were supported by glTF, every implementation would have to identify and decompose any matrix on any animated node.  Typically glTF has trended towards placing the burden on the exporter, not the runtime, where possible.  So in this case, the exporter would be responsible for decomposing any matrix as needed to get animatable targets.\r\n\r\nI'm curious to hear other opinions though, if people don't agree with that assessment."}}
{"actor":{"display_login":"emackey"}}