This project has moved. For the latest updates, please go here.

Performing Mathematical Operations On An image

Jun 18, 2015 at 1:05 PM
Hi

I have a requirement to implement below logic written in IDL (Interactive Data Language) to Magick.Net. I think this can only be achieved by using the Fx method but I am not sure how to use the same. Can anyone please help?

Gamma=2.2
Factor=4.0
Filter=[-0.03,-0.03,0.03] ; blue colored filter
BLg=(BL/255.0)^gamma
BLgEnh=BLg0B
For ic=0,2 do BLgEnh[ic,,]= Factor
(BLg[2,,] + Filter[ic])
BLEnh=255* (BLgEnh < 1.0) ^ (1/gamma)

In the above algo, BL variable in the original sRGB image and the final output image desired is in variable BLEnh
Coordinator
Jun 19, 2015 at 11:20 PM
You could have continued the conversation in the other topic: https://magick.codeplex.com/discussions/639776. It is unclear to me what BLg0B does and I don't understand how BLgEnh can be both a number and an array. Could you please translate the code above to C#?