Jump to content

[1.12.x] Textures Unlimited Recolour Depot


Recommended Posts

@CalixK It looks like the texture you are using for the metallicglossmap has the alpha channel / spmoothness layer completely white / opaque.

I recommend starting out with the alpha channel being a 1:1 copy of the RGB layer. You can tweak and manipulate it later with a combination of the graphics editor you use and the normalisation vector values in the config. The normalisation vectors values only apply to the areas masked to be painted. Any area unpainted needs to be manipulated via the texture values.

The main thing to understand about the metallicglossmap is how it is being interpreted by the shader. For the shader being used here, the red channel of the RGB layer determines the metal value applied. Strictly speaking, this should be 1 or 0 but artistically you can use values in between, particularly where materials transition. Rather than just editing the red channel, it is easier and possibly better with regard to block compression (not tested) to have all RGB channel values the same and essentially a greyscale image. Alternatively you could just work in shades of red but I found that too strange to visually process when I tried it out. The alpha channel is used to determine the smoothness and is greyscale.

 

Hope that helps.

Edited by Manwith Noname
Link to comment
Share on other sites

7 hours ago, Manwith Noname said:

@CalixK It looks like the texture you are using for the metallicglossmap has the alpha channel / spmoothness layer completely white / opaque.

I recommend starting out with the alpha channel being a 1:1 copy of the RGB layer. You can tweak and manipulate it later with a combination of the graphics editor you use and the normalisation vector values in the config. The normalisation vectors values only apply to the areas masked to be painted. Any area unpainted needs to be manipulated via the texture values.

The main thing to understand about the metallicglossmap is how it is being interpreted by the shader. For the shader being used here, the red channel of the RGB layer determines the metal value applied. Strictly speaking, this should be 1 or 0 but artistically you can use values in between, particularly where materials transition. Rather than just editing the red channel, it is easier and possibly better with regard to block compression (not tested) to have all RGB channel values the same and essentially a greyscale image. Alternatively you could just work in shades of red but I found that too strange to visually process when I tried it out. The alpha channel is used to determine the smoothness and is greyscale.

 

Hope that helps.

You have been very helpful! I'm still having trouble understanding how you choose the following values:

        vector = _DiffuseNorm,0.74,0.35,0.74
        vector = _MetalNorm,0.5,0.175,0.5
        vector = _SmoothnessNorm,0.5,0.175,0.5

I use photoshop for the entirety of this process. I installed gimp after reading your post earlier, but I am still confused.

 

Spoiler

1VtBwjU.pnggIF48gI.png

So far so good. I followed your advice and moved this all into it's own folder so it can be independently installed. Once I figure out these values, I'll be ready to save I can complete this. For now, I'm going to continue with the rest OPT Legacy

Link to comment
Share on other sites

@Arqane The quickest and simplest workaround is to open up the following files...

112x_Standardised_Switching.cfg

112x_Standardised_PBRMetallic.cfg

112x_Standardised_Switching.cfg

In each of them use CTRL+F to find [mk2DockingPort] then change the :NEEDS section on that line so it reads [TexturesUnlimited&!Restock] It's worth changing the KSP_TEXTURE_SET lines relating to the part also.

 

@CalixK First things first, I have not gone through all the parts in the pack but at first glance this is a great step in the right direction. I can further comment on some things I see but to first answer a previous question about choosing values, the best way I can explain how to understand these is they essentially set the value of the base texture that will result in the slider value of 255 giving a corresponding pixel value of 255 in the shader when rendered in game. This then means that the values along the slider should give a corresponding and representative output. So if a base texture contains an area you want to paint and it is mostly a value of 127/128 when measured inside PS or GIMP, using a value of 0.5 in those normalisation parameters would scale the slider allowing you to get a full range of colours when trying to paint that area.

The three values separated by commas represent the areas of a texture covered by each of the colours used in the paint mask. So the first number is the normalisation value for the red area, the second number is for green and the third number is for blue. Strictly speaking, it's the pixel value so areas where red and blue might overlap to composite in to a magenta will be treated twice and results may be undesired.

