exr image output

Discussion related to the LuxCore functionality, implementations and API.
bartek_zgo
Posts: 116
Joined: Mon Oct 26, 2020 11:42 am

Re: exr image output

Post by bartek_zgo »

Thanks CodeHD for you answer.
Does it mean that I only need to add TONEMAP_LINEAR to image pipeline and scale it with 0.39 factor?
CodeHD
Donor
Donor
Posts: 437
Joined: Tue Dec 11, 2018 12:38 pm
Location: Germany

Re: exr image output

Post by CodeHD »

No, the factor 0.39 was the ratio between the scale factors for different gamma, not the scale factor itself. At gamma 2.2, this evaluates to 2.465e-4.
User avatar
Dade
Developer
Developer
Posts: 5672
Joined: Mon Dec 04, 2017 8:36 pm
Location: Italy

Re: exr image output

Post by Dade »

CodeHD wrote: Wed Nov 25, 2020 12:09 pm If we compute the ratio of this factor for gamma 2.2 and 1.0 we get 0.39.
It is not a linear space. A fixed scale can not fix the problem but I assume it is exactly what you are trying to show.
Support LuxCoreRender project with salts and bounties
CodeHD
Donor
Donor
Posts: 437
Joined: Tue Dec 11, 2018 12:38 pm
Location: Germany

Re: exr image output

Post by CodeHD »

Dade wrote: Wed Nov 25, 2020 12:54 pm It is not a linear space. A fixed scale can not fix the problem but I assume it is exactly what you are trying to show.
Yes, the factor 0.39 is specific to the LUXLINEAR tonemapper when comparing between gamma 1.0 and 2.2.
bartek_zgo
Posts: 116
Joined: Mon Oct 26, 2020 11:42 am

Re: exr image output

Post by bartek_zgo »

Thanks a lot CodeHD. Your solution is exactly what I needed. Finally exr is identical to png
Capture3.PNG
I post the final pipeline code. Maybe someone will have the same problem

Code: Select all

film.imagepipelines.1.0.type = "NOP"
film.imagepipelines.1.1.type = "NOP"
film.imagepipelines.1.2.type = "TONEMAP_LUXLINEAR"
film.imagepipelines.1.2.sensitivity = "100"
film.imagepipelines.1.2.exposure = 0.1
film.imagepipelines.1.2.fstop = 22
film.imagepipelines.1.3.type = "GAMMA_CORRECTION"
film.imagepipelines.1.3.value = "2.2"
film.outputs.2.type = "RGB_IMAGEPIPELINE"
film.outputs.2.index = 1
film.outputs.2.filename = "c:\Bartek\stack\LuxCoreTests\exrGammaProblems\rgb_g22.png"

film.imagepipelines.3.0.type = "NOP"
film.imagepipelines.3.1.type = "NOP"
film.imagepipelines.3.2.type = "TONEMAP_LUXLINEAR"
film.imagepipelines.3.2.sensitivity = "100"
film.imagepipelines.3.2.exposure = 0.1
film.imagepipelines.3.2.fstop = 22
film.imagepipelines.3.3.type = "TONEMAP_LINEAR"
film.imagepipelines.3.3.scale = "0.39"
film.outputs.6.type = "RGB_IMAGEPIPELINE"
film.outputs.6.index = 3
film.outputs.6.filename = "c:\Bartek\stack\LuxCoreTests\exrGammaProblems\rgb_noGamma_tonemaper.exr"
Post Reply