Jump to content

IVA multiple UV setup and Shared Assets


Recommended Posts

So I imported the MK1 inline cockpit and noticed that the IVA has two UVmaps. One UV map is overlayed over details such as the border colors, and rivets and all that but the second UV map when overlayed over the sharedasset IVA texture doesn't make sense as the color information is not consistent with the texture it's overlayed with. When I bring the model into MODO I noticed the second UV map get's it color when loading the shared IVA texture, but I can't tell where it's getting the color information is coming from.

Basically my questions is: how does one set up this multiple UV with shared asset IVA setup in unity? Is this supported in the new PartTools?

I'm not near my computer right now, but I'll try to upload the pictures to make this post a little less confusing.

 

Link to comment
Share on other sites

KSP Shaders only read UV-0, no multiple UV sets, yet. 

one texture is Diffuse/Spec all 3 Mk1 cockpit/crew cabin atlased into 1 texture; the other is Emissive/Self Illumination, works in combination with a shader RGB(A) settingm for when you toggle "Cockpit Light" in game.

Edit: True, but not relevant to OP's topic. Mea culpa.

Edited by nli2work
Link to comment
Share on other sites

The newer IVA's have a lightmap texture applied using UV2. The lightmap has several baked GI maps and AO packed in seperate channels of the texture so it'll look like a colorful mess if you open the texture itself but the IVA shader in unity makes sense of it.

Link to comment
Share on other sites

Aha so that's the new Internal Specular shader... I totally misread the OP.

Which one is the newest one? I assume the one with Fog settings? Whats the Fog setting for? Atmosphere perspective while in IVA?

Single Color reads Alpha Channel while multi reads RGB?

Edited by nli2work
Link to comment
Share on other sites

29 minutes ago, Porkjet said:

The newer IVA's have a lightmap texture applied using UV2. The lightmap has several baked GI maps and AO packed in seperate channels of the texture so it'll look like a colorful mess if you open the texture itself but the IVA shader in unity makes sense of it.

 

16 minutes ago, nli2work said:

Aha so that's the new Internal Specular shader... I totally misread the OP.

Awesome!! I will begin to exploit this for fun and profit.

Thanks for the thorough answers!!

Link to comment
Share on other sites

Boost looks like global ambient control, additive to Color 1 and 2

Tightness is standard AO map. multiplies with the other 3.

This new Internal shader is good enough as standard shader for everything to be honest. only down side is it's not PBR. Make the Colors 1 and 2 tweakable in Editor and you got customizable color schemes... Well not quite. Looks like the light maps are all on by default. I guess because there's not much lighting in the IVA render scene. Internal Shader don't look good in Flight Scene.

Edited by nli2work
Link to comment
Share on other sites

yeah that just means there isn't a particular set of emissives being used. It was most likely baked in whatever 3d package Porkjet uses. I don't know which. Unity doesn't bake maps.

think of it as multiple Emissive maps packed into one RGBA map. saves on system resources. Typical KSP Emissive map is B/W. So you can package 4 different B/W maps into a single RGB(A) map, as long as a shader is setup so specific aspects are set to read pixel information from individual channels.

the Internal Specular shader set to read RGB (all added together before read by the shader) + A; This is the Single Colored option in Light Map/Occlusion Mode drop down. 

Multi Channel option gives you control over 4 properties using RGB +A channels.
 

Link to comment
Share on other sites

Quote

The internalspace shader has some useful extras for IVA's, most notably lightmapping. There are two modes for this, "Single Colored" simply uses RGB of the lightmap as one colored emissive, "Multi Greyscale" uses R, G and B as seperate emissive masks, where R and G can be multiplied by a color input, and B is colored by ambient light. Both modes use Ambient Occlusion map in Alpha channel.
"Multi Greyscale" can be used for more complex stuff, the ambient color lightmap can be used to fake light comming in through the windows and will be green on jool, red on duna etc. The color inputs for the other two lightmaps could potentially be animated or manipulated from modules to switch off a light and such.
Fog is kinda experimental, might come in handy for large IVA's or to emphasize foreground objects. (Alpha of the color input controls fog density)

Clarification courtesy of Porkjet.

Link to comment
Share on other sites

This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...