Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

ShadeBlend Class Reference

A blend of Shade instances. More...

#include <ShadeBlend.h>

Inherits Shade.

Inheritance diagram for ShadeBlend:

Inheritance graph
[legend]
Collaboration diagram for ShadeBlend:

Collaboration graph
[legend]
List of all members.

Public Types

enum  Operation {
  NoOp, Add, Multiply, Layer,
  In, HeldOut, Atop, Xor
}
 Blend operation. More...


Public Methods

void blend (Operation o, RefShade &s)
Color4 calculateColor (const SurfaceInfo &s, Scene &scene)
void parseSymbol (Token &t, ObjectFile &file)
 Reads a single parameter sections inside the body of the object description. More...

void writeParams (ostream &stream)
 Writes all parameter sections inside the body of the object description. More...


Detailed Description

A blend of Shade instances.


Member Enumeration Documentation

enum ShadeBlend::Operation
 

Blend operation.

Given two RGBA colors and .

Enumeration values:
NoOp  No operation.
Add  .
Multiply  .
Layer  .
In  .
HeldOut  .
Atop  .
Xor  .


Member Function Documentation

void ShadeBlend::parseSymbol Token   t,
ObjectFile   file
[virtual]
 

Reads a single parameter sections inside the body of the object description.

Each object has a set of parameter names associated with it, called symbols. Symbols are declared inside the createSymbols method. The method parseSymbol expects the Token t to be such a symbol and reads the corresponding parameters. Unknown symbols are passed to its super class.

Parameters:
t  Token that is the current parameter symbol.
file  ObjectFile from which to read.
Precondition:
The file is opened for reading and is positioned just after the parameter name.
Postcondition:
The parameter section is read including the terminating semicolon (';').

Reimplemented from Shade.

void ShadeBlend::writeParams ostream &    stream [virtual]
 

Writes all parameter sections inside the body of the object description.

This method writes all object parameters to ostream. Inhereting classes will always call super::writeParams().

Parameters:
stream  ostream to which to write.
Precondition:
stream is opened for writing.
Postcondition:
All object parameters are written.

Reimplemented from DynamicObject.


The documentation for this class was generated from the following files:
This documentation was generated using doxygen. If you have any comments or additions please mail me.