Author Topic: Custom Colour Correction  (Read 5708 times)

Offline Kev4000

  • Developer
  • ******
  • Posts: 1.039
  • FH2 "special" coder
    • View Profile
Custom Colour Correction
« on: 02-08-2011, 23:08:57 »
Here's the workings on creating custom colour correction filters.

Choosing your own colour correction
In the /fh2/common_client.zip/textures/ folder there is a file called "noise.dds", which contains the information of the filter. This file is read for maps which do not have their own filters and does nothing, except add the darkening of the edges of the screen.
For most official maps, we've used custom texture suffix' included in common_client.zip. Below explains how to change the colour correction on your map without modifying the FH2 archives:
1.) Copy /mods/fh2/levels/bastogne/noise.zip to your map's folder
2.) Replace noise.zip/textures/noise_snow.dds with the colour correction you wish to have. It must be renamed to match your map's texture suffix.
3.) In your map's tmp.con, add "run ClientArchives.con"
4.) Create a ClientArchives.con file that contains "fileManager.mountArchive /Levels/levelname/noise.zip Common"
Check Bastogne's files for reference if you're confused.

There's a couple limitations:
- You cannot use existing FH2 suffix' besides noise_snow.dds.
- For example if using suffix "phl" it will cause the noise_phl.dds to be loaded from common_client.zip/textures/noise_phl.dds.
- In other words, if the file exists in common_client.zip/textures/, it will be loaded from here instead.

You may also use this method for custom trench skirts textures, as seen on Bastogne with suffix snow.

Creating your own custom colour corrections
How do you change the noise.dds to get the look you want? Quite simple:
  • Open a screenshot of your map in photoshop, preferrably one with both light and dark areas so you can see how they will be affected.
  • Open noise.dds.
  • Remove the alpha channel.
  • Copy and paste noise.dds onto your map screenshot and move it somewhere where it's not in the way.
  • Now you're ready to apply some adjustment layers. Go to layers, adjustment layers and pick the ones you want to add. Remdul suggested starting with 'curves' to make the darkest areas of the map a little lighter. Then go on to colours, brightness, contrast, saturation, etc...
  • Once done with your adjustments, flatten layers.
  • Go back to noise.dds and undo deleting the alpha channel.
  • Copy your noise picture from the screenshot and paste it back into the noise.dds.
  • Save noise.dds as noise_suffix.dds, where "suffix" is your map's texture suffix. Make sure you save as 8888 ARGB with no mipmaps
And that's it. Below the instructions in picture format. Hope it's all clear.
« Last Edit: 02-08-2011, 23:08:15 by Kev4000 »

Offline Ajs47951

  • Jr. Member
  • **
  • Posts: 459
  • 1f u c4n r34d th1s u r34lly n33d t0 g3t l41d
    • View Profile
    • AJS
Re: Custom Colour Correction
« Reply #1 on: 03-08-2011, 00:08:29 »
nice TUT even tho I know how to do this from modding fallout new Vegas

also you can do must of this without having to keep going back to layers.

like when you flatten the images you can just  right click on the layer and merge down or click flatten
and for curves there is a tab for it

« Last Edit: 03-08-2011, 01:08:08 by Ajs47951 »


Offline Natty

  • Developer
  • ******
  • Posts: 3.170
    • View Profile
Re: Custom Colour Correction
« Reply #2 on: 05-08-2011, 11:08:01 »
You also dont need to delete the alpha and all that.
Just add all the adjustment layers you want on your screenshot, then drag n drop all those adjustment layers to the (unmodified) Noise.dds > Flatten Image > Save as Noise_SUFFIXNAME.dds

Keep in mind that desaturation doesnt work If you desaturate your colors, you will get an... contrasted weird effect (hard to put in words) try to completely reduce saturation (so the screenshot becomes black-and-white) then run the map, the bug/color side-effect is visible.
Slight desaturation can be achieved if you know how RGB colors work, you can counter reduction of "selective colors" by lowering one color, then compensate slightly with the opposite color in the RGB spectrum. You basically need to choose which color should be dominant and lower the others,you cant lower all colors.

