dng_1d_concatenate Class Reference

A dng_1d_function that represents the composition (curry) of two other dng_1d_functions. More...

#include <dng_1d_function.h>

Inheritance diagram for dng_1d_concatenate:

dng_1d_function

List of all members.


Public Member Functions

 dng_1d_concatenate (const dng_1d_function &function1, const dng_1d_function &function2)
virtual bool IsIdentity () const
 Only true if both function1 and function2 have IsIdentity equal to true.
virtual real64 Evaluate (real64 x) const
virtual real64 EvaluateInverse (real64 y) const

Protected Attributes

const dng_1d_functionfFunction1
const dng_1d_functionfFunction2

Detailed Description

A dng_1d_function that represents the composition (curry) of two other dng_1d_functions.

Constructor & Destructor Documentation

dng_1d_concatenate::dng_1d_concatenate ( const dng_1d_function function1,
const dng_1d_function function2 
)

Create a dng_1d_function which computes y = function2.Evaluate(function1.Evaluate(x)). Compose function1 and function2 to compute y = function2.Evaluate(function1.Evaluate(x)). The range of function1.Evaluate must be a subset of 0.0 to 1.0 inclusive, otherwise the result of function1(x) will be pinned (clipped) to 0.0 if <0.0 and to 1.0 if > 1.0 .

Parameters:
function1 Inner function of composition.
function2 Outer function of composition.


Member Function Documentation

real64 dng_1d_concatenate::Evaluate ( real64  x  )  const [virtual]

Return the composed mapping for value x.

Parameters:
x A value between 0.0 and 1.0 (inclusive).
Return values:
function2.Evaluate(function1.Evaluate(x)). 

Implements dng_1d_function.

References dng_1d_function::Evaluate().

real64 dng_1d_concatenate::EvaluateInverse ( real64  y  )  const [virtual]

Return the reverse mapped value for y. Be careful using this method with compositions where the inner function does not have a range 0.0 to 1.0 . (Or better yet, do not use such functions.)

Parameters:
y A value to reverse map. Should be within the range of function2.Evaluate.
Return values:
A value x such that function2.Evaluate(function1.Evaluate(x)) == y (to very close approximation).

Reimplemented from dng_1d_function.

References dng_1d_function::EvaluateInverse().


The documentation for this class was generated from the following files:

Copyright © 2006-2009 Adobe Systems Incorporated.

Use of this website signifies your agreement to the Terms of Use and Online Privacy Policy.

Search powered by Google