A good starting point for finding suitable values is to use the colour picker tool and look at the values in your image editor (photoshop). You may find it useful to desaturate textures based on luminance and using the values extracted from the resulting greyscale texture. This is what I do to get the colour normalisation value so it maintains all the existing artwork character in terms of "fake shading" for artistic purposes. It maintains the look of the part even if some of the pre existing texture works was really about faking ambient occlusion. This method may not always get you a result you are 100% happy with and sometimes I manipulate or completely recreate the diffuse texture to get something more akin to what I want.

The metallic and smoothness values are typically found by educated guessing then trial and error tweaking. To some extent this is an artistic choice I would say. With the in game GUI sliders for these at 255 values, I want the bulk of the painted areas to be close to fully smooth but not necessarily obliterating all detail and conversely not only making a tiny portion of an area completely smooth.

 

I've kinda waffled a bit so I'll wrap that up here and say, I am going to be reworking and adding to my OPT base pack because way back when I converted it to more current standards I did so very quickly and some things have changed in the TU plugin since that were not part of the consideration when I was doing so. Some things will not be drastically different but I mainly notice I did not normalise areas of the texture as I would have been.

Before I pass comment on certain aspects of your legacy pack I suppose I should state anything I say is not meant to discourage you or otherwise diminish your efforts, what I have seen is genuinely a good beginning. It's mostly finer details and artistic interpretation that I see that I feel can elevate the pack. Some of them you may have plans to do. Some of them you may have just not noticed. Some of them you may just consider unimportant. All are reasonable positions. I also only bring this up because you said you consider it finished, so I guess I should ask, do you actually consider it finished or do you just consider that "hey, I get everything up and running with colour mapping" ? Trust me, I have been there. The stock project when I first converted it from KerbPaint was very much incomplete and just, "hey, you can muck about with colouring". Even today, I am still working on improving things in the stock pack. As a result of this and a conversation elsewhere I see some parts have been added to the base OPT I need to get covered and noticed the things I previously mentioned that I feel need to be brought more in line with my current methodology in stock.

Edited by Manwith Noname
Link to comment
Share on other sites

Just a quick note that the stock recolour pack has been updated (completely delete existing stock packs when updating to prevent conflicts and errors) and a new "pGlass" pack is available for anyone using either or both of the procedural wings mods with the existing recolour pack.

 

The main focus of the stock update was fleshing out the science parts so everything can be painted.

Spoiler

2D811D79735EB8B274A216A0278AAF97AAEA71D2

The pGlass pack was the result of a conversation a while back and gives an option for creating procedural glass type things from procedural wings.

Spoiler

03409142683B5074349C102CB7E4D52EBDB16D9D

It still has assorted rendering issues but some may find it useful. Note, the "Clear Glass" colour preset does not automatically make any part translucent. It's just there to give a reasonable starting point when this texture set is selected.

Edited by Manwith Noname
Link to comment
Share on other sites

  • 2 weeks later...

@daddydante88 The current most effective way is to use the save and load pattern buttons on each part. It would conceivably be possibly to program an "apply to all" sort of logic in to the base TU plugin but it's not something that exists and I suspect it is unlikely to unless I learn C# and a whole load of best practices.

An alternative if you wish to start from something other than the red, green and blue bases is to decide on a useful palette, configure colours if required and then point to them in the base texture set config. The base texture set ultimately looks like this once the commented out lines are removed...

Spoiler
KSP_TEXTURE_SET:NEEDS[TexturesUnlimited]
{
	name = MWNN_Stock_Paint
	title = Bob Ross Paints
	recolorable = true
	
	MATERIAL
	{
		mode = create
		shader = TU/Metallic
		keyword = TU_RECOLOR
	}
	COLORS
	{
		mainColor = absolute_red
		secondColor = absolute_green
		detailColor = absolute_blue
	}
}

 

The main, second and detail colours in the COLORS block can be set to anything configured as a colour preset but you would need to do this prior to loading the game. You can find colour preset files in the base TU folder or in amongst the recolour files for a reference to create new ones or find appropriate existing ones to assign.

