{"id":532,"date":"2010-05-30T23:14:14","date_gmt":"2010-05-30T23:14:14","guid":{"rendered":""},"modified":"2013-02-27T12:05:20","modified_gmt":"2013-02-27T04:05:20","slug":"532","status":"publish","type":"post","link":"https:\/\/1vr.cn\/?p=532","title":{"rendered":"Maya\u70d8\u57f9\u5165Unity\u6559\u7a0b"},"content":{"rendered":"<p>1,\u7ed9\u4f60\u7684\u6a21\u578b\u6253\u4e0a\u4f60\u9700\u8981\u7684\u706f\u5149,\u6dfb\u52a0\u8d34\u56fe\u6750\u8d28\u7b49\u7b49..<br \/><img decoding=\"async\" src=\"wp-content\/uploads\/attachments\/month_1005\/20100530230355j.jpg\" \/><br \/>2,\u6e32\u67d3\u4f60\u7684\u573a\u666f,\u6bd4\u5982\u7528Mental Ray,\u4f60\u559c\u6b22\u7528\u4ec0\u4e48\u5c31\u7528\u4ec0\u4e48.<br \/><img decoding=\"async\" src=\"wp-content\/uploads\/attachments\/month_1005\/20100530230540t.jpg\" \/><br \/>3,\u9009\u62e9\u6240\u6709\u7269\u4f53\u5e76\u4f7f\u7528&#8221;Mesh-&gt;Combine&#8221;\u547d\u4ee4.\u7136\u540e\u7ed9\u8fd9\u4e9b\u7269\u4f53\u6253\u5f00&#8221;Create UVs-&gt;Automatic Mapping&#8221;,\u8fdb\u884c\u5c55UV\u64cd\u4f5c.\u6253\u5f00&#8221;Window-&gt;UV Texture Editor&#8221;\u5e76\u68c0\u67e5\u7528\u4e8e\u70d8\u57f9\u7684\u65b0\u7684UV.<br \/><img decoding=\"async\" src=\"wp-content\/uploads\/attachments\/month_1005\/201005302307590.jpg\" \/><br \/>4,\u5207\u6362\u5230&#8221;Rendering&#8221;\u5de5\u5177\u680f,\u5e76\u4e14\u786e\u4fdd\u4f60\u8981\u6e32\u67d3\u7684\u7269\u4f53\u662f\u88ab\u9009\u62e9\u7684,\u6253\u5f00&#8221;Texture\/Lighting-&gt;Batch Bake(mental ray)&#8221;\u5bf9\u8bdd\u6846,\u5e76\u7528\u5982\u4e0b\u7684\u8bbe\u7f6e,\u7136\u540e\u70b9\u51fb&#8221;Convert and close&#8221;:<\/p>\n<p>Objects to bake: Selected <br \/>Bake to: Texture \/\/ IMPORTANT <br \/>Bake shadows: checked \/\/ IMPORTANT <br \/>Keep original shading network: checked \/\/ IMPORTANT <br \/>Use bake set override: checked \/\/ IMPORTANT <br \/>Color mode: light and color \/\/ IMPORTANT <br \/>Normal direction: surface front \/\/ IMPORTANT <br \/>Prefix: myLightmap \/\/ IMPORTANT this will be the filename of the lightmap TIFF, pick a name you like <br \/>X resolution: 2048 \/\/ depends on the size of the object usually 2048 is plenty, try various values <br \/>Y resolution: same value as &#8220;X resolution&#8221; <br \/>File format: TIFF \/\/ others work to as long as Unity can import them <br \/>Bits per channel: 8 bits \/\/ IMPORTANT <br \/>Number of samples: 1 <br \/>Bake to one map: checked \/\/ IMPORTANT <br \/>UV range: Normal [0 to 1] \/\/ IMPORTANT, other settings lead to distorted maps <br \/>Fill texture seams: 3 \/\/ IMPORTANT, this is the bleed area in pixels around each UV shape to avoid jaggy edges later in Unity <br \/>Override mesh UV assignments: checked <br \/>UV set name: Lightmap<\/p>\n<p>5,Maya\u5c06\u5e2e\u4f60\u6e32\u67d3\u51faLightmap(\u6839\u636e\u4f60\u8bbe\u7f6e\u7684\u5206\u8fa8\u7387\u548c\u6e32\u67d3\u9009\u9879\u4e0d\u540c\u53ef\u80fd\u6d88\u8017\u6bd4\u8f83\u957f\u7684\u65f6\u95f4),\u8fd9\u4e2a\u56fe\u4e0d\u4f1a\u5728Maya\u4e2d\u663e\u793a,\u8fd9\u4e2a\u6587\u4ef6\u770b\u8d77\u6765\u4f1a\u50cf\u4e0b\u9762\u8fd9\u79cd:<br \/><img decoding=\"async\" src=\"wp-content\/uploads\/attachments\/month_1005\/20100530231123u.jpg\" \/><br \/>9,\u4fdd\u5b58\u573a\u666f\u548c\u5207\u6362\u5230Unity,\u627e\u5230Lightmap\u5e76\u5bfc\u5165\u5230Unity\u4e2d.\u9ed8\u8ba4\u8def\u5f84&#8221;user\/[your username]\/documents\/maya\/projects\/[maya project name]\/renderData\/mentalray\/lightMap\/[prefix].tiff&#8221;,\u9009\u62e9\u4f60\u7684\u6a21\u578b,\u66f4\u6539\u6750\u8d28\u4e3a&#8221;Lightmapped&#8221;,\u5e76\u5c06tiff\u683c\u5f0f\u7684\u70d8\u57f9\u56fe\u6587\u4ef6\u8d4b\u4e88\u7ed9\u5b83,\u641e\u5b9a!<br \/><img decoding=\"async\" src=\"wp-content\/uploads\/attachments\/month_1005\/20100530231331j.jpg\" \/><\/p>\n<p>\u539f\u6587:<a href=\"http:\/\/forum.unity3d.com\/viewtopic.php?t=9606\" target=\"_blank\" rel=\"external\">http:\/\/forum.unity3d.com\/viewtopic.php?t=9606<\/a><br \/>\u5a01\u963f\u7ffb\u8bd1,\u8f6c\u8f7d\u8bf7\u6ce8\u660e\u6765\u59041Vr.Cn<\/p>\n","protected":false},"excerpt":{"rendered":"<p>1,\u7ed9\u4f60\u7684\u6a21\u578b\u6253\u4e0a\u4f60\u9700\u8981\u7684\u706f\u5149,\u6dfb\u52a0\u8d34\u56fe\u6750\u8d28\u7b49\u7b49..2,\u6e32\u67d3\u4f60\u7684\u573a\u666f,\u6bd4\u5982\u7528Mental Ray,\u4f60\u559c\u6b22\u7528\u4ec0\u4e48 &hellip; <a href=\"https:\/\/1vr.cn\/?p=532\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">Maya\u70d8\u57f9\u5165Unity\u6559\u7a0b<\/span><\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-532","post","type-post","status-publish","format-standard","hentry","without-featured-image"],"_links":{"self":[{"href":"https:\/\/1vr.cn\/index.php?rest_route=\/wp\/v2\/posts\/532","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/1vr.cn\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/1vr.cn\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/1vr.cn\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/1vr.cn\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=532"}],"version-history":[{"count":1,"href":"https:\/\/1vr.cn\/index.php?rest_route=\/wp\/v2\/posts\/532\/revisions"}],"predecessor-version":[{"id":738,"href":"https:\/\/1vr.cn\/index.php?rest_route=\/wp\/v2\/posts\/532\/revisions\/738"}],"wp:attachment":[{"href":"https:\/\/1vr.cn\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=532"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/1vr.cn\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=532"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/1vr.cn\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=532"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}