I’m looking for the GIMP or Gegl filter that corresponds to the Tone Curve of GIMP. The “gegl:contrast-curve” filter seems similar to the Tone Curve, but it only adjusts grayscale images, whereas the Tone Curve is applicable to color images or each color channel.
There is also a “gimp:curves” filter, but there is no information about it. Which filter corresponds to the Tone Curve module in GIMP?
Because I try to use it from Python script. Gimp.Drawable.curve_spline() can apply tone curve to the image, but it changes pixel values destructively. I am looking for the way to apply tone curve non-destructively from Python script.
Thank you for the information. In my trial, it appears to be operating normally. I suppose that it may operate abnormally if the amount of input data is small.
Thanks for that test code. I think I might understand why we’re getting different results. You’re adjusting just the midtones (gamma), while I’m trying to generate a complete curve.
I think the problem of the issue reporter is that he tries to input 0-255 range integer data to curves_spline() method. I suppose that it can only accept now 0.0 - 1.0 range float data.
Yes! Thank you. I solved my issue by manually creating the curve I want, then opening the GimpCurvesConfig.settings file, copying the points numbers, pasting them into the code, and it works. You’ve made my day brighter.