Jump to content

Normal maps vs. Bump maps for KSP


Recommended Posts

Hi, I was wondering whether or not it is possible to use normal maps for KSP. Just to clarify since the terms are sometimes used interchangeably; what I mean by normal maps are actual normal maps, not bump maps. Bump maps can "easily" be painted using the same mesh whereas normal maps needs to be generated from a higher poly mesh and then baked/mapped onto the lower poly mesh for use in-game. A bump map stores intensity (by using alpha channels) and a normal map stores a direction making them more accurate and allows for better detail than a regular bump map.

So, in short, should I be bothered to make normal maps for KSP or should I just use bump maps?

Oh just remembered another question I had, perhaps it's stupid but would be useful to know. Does a part (say a radial part) connect to the normal mesh or the collision mesh in KSP?

Please note I am away from home and have a sketchy internet connection but I will try to respond (if anyone else does) as soon as possible, thank you!

Edited by Layer23
Link to comment
Share on other sites

KSP does have shaders that can use Normal maps; Unity has option that converts gray-scale bump map to a normal map. you can rely on Unity to create your normal maps; or bake your own.

All in the collision mesh. without a collision mesh you won't be able to pick up a part in VAB/SPH with your mouse, much less attach it to anything.

Link to comment
Share on other sites

Thank you very much for the answer. Didn't know Unity could convert bump maps to normal maps, and is that really as detailed as baking your own in say Blender? Is it possible to import a normal map generated in Blender into Unity? I don't see why not but you never know.

Regarding collision meshes, that means they actually have to be pretty exact. Making concave models using compound colliders seems very difficult now if you want to retain a modular building approach :(

Thanks for your help once again!

Link to comment
Share on other sites

you can import tangent space normal maps from any source. not sure about the other type World space, never tried those. Stick to the blue kind you should be good. Unity requires normal maps to be marked as such, otherwise they'll be treated as diffuse texture.

Doesn't have to be exact. You can use a primitive collider on anything. spaces between collider and model only becomes apparent if you attach parts to the surface since KSP uses collider to determine the "surface".

Concave objects will need multiple colliders to approximate the shape. intersecting colliders isn't an issue from what I've seen. Open geometry mesh colliders can be problematic, best to avoid those. You can also use primitive colliders included in Unity. Sphere; Capsule; and Box/Cube. non-convex mesh colliders won't collide with other non-convex mesh colliders in Unity, any other mix of colliders should work fine.

Primitive + Convex = ok

Primitive + Primitive = ok

Convex + Convex = ok

Non-Convex + Convex = ok

Non-Convex + Primitive = ok

Non-Convex + Non-Convex = no collision

Link to comment
Share on other sites

Okey great knowing that it can be done in Blender. Is it common for KSP mods to use normal maps (and is it appreciated) or is bump maps the way to go?

Approximating mesh shapes using compound colliders isn't as difficult as approximating it with high simplicity (using primitives) without it becoming apparent when radial parts such as RCS ports are attached to the surface. For collision purposes it doesn't have to be super exact, I get that. It's just that I want people to be able to attach stuff without it looking wrong/weird. Thanks!

Link to comment
Share on other sites

  • 2 weeks later...

There are also plenty of tools that can convert bump/heightmaps,color maps to normal maps.even free plugins for ps can do that.

I would prefer those because you have more control over them then letting unity handle everything.(i.g. delta,flips)

Just google for them, you should immediatly find something.

Link to comment
Share on other sites

  • 2 years later...

What is the KSP material that use the normal map? because i'm using the Bumped Specular (Transparent) and Emissive Bumped Specular, and both convert the original normal map i create in Maya/Photoshop to a bump map in KSP.

Don't know how to make it export as normal and not bump. I already unchecked inside Unity the "Create from Grayscale" checkbox on the texture normal map.

Is there a material that is not listed on the KSP materials?

Edited by Climberfx
Link to comment
Share on other sites

Any shader with Bumped channel uses Tangent space (Blue) Normal Maps. during export they are converted to D3D Normal maps, which puts R into RGB and G into A. original B channel is dropped. Those look like gray scale maps in photoshop.  Normal maps created from gray scale bump maps using "Create from Grayscale" checkbox will be exported as original grayscale maps. don't rely on Unity for normal maps.

Link to comment
Share on other sites

10 hours ago, nli2work said:

Any shader with Bumped channel uses Tangent space (Blue) Normal Maps. during export they are converted to D3D Normal maps, which puts R into RGB and G into A. original B channel is dropped. Those look like gray scale maps in photoshop.  Normal maps created from gray scale bump maps using "Create from Grayscale" checkbox will be exported as original grayscale maps. don't rely on Unity for normal maps.

Great explanation Nliwork, thank a lot.

I find another way in the doc's of Texture Replacer.

If i put the NRM in the suffix of the normal map, when exporting from Unity, then i replace the normal with the original tangent space normal, it use the tangent space RGB, original from Maya/Photoshop. I had the impression on KSP that the result was great.

But is good to know that this "Grey" is to a tangent normal map too.

Cheers Commander. Live long and prosper!

Edited by Climberfx
Link to comment
Share on other sites

On 7/23/2016 at 2:09 AM, nli2work said:

Any shader with Bumped channel uses Tangent space (Blue) Normal Maps. during export they are converted to D3D Normal maps, which puts R into RGB and G into A. original B channel is dropped. Those look like gray scale maps in photoshop.  Normal maps created from gray scale bump maps using "Create from Grayscale" checkbox will be exported as original grayscale maps. don't rely on Unity for normal maps.

It's worth noting that there are issues using Unity's "Create from Grayscale" if you have any mirroring on your UV's (such as mirroring to double sections back on each other). The issues only show up in game, ie with the exported .mu, and are not visible in the editor. You need to export as a proper normal map first, and then import that into Unity.

Link to comment
Share on other sites

2 hours ago, CobaltWolf said:

It's worth noting that there are issues using Unity's "Create from Grayscale" if you have any mirroring on your UV's (such as mirroring to double sections back on each other). The issues only show up in game, ie with the exported .mu, and are not visible in the editor. You need to export as a proper normal map first, and then import that into Unity.

Mirroring the similar faces on the UVW process to optimize space is a good thing, but here the problem is only in Maya, when transferring Tangent normals from a high poly model to a low one. I do a out position for the mirrored ones (out of the uvw box), so the process go right.

Then i put back the mirror faces, and had no problem in Unity neither in KSP for that. Using a Grey Tangent Normal and a RGB Tangent one too.

 

Link to comment
Share on other sites

  • 3 months later...

Can you say why?  What I'm trying to figure out is like this: notepad and notepad+ are both text editors, but notepad+ is way more powerful.  All these programs make normal maps, but are any more feature packed?

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...