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

Teddy::Imports::LWEnvelope Class Reference

Parser for LightWave object file envelope subchunks. More...

#include <LWEnvelope.h>

Collaboration diagram for Teddy::Imports::LWEnvelope:

Collaboration graph
[legend]
List of all members.

Public Methods

 LWEnvelope (LWFile *f)
 LWEnvelope constructor. More...

void processEnvelope ()

Protected Methods

void readPreBehaviour_U2 ()
void readPostBehaviour_U2 ()
void readKeyframe_F4_F4 ()
void readInterpolation_ID4_d ()
void readChannel_S0_U2_d ()
void readName_S0 ()

Protected Attributes

std::string name
U2 pre_behaviour
U2 post_behaviour
list< LWEnvelopeKey * > keys
LWEnvelopeKeylast_key
LWFilef
ID4 envelope_type
U4 envelope_length

Detailed Description

Parser for LightWave object file envelope subchunks.

Warning:
Envelopes are not actually used at all yet.
Only for Lighwave files from version 6.0 and up

Definition at line 52 of file LWEnvelope.h.


Constructor & Destructor Documentation

Teddy::Imports::LWEnvelope::LWEnvelope LWFile   f
 

LWEnvelope constructor.

Definition at line 40 of file LWEnvelope.cpp.

References f, and last_key.


Member Function Documentation

void Teddy::Imports::LWEnvelope::processEnvelope  
 

Definition at line 46 of file LWEnvelope.cpp.

References envelope_length, envelope_type, f, ID_KEY, ID_NAME, ID_POST, ID_PRE, ID_SPAN, readChannel_S0_U2_d, readInterpolation_ID4_d, readKeyframe_F4_F4, readName_S0, readPostBehaviour_U2, and readPreBehaviour_U2.

void Teddy::Imports::LWEnvelope::readChannel_S0_U2_d   [protected]
 

Plug-in Channel Operators

CHAN { server-name[S0], flags[U2], data[...] }

Channel filters can be layered on top of a basic keyframed envelope to provide some more elaborate effects. Each channel chunk contains the name of the plug-in server and some flags bits. Only the first flag bit is defined, which if set indicates that the filter is disabled. The plug-in data follows as raw bytes.

Definition at line 128 of file LWEnvelope.cpp.

References f, and Teddy::Imports::U2.

Referenced by processEnvelope.

void Teddy::Imports::LWEnvelope::readInterpolation_ID4_d   [protected]
 

Interval Interpolation

SPAN { type[ID4], value[F4] * }

This sub-chunk defines the interpolation between the most recently specified KEY chunk and the keyframe immediately before it in time. The type ID code defines the interpolation algorithm and can be STEP, LINE, TCB, HERM or BEZI. The variable number of parameters values that follow define the particulars of the interpolation.

Definition at line 109 of file LWEnvelope.cpp.

References last_key.

Referenced by processEnvelope.

void Teddy::Imports::LWEnvelope::readKeyframe_F4_F4   [protected]
 

Definition at line 90 of file LWEnvelope.cpp.

References f, Teddy::Imports::F4, keys, and last_key.

Referenced by processEnvelope.

void Teddy::Imports::LWEnvelope::readName_S0   [protected]
 

Channel Name

NAME { channel-name[S0] }

This is an optional envelope sub-chunk which is not used by LightWave in any way. It is only provided to allow external programs to browse through the envelopes available in an object fille.

Definition at line 152 of file LWEnvelope.cpp.

References f, and name.

Referenced by processEnvelope.

void Teddy::Imports::LWEnvelope::readPostBehaviour_U2   [protected]
 

Post-Behavior

POST { type[U2] }

The post-behavior determines the signal value for times after the last key. The type codes are the same as for pre-behaviors.

Definition at line 85 of file LWEnvelope.cpp.

References f, and post_behaviour.

Referenced by processEnvelope.

void Teddy::Imports::LWEnvelope::readPreBehaviour_U2   [protected]
 

Pre-Behavior

PRE { type[U2] }

The pre-behavior for an envelope defines the signal value for times before the first key. The integer code selects one of several predefined behaviors, starting from zero: Reset, Constant, Repeat, Ocsillate, Offset Repeat, Linear.

Definition at line 72 of file LWEnvelope.cpp.

References f, and pre_behaviour.

Referenced by processEnvelope.


Member Data Documentation

U4 Teddy::Imports::LWEnvelope::envelope_length [protected]
 

Definition at line 74 of file LWEnvelope.h.

Referenced by processEnvelope.

ID4 Teddy::Imports::LWEnvelope::envelope_type [protected]
 

Definition at line 73 of file LWEnvelope.h.

Referenced by processEnvelope.

LWFile* Teddy::Imports::LWEnvelope::f [protected]
 

Definition at line 72 of file LWEnvelope.h.

Referenced by LWEnvelope, processEnvelope, readChannel_S0_U2_d, readKeyframe_F4_F4, readName_S0, readPostBehaviour_U2, and readPreBehaviour_U2.

list<LWEnvelopeKey*> Teddy::Imports::LWEnvelope::keys [protected]
 

Definition at line 69 of file LWEnvelope.h.

Referenced by readKeyframe_F4_F4.

LWEnvelopeKey* Teddy::Imports::LWEnvelope::last_key [protected]
 

Definition at line 70 of file LWEnvelope.h.

Referenced by LWEnvelope, readInterpolation_ID4_d, and readKeyframe_F4_F4.

std::string Teddy::Imports::LWEnvelope::name [protected]
 

Definition at line 66 of file LWEnvelope.h.

Referenced by readName_S0.

U2 Teddy::Imports::LWEnvelope::post_behaviour [protected]
 

Definition at line 68 of file LWEnvelope.h.

Referenced by readPostBehaviour_U2.

U2 Teddy::Imports::LWEnvelope::pre_behaviour [protected]
 

Definition at line 67 of file LWEnvelope.h.

Referenced by readPreBehaviour_U2.


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