Offline aserafimov

  • Developer
  • ******
  • Posts: 177
    • View Profile
Re: Custom Colour Correction
« Reply #3 on: 10-11-2011, 23:11:12 »
nice tutorial...

I have a question.
I made custom correction, the name of the file is noise_os.dds.
I replaced noise.zip/textures/noise_snow.dds with noise_os.dds
In my map's tmp.con, added "run ClientArchives.con"
I created a ClientArchives.con file that contains "fileManager.mountArchive /Levels/levelname/noise.zip Common"
In the Init.con added:
LevelSettings.CustomTextureSuffix "os"
else
texturemanager.customTextureSuffix "os"
endIf

It works fine, BUT when I use noise_os.dds the snow on the roofs and the sandbags dissapear.
Could you help me with advice?

Offline Stubbfan

  • Developer
  • ******
  • Posts: 523
    • View Profile
Re: Custom Colour Correction
« Reply #4 on: 11-11-2011, 00:11:41 »
Yeah.. AFAIK there's no way to run 2 different suffixes on a map. Since "snow" suffix is used on all buildings and whatnot, that is what you need to have in your map, and you need to name your file noise_snow.dds or it wont work. There's no noise_snow file in the default fh2 files so it will not conflict or anything so you should be fine just by doing that.

Offline aserafimov

  • Developer
  • ******
  • Posts: 177
    • View Profile
Re: Custom Colour Correction
« Reply #5 on: 26-11-2011, 23:11:43 »
Yeah.. AFAIK there's no way to run 2 different suffixes on a map. Since "snow" suffix is used on all buildings and whatnot, that is what you need to have in your map, and you need to name your file noise_snow.dds or it wont work. There's no noise_snow file in the default fh2 files so it will not conflict or anything so you should be fine just by doing that.

thank you Stubbfan!
it works...

Offline Mudzin

  • Jr. Member
  • **
  • Posts: 692
    • View Profile
Re: Custom Colour Correction
« Reply #6 on: 09-06-2014, 12:06:21 »
So if I want to use already existing color correction, do I have to copy this dds. files to my map directory or will it be enough if I add proper name of suffix to Init.con?

Offline Stubbfan

  • Developer
  • ******
  • Posts: 523
    • View Profile
Re: Custom Colour Correction
« Reply #7 on: 09-06-2014, 15:06:09 »
It's enough to provide the suffix. Consider that it will load all textures for that specific suffix. IE if you use 'omaha', it will use the noise file for omaha, but also all the custom trench textures etc that was made to fit omaha terrain. Could also be different vehicle skins or whatever.

Offline Mudzin

  • Jr. Member
  • **
  • Posts: 692
    • View Profile
Re: Custom Colour Correction
« Reply #8 on: 09-06-2014, 17:06:43 »
Ok, thanks for the answer.

Another issue, related to this, is what's the difference between:
LevelSettings.CustomTextureSuffix "totalize"
and
texturemanager.customTextureSuffix "totalize"
?

I suppose level settings are related to lighting and texturemanager to things like trench texture, vehicle texture, right? If yes, can I use different suffixes, from different maps?

Offline Stubbfan

  • Developer
  • ******
  • Posts: 523
    • View Profile
Re: Custom Colour Correction
« Reply #9 on: 09-06-2014, 23:06:30 »
I don't think you can IIRC, but you can always try. Maybe a noise file counts as a levelsettin.customtexturesuffix.. not sure, never tried it.

Offline Mudzin

  • Jr. Member
  • **
  • Posts: 692
    • View Profile
Re: Custom Colour Correction
« Reply #10 on: 10-06-2014, 01:06:20 »
Ok, thanks for the explanation!