Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
This repository was archived by the owner on Jul 2, 2022. It is now read-only.
/muhcolorsPublic archive

Simple script to create color grading and color correction presets and export them to a 3DLUT.

License

NotificationsYou must be signed in to change notification settings

DomBito/muhcolors

Repository files navigation

Simple script to create color grading / color correction presets and export them to a 3DLUT. The goal is to then use it on videos.

Capabilities and qualities:

  • white-balance when testing on images;
  • hue-to-hue maps for dark and bright tones separately;
  • functions use the cylindrical CIEluv colorspace, which focus on keeping the same perceived luminosity of each color after hue shifts;
  • saturation map with respect to brightness;
  • lightness map with respect to brightness;
  • locally boost or decrease the lightness within an interval of hue and lightness;
  • locally boost or decrease the saturation within an interval of hue and lightness;
  • considerably good performance;

Change the parameters in arguments.py to tweak the colors. The presets are all given by RGB and HSV/L values, since these are very simple to colorpick and understand. The HSV/L (range: hue from 0° to 360°, saturation and value/lightness from 0% to 100%) numbers are all converted to cylindrical CIEluv.Run

python makeLUT.py

to generate a new LUT file in .cube format. This will ignore any white-balance presets in arguments.py. Ideally, you should apply the LUTs generated by this script on footage that's already white-balanced.To test on an image, run

python makeLUT.py --test=/path/to/image.png

on your terminal.

Apply the 3DLUT to video:

If you use any video editor, you should be able to import the 3DLUT file with ease.Here I included the vapoursynth script cc.py to accomplish this. To avoid artefacting due to possible extreme transformations the 3DLUT might do, a fast denoiser is applied to separate any noise or film grain from the footage. The noise is added back to the video after the color correction, and finally a deband filter is applied.To preview the cc.py script, run on your terminal:

./vspipepreview.sh /path/to/video.avi

You can edit vspipepreview.sh to pipe the script to a raw y4m file or to ffmpeg to get a proper encode.

Examples:

( untouched| white-balance + 3DLUT exported by the script )

About

Simple script to create color grading and color correction presets and export them to a 3DLUT.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

[8]ページ先頭

©2009-2025 Movatter.jp