{"action":"closed","number":7431,"pull_request":{"url":"https://api.github.com/repos/mrdoob/three.js/pulls/7431","id":48661882,"html_url":"https://github.com/mrdoob/three.js/pull/7431","diff_url":"https://github.com/mrdoob/three.js/pull/7431.diff","patch_url":"https://github.com/mrdoob/three.js/pull/7431.patch","issue_url":"https://api.github.com/repos/mrdoob/three.js/issues/7431","number":7431,"state":"closed","locked":false,"title":"Ignore empty entries in MTL files","user":{"login":"jensarps","id":178141,"avatar_url":"https://avatars.githubusercontent.com/u/178141?v=3","gravatar_id":"","url":"https://api.github.com/users/jensarps","html_url":"https://github.com/jensarps","followers_url":"https://api.github.com/users/jensarps/followers","following_url":"https://api.github.com/users/jensarps/following{/other_user}","gists_url":"https://api.github.com/users/jensarps/gists{/gist_id}","starred_url":"https://api.github.com/users/jensarps/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jensarps/subscriptions","organizations_url":"https://api.github.com/users/jensarps/orgs","repos_url":"https://api.github.com/users/jensarps/repos","events_url":"https://api.github.com/users/jensarps/events{/privacy}","received_events_url":"https://api.github.com/users/jensarps/received_events","type":"User","site_admin":false},"body":"Every so often I stumble upon .mtl files that contain definitions that look like this:\r\n\r\n```\r\nnewmtl Material__73\r\nKa 0.156863 0.156863 0.156863\r\nKd 0.156863 0.156863 0.156863\r\nKs 0 0 0\r\nillum 2\r\nNs 128\r\nmap_Kd \r\nmap_bump \r\nbump \r\nmap_opacity \r\nmap_d \r\nrefl \r\nmap_kS \r\nmap_kA \r\nmap_Ns \r\n```\r\n\r\nCurrently, a definition like this will lead to an unexpected material being created, as it will have all of the properties, but with empty values (including maps).\r\n\r\nWhile this is technically an issue of the exporter that generated the file, just skipping those empty entries is a small fix, and will lead to less headaches for developers importing models.","created_at":"2015-10-24T18:20:30Z","updated_at":"2015-10-24T19:52:39Z","closed_at":"2015-10-24T19:52:39Z","merged_at":"2015-10-24T19:52:39Z","merge_commit_sha":"8bbc5d6ddf7e87909df7a6d8c8877c126576b43e","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/mrdoob/three.js/pulls/7431/commits","review_comments_url":"https://api.github.com/repos/mrdoob/three.js/pulls/7431/comments","review_comment_url":"https://api.github.com/repos/mrdoob/three.js/pulls/comments{/number}","comments_url":"https://api.github.com/repos/mrdoob/three.js/issues/7431/comments","statuses_url":"https://api.github.com/repos/mrdoob/three.js/statuses/91370c6e097227812732fc9809e272046123333b","head":{"label":"jensarps:ignore-empty-mtl-entries","ref":"ignore-empty-mtl-entries","sha":"91370c6e097227812732fc9809e272046123333b","user":{"login":"jensarps","id":178141,"avatar_url":"https://avatars.githubusercontent.com/u/178141?v=3","gravatar_id":"","url":"https://api.github.com/users/jensarps","html_url":"https://github.com/jensarps","followers_url":"https://api.github.com/users/jensarps/followers","following_url":"https://api.github.com/users/jensarps/following{/other_user}","gists_url":"https://api.github.com/users/jensarps/gists{/gist_id}","starred_url":"https://api.github.com/users/jensarps/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jensarps/subscriptions","organizations_url":"https://api.github.com/users/jensarps/orgs","repos_url":"https://api.github.com/users/jensarps/repos","events_url":"https://api.github.com/users/jensarps/events{/privacy}","received_events_url":"https://api.github.com/users/jensarps/received_events","type":"User","site_admin":false},"repo":{"id":44877683,"name":"three.js","full_name":"jensarps/three.js","owner":{"login":"jensarps","id":178141,"avatar_url":"https://avatars.githubusercontent.com/u/178141?v=3","gravatar_id":"","url":"https://api.github.com/users/jensarps","html_url":"https://github.com/jensarps","followers_url":"https://api.github.com/users/jensarps/followers","following_url":"https://api.github.com/users/jensarps/following{/other_user}","gists_url":"https://api.github.com/users/jensarps/gists{/gist_id}","starred_url":"https://api.github.com/users/jensarps/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jensarps/subscriptions","organizations_url":"https://api.github.com/users/jensarps/orgs","repos_url":"https://api.github.com/users/jensarps/repos","events_url":"https://api.github.com/users/jensarps/events{/privacy}","received_events_url":"https://api.github.com/users/jensarps/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jensarps/three.js","description":"JavaScript 3D library.","fork":true,"url":"https://api.github.com/repos/jensarps/three.js","forks_url":"https://api.github.com/repos/jensarps/three.js/forks","keys_url":"https://api.github.com/repos/jensarps/three.js/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jensarps/three.js/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jensarps/three.js/teams","hooks_url":"https://api.github.com/repos/jensarps/three.js/hooks","issue_events_url":"https://api.github.com/repos/jensarps/three.js/issues/events{/number}","events_url":"https://api.github.com/repos/jensarps/three.js/events","assignees_url":"https://api.github.com/repos/jensarps/three.js/assignees{/user}","branches_url":"https://api.github.com/repos/jensarps/three.js/branches{/branch}","tags_url":"https://api.github.com/repos/jensarps/three.js/tags","blobs_url":"https://api.github.com/repos/jensarps/three.js/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jensarps/three.js/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jensarps/three.js/git/refs{/sha}","trees_url":"https://api.github.com/repos/jensarps/three.js/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jensarps/three.js/statuses/{sha}","languages_url":"https://api.github.com/repos/jensarps/three.js/languages","stargazers_url":"https://api.github.com/repos/jensarps/three.js/stargazers","contributors_url":"https://api.github.com/repos/jensarps/three.js/contributors","subscribers_url":"https://api.github.com/repos/jensarps/three.js/subscribers","subscription_url":"https://api.github.com/repos/jensarps/three.js/subscription","commits_url":"https://api.github.com/repos/jensarps/three.js/commits{/sha}","git_commits_url":"https://api.github.com/repos/jensarps/three.js/git/commits{/sha}","comments_url":"https://api.github.com/repos/jensarps/three.js/comments{/number}","issue_comment_url":"https://api.github.com/repos/jensarps/three.js/issues/comments{/number}","contents_url":"https://api.github.com/repos/jensarps/three.js/contents/{+path}","compare_url":"https://api.github.com/repos/jensarps/three.js/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jensarps/three.js/merges","archive_url":"https://api.github.com/repos/jensarps/three.js/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jensarps/three.js/downloads","issues_url":"https://api.github.com/repos/jensarps/three.js/issues{/number}","pulls_url":"https://api.github.com/repos/jensarps/three.js/pulls{/number}","milestones_url":"https://api.github.com/repos/jensarps/three.js/milestones{/number}","notifications_url":"https://api.github.com/repos/jensarps/three.js/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jensarps/three.js/labels{/name}","releases_url":"https://api.github.com/repos/jensarps/three.js/releases{/id}","created_at":"2015-10-24T17:53:35Z","updated_at":"2015-10-24T17:53:59Z","pushed_at":"2015-10-24T18:09:17Z","git_url":"git://github.com/jensarps/three.js.git","ssh_url":"git@github.com:jensarps/three.js.git","clone_url":"https://github.com/jensarps/three.js.git","svn_url":"https://github.com/jensarps/three.js","homepage":"http://threejs.org/","size":423652,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":false,"has_wiki":true,"has_pages":true,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"mrdoob:dev","ref":"dev","sha":"c518b92baf3aa859df188c62860a319d535d2280","user":{"login":"mrdoob","id":97088,"avatar_url":"https://avatars.githubusercontent.com/u/97088?v=3","gravatar_id":"","url":"https://api.github.com/users/mrdoob","html_url":"https://github.com/mrdoob","followers_url":"https://api.github.com/users/mrdoob/followers","following_url":"https://api.github.com/users/mrdoob/following{/other_user}","gists_url":"https://api.github.com/users/mrdoob/gists{/gist_id}","starred_url":"https://api.github.com/users/mrdoob/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mrdoob/subscriptions","organizations_url":"https://api.github.com/users/mrdoob/orgs","repos_url":"https://api.github.com/users/mrdoob/repos","events_url":"https://api.github.com/users/mrdoob/events{/privacy}","received_events_url":"https://api.github.com/users/mrdoob/received_events","type":"User","site_admin":false},"repo":{"id":576201,"name":"three.js","full_name":"mrdoob/three.js","owner":{"login":"mrdoob","id":97088,"avatar_url":"https://avatars.githubusercontent.com/u/97088?v=3","gravatar_id":"","url":"https://api.github.com/users/mrdoob","html_url":"https://github.com/mrdoob","followers_url":"https://api.github.com/users/mrdoob/followers","following_url":"https://api.github.com/users/mrdoob/following{/other_user}","gists_url":"https://api.github.com/users/mrdoob/gists{/gist_id}","starred_url":"https://api.github.com/users/mrdoob/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mrdoob/subscriptions","organizations_url":"https://api.github.com/users/mrdoob/orgs","repos_url":"https://api.github.com/users/mrdoob/repos","events_url":"https://api.github.com/users/mrdoob/events{/privacy}","received_events_url":"https://api.github.com/users/mrdoob/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/mrdoob/three.js","description":"JavaScript 3D library.","fork":false,"url":"https://api.github.com/repos/mrdoob/three.js","forks_url":"https://api.github.com/repos/mrdoob/three.js/forks","keys_url":"https://api.github.com/repos/mrdoob/three.js/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mrdoob/three.js/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mrdoob/three.js/teams","hooks_url":"https://api.github.com/repos/mrdoob/three.js/hooks","issue_events_url":"https://api.github.com/repos/mrdoob/three.js/issues/events{/number}","events_url":"https://api.github.com/repos/mrdoob/three.js/events","assignees_url":"https://api.github.com/repos/mrdoob/three.js/assignees{/user}","branches_url":"https://api.github.com/repos/mrdoob/three.js/branches{/branch}","tags_url":"https://api.github.com/repos/mrdoob/three.js/tags","blobs_url":"https://api.github.com/repos/mrdoob/three.js/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mrdoob/three.js/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mrdoob/three.js/git/refs{/sha}","trees_url":"https://api.github.com/repos/mrdoob/three.js/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mrdoob/three.js/statuses/{sha}","languages_url":"https://api.github.com/repos/mrdoob/three.js/languages","stargazers_url":"https://api.github.com/repos/mrdoob/three.js/stargazers","contributors_url":"https://api.github.com/repos/mrdoob/three.js/contributors","subscribers_url":"https://api.github.com/repos/mrdoob/three.js/subscribers","subscription_url":"https://api.github.com/repos/mrdoob/three.js/subscription","commits_url":"https://api.github.com/repos/mrdoob/three.js/commits{/sha}","git_commits_url":"https://api.github.com/repos/mrdoob/three.js/git/commits{/sha}","comments_url":"https://api.github.com/repos/mrdoob/three.js/comments{/number}","issue_comment_url":"https://api.github.com/repos/mrdoob/three.js/issues/comments{/number}","contents_url":"https://api.github.com/repos/mrdoob/three.js/contents/{+path}","compare_url":"https://api.github.com/repos/mrdoob/three.js/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mrdoob/three.js/merges","archive_url":"https://api.github.com/repos/mrdoob/three.js/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mrdoob/three.js/downloads","issues_url":"https://api.github.com/repos/mrdoob/three.js/issues{/number}","pulls_url":"https://api.github.com/repos/mrdoob/three.js/pulls{/number}","milestones_url":"https://api.github.com/repos/mrdoob/three.js/milestones{/number}","notifications_url":"https://api.github.com/repos/mrdoob/three.js/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mrdoob/three.js/labels{/name}","releases_url":"https://api.github.com/repos/mrdoob/three.js/releases{/id}","created_at":"2010-03-23T18:58:01Z","updated_at":"2015-10-24T19:26:51Z","pushed_at":"2015-10-24T19:52:39Z","git_url":"git://github.com/mrdoob/three.js.git","ssh_url":"git@github.com:mrdoob/three.js.git","clone_url":"https://github.com/mrdoob/three.js.git","svn_url":"https://github.com/mrdoob/three.js","homepage":"http://threejs.org/","size":423652,"stargazers_count":21675,"watchers_count":21675,"language":"JavaScript","has_issues":true,"has_downloads":false,"has_wiki":true,"has_pages":true,"forks_count":6728,"mirror_url":null,"open_issues_count":515,"forks":6728,"open_issues":515,"watchers":21675,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/mrdoob/three.js/pulls/7431"},"html":{"href":"https://github.com/mrdoob/three.js/pull/7431"},"issue":{"href":"https://api.github.com/repos/mrdoob/three.js/issues/7431"},"comments":{"href":"https://api.github.com/repos/mrdoob/three.js/issues/7431/comments"},"review_comments":{"href":"https://api.github.com/repos/mrdoob/three.js/pulls/7431/comments"},"review_comment":{"href":"https://api.github.com/repos/mrdoob/three.js/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/mrdoob/three.js/pulls/7431/commits"},"statuses":{"href":"https://api.github.com/repos/mrdoob/three.js/statuses/91370c6e097227812732fc9809e272046123333b"}},"merged":true,"mergeable":null,"mergeable_state":"unknown","merged_by":{"login":"mrdoob","id":97088,"avatar_url":"https://avatars.githubusercontent.com/u/97088?v=3","gravatar_id":"","url":"https://api.github.com/users/mrdoob","html_url":"https://github.com/mrdoob","followers_url":"https://api.github.com/users/mrdoob/followers","following_url":"https://api.github.com/users/mrdoob/following{/other_user}","gists_url":"https://api.github.com/users/mrdoob/gists{/gist_id}","starred_url":"https://api.github.com/users/mrdoob/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mrdoob/subscriptions","organizations_url":"https://api.github.com/users/mrdoob/orgs","repos_url":"https://api.github.com/users/mrdoob/repos","events_url":"https://api.github.com/users/mrdoob/events{/privacy}","received_events_url":"https://api.github.com/users/mrdoob/received_events","type":"User","site_admin":false},"comments":1,"review_comments":0,"commits":1,"additions":4,"deletions":0,"changed_files":1}}