Documentation ¶
Index ¶
Constants ¶
const ( // RangeMin is the LDR lower boundary. RangeMin = 0 // RangeMax is the LDR higher boundary. RangeMax = 65535 // max uint16 // LumSize defines the luminance range [0, LumSize] LumSize = RangeMax + 3 )
Variables ¶
var ( // ICamNormalizeLDRLuminance normalizes the LDR luminance (10% slower when activated). ICamNormalizeLDRLuminance = false )
var ( // LumPixFloor is the default lunMap maping for LinearInversePixelMapping func. LumPixFloor []float64 )
Functions ¶
func LinearInversePixelMapping ¶
LinearInversePixelMapping is an linear inverse pixel mapping. It is preference to have slightly more solid black 0 and solid white RangeMax in spectrum by stretching a mapping.
Types ¶
type CustomReinhard05 ¶
type CustomReinhard05 struct { HDRImage hdr.Image // Brightness is included in [-50, 50] with 1 increment step. Brightness float64 // Chromatic is included in [0, 1] with 0.01 increment step. Chromatic float64 // Light is included in [0, 1] with 0.01 increment step. Light float64 // contains filtered or unexported fields }
A CustomReinhard05 is a custom Reinhard05 TMO implementation. It looks like a JPEG photo taken with a smartphone. It provides a quick render with less RAM consumption than Reinhard05.
func NewCustomReinhard05 ¶
func NewCustomReinhard05(m hdr.Image, brightness, chromatic, light float64) *CustomReinhard05
NewCustomReinhard05 instanciates a new CustomReinhard05 TMO.
func NewDefaultCustomReinhard05 ¶
func NewDefaultCustomReinhard05(m hdr.Image) *CustomReinhard05
NewDefaultCustomReinhard05 instanciates a new CustomReinhard05 TMO with default parameters.
func (*CustomReinhard05) Perform ¶
func (t *CustomReinhard05) Perform() image.Image
Perform runs the TMO mapping.
type Drago03 ¶
type Drago03 struct { HDRImage hdr.Image // Bias is included in [0, 1] with 0.01 increment step. Bias float64 // contains filtered or unexported fields }
A Drago03 is an adaptive TMO implementation based on Frederic Drago's 2003 white paper.
Reference: http://resources.mpi-inf.mpg.de/tmo/logmap/
func NewDefaultDrago03 ¶
NewDefaultDrago03 instanciates a new Drago03 TMO with default parameters.
func NewDrago03 ¶
NewDrago03 instanciates a new Drago03 TMO.
type Durand ¶
type Durand struct { HDRImage hdr.Image Contrast float64 // contains filtered or unexported fields }
A Durand is a Fast Bilateral Filtering for the Display of High-Dynamic-Range Images.
Reference: Fredo Durand and Julie Dorsey in Proceedings of SIGGRAPH 2002
func NewDefaultDurand ¶
NewDefaultDurand instanciates a new Durand TMO with default parameters.
type ICam06 ¶
type ICam06 struct { HDRImage hdr.Image Contrast float64 MinClipping float64 MaxClipping float64 // contains filtered or unexported fields }
A ICam06 is a TMO implementation based on Mark D. Fairchild, Jiangtao Kuang and Garrett M. Johnson's 2006 white paper.
Reference: iCAM for high-dynamic-range image rendering. Mark D. Fairchild, Jiangtao Kuang and Garrett M. Johnson. In SIGGRAPH '06 ACM SIGGRAPH 2006 Research posters. Article No. 185 http://rit-mcsl.org/fairchild/PDFs/PAP26.pdf
func NewDefaultICam06 ¶
NewDefaultICam06 instanciates a new ICam06 TMO with default parameters.
type Logarithmic ¶
A Logarithmic is a naive TMO implementation.
func NewLogarithmic ¶
func NewLogarithmic(m hdr.Image) *Logarithmic
NewLogarithmic instanciates a new Logarithmic TMO.
func (*Logarithmic) Perform ¶
func (t *Logarithmic) Perform() image.Image
Perform runs the TMO mapping.
type Reinhard05 ¶
type Reinhard05 struct { HDRImage hdr.Image // Brightness is included in [-20, 20] with 0.1 increment step. Brightness float64 // Chromatic is included in [0, 1] with 0.01 increment step. Chromatic float64 // Light is included in [0, 1] with 0.01 increment step. Light float64 // contains filtered or unexported fields }
A Reinhard05 is a TMO implementation based on Erik Reinhard's 2005 white paper.
Reference: Dynamic Range Reduction Inspired by Photoreceptor Physiology. E. Reinhard and K. Devlin. In IEEE Transactions on Visualization and Computer Graphics, 2005.
func NewDefaultReinhard05 ¶
func NewDefaultReinhard05(m hdr.Image) *Reinhard05
NewDefaultReinhard05 instanciates a new Reinhard05 TMO with default parameters.
func NewReinhard05 ¶
func NewReinhard05(m hdr.Image, brightness, chromatic, light float64) *Reinhard05
NewReinhard05 instanciates a new Reinhard05 TMO.
func (*Reinhard05) Perform ¶
func (t *Reinhard05) Perform() image.Image
Perform runs the TMO mapping.
type ToneMappingOperator ¶
A ToneMappingOperator is an algorithm that converts hdr.Image to image.Image.
HDR is a high dynamic range (HDR) technique used in imaging and photography to reproduce a greater dynamic range of luminosity than is possible with standard digital imaging or photographic techniques. The aim is to present a similar range of luminance to that experienced through the human visual system. The human eye, through adaptation of the iris and other methods, adjusts constantly to adapt to a broad range of luminance present in the environment. The brain continuously interprets this information so that a viewer can see in a wide range of light conditions.