-
Notifications
You must be signed in to change notification settings - Fork 428
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
If Emission keyword is false, do not output a value #227
Conversation
Standerdシェーダを使用してエクスポートした時に、EmissionEnable = falseの状態でもEmissionColorが書き込まれてしまい、インポート時にEmissionColorが(0,0,0)でなかった場合はEmissionEnable = trueになってしまうバグの修正 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM with nits.
@@ -142,6 +142,9 @@ static void Export_Occlusion(Material m, TextureExportManager textureManager, gl | |||
|
|||
static void Export_Emission(Material m, TextureExportManager textureManager, glTFMaterial material) | |||
{ | |||
if (m.IsKeywordEnabled("_EMISSION") == false) | |||
return; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
return; | |
{ | |
return; | |
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nits:
@@ -142,6 +142,9 @@ static void Export_Occlusion(Material m, TextureExportManager textureManager, gl | |||
|
|||
static void Export_Emission(Material m, TextureExportManager textureManager, glTFMaterial material) | |||
{ | |||
if (m.IsKeywordEnabled("_EMISSION") == false) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if (m.IsKeywordEnabled("_EMISSION") == false) | |
if (!m.IsKeywordEnabled("_EMISSION")) |
自分であれば IDEのフォーマッタ挟まっているので良さそうです。 |
EMISSIONキーワードがfalseの場合は何も書き込まない