Edited by Manwith Noname
Link to comment
Share on other sites

On 4/8/2023 at 4:13 AM, Manwith Noname said:

Just a quick note that the stock recolour pack has been updated (completely delete existing stock packs when updating to prevent conflicts and errors) and a new "pGlass" pack is available for anyone using either or both of the procedural wings mods with the existing recolour pack.

 

The main focus of the stock update was fleshing out the science parts so everything can be painted.

  Reveal hidden contents

2D811D79735EB8B274A216A0278AAF97AAEA71D2

The pGlass pack was the result of a conversation a while back and gives an option for creating procedural glass type things from procedural wings.

  Hide contents

03409142683B5074349C102CB7E4D52EBDB16D9D

It still has assorted rendering issues but some may find it useful. Note, the "Clear Glass" colour preset does not automatically make any part translucent. It's just there to give a reasonable starting point when this texture set is selected.

OMG im more than happy to see this, tweaking transparent part, I been yearning this for so long.

Link to comment
Share on other sites

  • 2 weeks later...

Kill your foes in style

Thanks to the time and dedication of @Spartwo you can now paint BD Armoury parts for added flare in your simulated war games.

Spoiler

screenshot114.png

screenshot107.png

screenshot113.png

screenshot112.png

screenshot111.png

Link in the opening post.

 

@InterstellarKev Maybe at some point if nobody else does. I don't have the DLC. I've considered getting it but I have not really played KSP in years, I only load it up to make colour packs.

@grandmastergoober Unfortunately Restock is not currently paintable.

@jebycheek Another unfortunate response, not easily solvable. Needs a shader wizard to fix and as of now, that's not me.

 

Happy coronation weekend everyone. Long live the King!

Link to comment
Share on other sites

@Spartwo

Hehe, I don't know what the forum software is doing or if it is my currently inebriated state but that should be the link on the front page?! Is it not redirecting others to the overall GitHub releases page?

 

 

Edit:  Ok, even while...tipsy...I have changed the link to the overall releases pages...that seems weird to me but we should be good!

Edited by Manwith Noname
Link to comment
Share on other sites

  • 3 weeks later...
  • 2 weeks later...
  • 2 weeks later...

I have a problem. In the Editor or VAB I see perfectly the recoloured parts and also the windows on the cabin. But when I launch, everything is dull and really dark, and only a liiiitle bit of reflection but so little. Even if I set it to maximum specular. What am I doing wrong?

Nevermind

Edited by Agustin
Link to comment
Share on other sites

  • 3 weeks later...

Hey all! Seems like I'm having issues with my reflections. The parts do become reflective, but its almost as if the reflections are reversed. When I have my ship in orbit with the module being painted shiny, looking at Kerbin, the entire module turns blue, while being black when looking from the opposite side. I do have planet shine, along with many other graphics mods installed, what could be causing this issue and is there a good solution?AITFw-xdCrdxzik1YIGR3p7GkjWGfWRkx5A1EWOgAKsag4NEcMel1bStRjgTfHC7jtfnlzGF8nDGG-55

Link to comment
Share on other sites

On 4/17/2023 at 5:53 PM, daddydante88 said:

I love the detailed at this mod allows me to add to a craft. The ability to paint each section of a part is wonderful. My question is, what is the most effective way to paint an entire craft instead of having to load the profile on each individual part?

 

On 4/21/2023 at 6:39 PM, Manwith Noname said:

@daddydante88 The current most effective way is to use the save and load pattern buttons on each part. It would conceivably be possibly to program an "apply to all" sort of logic in to the base TU plugin but it's not something that exists and I suspect it is unlikely to unless I learn C# and a whole load of best practices.

...

The main, second and detail colours in the COLORS block can be set to anything configured as a colour preset but you would need to do this prior to loading the game. You can find colour preset files in the base TU folder or in amongst the recolour files for a reference to create new ones or find appropriate existing ones to assign.

I've made an alternative UI for Textures Unlimited that tries to solve this problem. Be great if you guys could give me any feedback on how it's working for you and any ideas for improvements.

Edited by Halban
Link to comment
Share on other sites

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