LightWrap++
AC++wrapperfortheLightWave3DSDK
lwpp Namespace Reference

contain Carbon specific code for the OSX XCode version platform_carbon.cpp lwpp More...

Namespaces

namespace  lw10
namespace  lwsdk10
namespace  LWSDK95_1

Classes

class  AboutPanel
class  AnimLoaderAdaptor
class  AnimLoaderHandler
class  AutoMutex
class  BackdropInfo
 Wrapper for LWBackdropInfo. More...
class  BaseFileRequest
 virtual base class for all file requesters More...
class  BaseMonitor
class  CameraAdaptor
class  CameraEvaluator
class  CameraHandler
class  CameraInfo
class  Channel
class  ChannelAdaptor
class  ChannelGroup
class  ChannelHandler
class  ColourManager
class  ColourPicker
class  comRingCommunicator
class  ContextMenu
class  ContextMenuCallback
 Base class for context menus. More...
class  ControlSizer
 a sizer containing a single PanelControl More...
class  CustomGlobal
class  CustomObjAccess
class  CustomObjAdaptor
 Wrapper for an CustomObjectHandler. More...
class  CustomObjHandler
 Base class for CustomObject plugins. More...
class  Directory
class  DirInfo
class  DisplacementAccess
class  DisplacementAdaptor
 Wrapper for an DisplacementHandler. More...
class  DisplacementHandler
 Base class for Displacement plugins. More...
class  doPop
 PopCount callback for LightWave. More...
class  DynamicContextMenu
class  DynamicSizer
class  DynaMonitor
class  EdgeScanner
class  Envelope
class  Envelopes
class  EnvironmentAdaptor
class  EnvironmentHandler
class  exception
class  ExtendedPopUp
class  FastEdgeScanner
class  FastPointScanner
class  FastPolyScanner
class  File
class  FileName
 Manages file names that are content directory aware. More...
class  FileRequest2
class  FileType
class  FrameBufferAdaptor
class  FrameBufferHandler
class  genericGlobal
class  GizmoAdaptor
 Wrapper for Gizmos. More...
class  GizmoDrawAdaptor
 Wrapper for Gizmos that only perform drawing. More...
class  GizmoDrawHandler
 Base class for Gizmos that only perform drawing. More...
class  GizmoHandler
 Base class for Gizmos. More...
class  GlobalBase
 Template class base for any kind of global that will be AQUIREd/RELEASEd,. More...
class  GlobalMemory
class  HorizontalSizer
 A sizer with components lined up horizontally. More...
class  Image
class  ImageFilterAdaptor
 Wrapper for an ImageFilterHandler. More...
class  ImageFilterHandler
 Class for Imagefilters. More...
class  ImageLoaderAdaptor
class  ImageLoaderHandler
class  ImageLoaderProtocol
 Pushes an image to LW using the LWImageProtocol. Only useful for image loaders or animation loaders. More...
class  ImageSaverAdaptor
class  ImageSaverHandler
class  ImageUtil
class  InstanceAdaptor
 Wrapper for InstanceHandler. More...
class  InstanceHandler
 Base class for (almost) any LW plugin. More...
class  InstanceUpdate
class  InterfaceAdaptor
 Wrapper for InterfaceHandler. More...
class  InterfaceHandler
 Base class for a Lightwave UI. More...
class  InterfaceInfo
class  ItemAdaptor
 Wrapper for ItemHandler. More...
class  ItemHandler
 LW ItemFuncs class extension. More...
class  ItemInfo
class  ItemMotionAdaptor
class  ItemMotionHandler
class  LayoutGenericAdaptor
class  LayoutGenericHandler
class  LayoutGenericLWPanelHandler
class  LayoutGenericXPanelHandler
class  LayoutNonModalGenericAdaptor
class  LayoutToolAdaptor
 Wrapper for a Layout Tool. More...
class  LayoutToolHandler
 Base class for Layout Tool plugins. More...
class  LightAdaptor
 Wrapper for an LightHandler. More...
class  LightHandler
 Class for Lights. More...
class  LightWave
 Wrap functions related to the LightWave system. More...
class  LimboComRing
 Simple helper class for the limbo state. More...
class  LoadState
 Wrapper for a LW save state. More...
class  LogPanel
class  LWDrawFuncs
class  LWDynaValue
 Dynamic Values. More...
struct  LWImageProtocol_V2
struct  LWImageProtocol_V3
class  LWItem
class  LWItemCallback
 Provide callback functions for LW Items in XPanels... More...
class  LWItemTracker
 This class tracks the IDs of LW items, especially related to the LWItemFuncs callbacks. More...
class  LWMessage
 Wrapped LWMessageFuncs. More...
class  LWMTUtil
class  LWMTUtil9
class  LWMTUtil_Pre9
class  LWNode
class  LWNodeInput
 Node Input. More...
class  LWNodeOutput
class  LWNodeUtility
class  LWPanel
class  LWPanelAdaptor
class  LWPanelCallbacks
class  LWPanelCameraAdaptor
class  LWPanelCameraHandler
class  LWPanelChannelAdaptor
class  LWPanelChannelHandler
class  LWPanelControlCallBacks
class  LWPanelCustomObjAdaptor
class  LWPanelCustomObjHandler
class  LWPanelDisplacementAdaptor
class  LWPanelDisplacementHandler
class  LWPanelEnvironmentAdaptor
class  LWPanelEnvironmentHandler
class  LWPanelImageFilterAdaptor
class  LWPanelImageFilterHandler
class  LWPanelInterface
class  LWPanelItemMotionAdaptor
class  LWPanelItemMotionHandler
class  LWPanelListCallBacks
class  LWPanelMasterAdaptor
class  LWPanelMasterHandler
class  LWPanelMultiListControlCallBacks
 Callbacks for multi-line list boxes. More...
class  LWPanelPixelFilterAdaptor
class  LWPanelPixelFilterHandler
class  LWPanelTreeControlCallBacks
class  LWPanelVolumetricAdaptor
 Adaptor class for LWPanelVolumetricHandler. More...
class  LWPanelVolumetricHandler
 Class for Volumetric Handler with an LWPanels. More...
class  LWRaster
class  LWServer
class  LWSurface
class  ManagedPanel
class  MasterAdaptor
 Wrapper for an MasterHandler. More...
class  MasterHandler
class  Matrix4x4
class  MeshEditOperator
class  MeshInfo
class  MeshPointScan
 Base Class for Point Scanners. More...
class  MeshPolygonScan
 Base Class for Polygon Scanners. More...
class  MissingGlobal
class  ModelerCommand
class  ModelerCommandAdaptor
class  ModelerState
class  Monitor
 Wrapped LWLMonFuncs. More...
class  MTUtilBase
class  Nameable
 Base class for items that can be named. Will store the name locally in a copy. More...
class  nGlobalBase
class  NodeAdaptor
class  NodeEditor
class  NodeHandler
class  NodeInputHelper
class  ObjectInfo
class  OSFileRequest
 OS specific file requester. More...
class  PanelControl
class  PanelControlAdaptor
 Class to adapt callbacks for Panel controls on a LW Panel. More...
class  PanelTreeNode
class  ParticleServices
class  PixelFilterAdaptor
class  PixelFilterHandler
class  Point3
class  PointScanner
class  PolyScanner
class  PopCmdCallback
class  PopUpCallback
 Base class for PopUpCallbacks. More...
class  PresetCollection
class  PresetEntry
class  PresetHandler
class  Preview
class  PreviewCallbacks
class  Qualifier
 Used to extract information from an input qualifier. More...
class  Reference
class  ReferenceCounted
class  RenderAdaptor
 Wrapper for RenderHandler. More...
class  RenderHandler
class  RootNode
class  SaveState
 Wrapper for a LW save state. More...
class  SceneInfo
 Provides information about the currently loaded scene. More...
class  SceneObjectReference
 Provide callback functions for LW Items in XPanels... More...
class  SceneObjects
class  ServerInfo
class  ServerInfo10
class  ShaderAdaptor
 Wrapper for an ImageFilterHandler. More...
class  ShaderHandler
 Class for Shaders. More...
class  ShadingEvaluator
 A base clasee for shaders that evaluate depending on light samples. More...
class  ShutdownHandler
class  SimpleContextMenu
class  SimpleMonitor
class  SimplePreset
class  Sizer
 Virtual base class for all Sizers. More...
struct  st_lwcolorspacefuncs
class  StartupHandler
class  Stat
 Wrapper to extract stats from a file. More...
class  Storeable
class  StyledItemCallback
 Provide callback functions for LW Items in XPanels... More...
class  SurfaceReference
 Provide callback functions for LW Items in XPanels... More...
class  Texture
 A Texture is a set of TextureLayer that drive a parameter. More...
class  TextureAdaptor
 Wrapper for an ImageFilterHandler. More...
class  TextureEditor
class  TextureHandler
 Class for Procedural Textures. More...
class  TextureLayer
class  Thread
class  ThreadGroup
class  ThreadUtils
class  TimeInfo
class  Timer
 Adds timer based events to LightWave. More...
struct  to_lower
class  TransientGlobalBase
 Template class base for any TRANSIENT global. More...
class  Vector3
class  VerticalSizer
 A sizer with components lined up vertically. More...
class  VMapCallbacks
class  VolumetricAccess
class  VolumetricAdaptor
 Wrapper for an VolumetricHandler. More...
class  VolumetricHandler
 Class for Volumetric plugins. More...
class  VParm
 The Variant Parameter Class Wrapper. More...
class  XPanel
 Wrapper for a LWXPanel. More...
class  XPanelAdaptor
class  XPanelCameraAdaptor
class  XPanelCameraHandler
class  XPanelChannelAdaptor
class  XPanelChannelHandler
class  XPanelCustomObjAdaptor
class  XPanelCustomObjHandler
class  XPanelDisplacementAdaptor
class  XPanelDisplacementHandler
class  XPanelEnvironmentAdaptor
class  XPanelEnvironmentHandler
class  XPanelFuncs
 Wrapper for LWXPanelFuncs. More...
class  XPanelImageFilterAdaptor
class  XPanelImageFilterHandler
class  XPanelInterface
 Base class for all plugins that use an XPanels user interface. More...
class  XPanelItemMotionAdaptor
class  XPanelItemMotionHandler
class  XPanelLightAdaptor
class  XPanelLightHandler
class  XPanelMasterAdaptor
class  XPanelMasterHandler
class  XPanelNodeAdaptor
class  XPanelNodeHandler
class  XPanelPixelFilterAdaptor
class  XPanelPixelFilterHandler
class  XPanelShaderAdaptor
class  XPanelShaderHandler
class  XPanelTextureAdaptor
class  XPanelTextureHandler
class  XPanelView
 Base for classes that can handle XPanel view data. More...
class  XPanelVolumetricAdaptor
class  XPanelVolumetricHandler
class  XPDrawArea

Typedefs

typedef std::auto_ptr
< LWNodeInput
auto_NodeInput
 Helper declaration for node member variables.
typedef std::auto_ptr
< LWNodeOutput
auto_NodeOutput
 Helper declaration for node member variables.
typedef std::auto_ptr< VParmauto_VParm
typedef std::set< int > BufferSet
typedef HandlerList::iterator HandlerIterator
typedef std::vector
< SimpleHandler * > 
HandlerList
typedef struct
lwpp::st_lwcolorspacefuncs 
LWColorSpaceFuncs
typedef void LWPixelConversionAlphaFunc (struct st_lwimagelookup *, float *, float *)
typedef void LWPixelConversionRGBFunc (struct st_lwimagelookup *, float *, float *)
typedef Matrix4x4< double > Matrix4x4d
typedef Matrix4x4< float > Matrix4x4f
typedef pathList::const_iterator pathCIterator
typedef pathList::iterator pathIterator
typedef std::deque< std::string > pathList
typedef PluginList::iterator PluginIterator
typedef std::vector< ServerRecord > PluginList
typedef Point3< double > Point3d
typedef Point3< float > Point3f
typedef void SimpleHandler ()
typedef Vector3< double > Vector3d
typedef Vector3< float > Vector3f

Enumerations

enum  { ID_PSEL = 0x0800, ID_TYPE, ID_TEST }
enum  { LW10PFF_MULTITHREADED = 1<<0, LW10PFF_EVERYPIXEL = 1<<1, LW10PFF_BEFOREVOLUME = 1<<2, LW10PFF_RAYTRACE = 1<<3 }
enum  LWColorSpaceType {
  lwcst_viewer = 0, lwcst_surface_color, lwcst_light_color, lwcst_palette_files,
  lwcst_8bit_files, lwcst_float_files, lwcst_alpha_files, lwcst_output,
  lwcst_output_alpha, lwcst_sizeof
}
enum  LWColourSpace {
  lwcs_linear = 0, lwcs_sRGB, lwcs_rec709, lwcs_cineon,
  lwcs_ciexyz, lwcs_sizeof
}
enum  LWColourSpaceConversion { lwcsc_colorspaceToLinear = 0, lwcsc_linearToColorspace, lwcsc_sizeof }
enum  LWColourSpaceLayer { lwcsl_RGB = 0, lwcsl_Alpha, lwcsl_sizeof }
enum  MutexID {
  MUTEX0 = 0, MUTEX1, MUTEX2, MUTEX3,
  MUTEX4, MUTEX5, MUTEX6, MUTEX7,
  MUTEX8, MUTEX9
}
 Mutex ids. Use these since LW only provides us with 10 mutexes. More...
enum  SizerFlags { STRETCH_HORIZONTAL = 1 << 0, STRETCH_VERTICAL = 1 << 1 }

Functions

template<class Type >
int Ceil (const Type x)
template<class Type >
Type Clamp (const Type value, const Type min, const Type max)
 Clamp a value between min and max.
bool cmpNoCase (const std::string &s1, const std::string &s2)
 Case independant string comparison.
template<typename T >
void CoordinateSystem (const Vector3< T > &v1, Vector3< T > *v2, Vector3< T > *v3)
 Create a coordinate system out of one vector.
template<typename T >
void CoordinateSystem (const Vector3< T > &view, const Vector3< T > &normal, Vector3< T > *right, Vector3< T > *forward)
 Create a coordinate system out of two vectors, one being the normal, the other the viewing ray.
template<typename T >
Vector3< T > Cross (Vector3< T > a, Vector3< T > b)
 Cross product of two Vector3.
template<class Type >
Type Degrees (const Type rad)
 Radians to degree conversion.
int Double2Int (double val)
 Fast double to integer conversion.
template<class Type >
int Floor (const Type x)
template<typename T >
T * getEventHandler (PanelControl &control)
 Helper function for callbacks.
LWFrame GetFrame ()
std::string getTempPath ()
 returns the current temp path, including a trailing separator
LWTime GetTime ()
template<class T >
T * getTransGlobal (const char *globalName)
Matrix4x4d getWorld2Screen (LWItem cid, LWTime time)
Matrix4x4d getWorld2Screen (LWItemID id, LWTime time)
 Generate a world to screen transformation matrix.
Matrix4x4d getWorld2Screen (LWTime time)
 Return the world to Screen transformation matrix for the current camera at the time specified.
int IlluminationSampler (void *data, LWItemID light, const LWDVector dir, const LWDVector color)
 Creates a callback to sample illumination.
 IMPLEMENT_GLOBAL (LWColorSpaceFuncs, LWPP_COLORSPACEFUNCS_GLOBAL)
template<class Type >
bool inRange (const Type x, const Type min, const Type max)
 return true if the value is within the range, including the bounds
bool isDirectory (const std::string name)
bool isDoubleClick (unsigned int milliseconds)
 Check if the time in milliseconds is short enough to be registered as a double click.
template<class T >
Lerp (const double f, const T a, const T b)
template<class Type >
Type log2 (const Type a)
template<typename T >
void LWXPanelBtnClickFunc (LWXPanelID panel, int cid)
std::string makeAbsoluteName (pathList basePath, const std::string relFileName)
std::string makeAbsoluteName (const std::string basePath, const std::string relFileName)
void makeAllDirectories (const char *path)
std::string makeFullFileName (const pathList &path, const std::string &file, const std::string &ext)
std::string makeFullPath (const pathList &path)
std::string makeRelativeName (pathList basePath, const std::string absFileName)
std::string makeRelativeName (const std::string basePath, const std::string absFileName)
 Return the file name in relation to base.
template<class Type >
Type Max (Type a, Type b)
 Maximum.
template<class Type >
Type Max (const Type v[3])
template<class Type >
Type Min (const Type a, const Type b)
 Minimum.
template<class Type >
Type Min (const Type v[3])
template<class Type >
int Mod (const Type a, const Type b)
bool nocase_compare (const char c1, const char c2)
template<class Type >
Type Normalize (const Type x, const Type min, const Type max)
void OpenURL (const std::string urlString)
 Open a URL in the default application, usually a browser.
int Pow2 (const int n)
template<class Type >
Type Radians (const Type deg)
 Degrees to radians conversion.
template<class Type >
Type Range (const Type x, const Type min, const Type max)
void RegisterImageChangeComRing ()
template<class Type >
int Round (const double r)
int Round2Int (double val)
 Fast rounding of a double to an integer.
int SendCommand (const char *cmdname, const char *fmt,...)
 Send a Command to layout during any context.
int SendCommand (const std::string cmd)
void SetSuperGlobal (GlobalFunc *g)
 Set Superglobal.
template<class T >
SignOf (const T a)
template<class Type >
Type SmoothStep (const Type value, const Type min, const Type max)
template<class Type >
Type SmoothStep (const Type value)
pathList splitFullPath (std::string sourcePath, std::string &fileName, std::string &ext)
pathList splitPath (std::string sourcePath)
template<class Type >
Type Sqr (const Type a)
 Minimum.
std::string stripExtension (const char *source)
template<class T >
void Swap (T &a, T &b)
std::string & toCapitalize (std::string &str)
 Capitalizes a string so the first character and every character after a space is in upper case.
std::string & toLowercase (std::string &str)
 convert a string in-place to lower case
std::string trim (const std::string &s, const char *ws)
void trimTrail (std::string &path)
void UnregisterImageChangeComRing ()
bool World2Screen (lwpp::Point3d pt, double scoord[2], lwpp::Matrix4x4d &CameraTransform, double frameAspect)
 Transformation from world to screen coordinates.
bool World2Screen (lwpp::Vector3d dir, double scoord[2], lwpp::Matrix4x4d &CameraTransform, double frameAspect)
 Transformation from world to screen coordinates.
bool World2Screen (lwpp::Point3d pt, double scoord[2], LWItemID camID, LWTime time, double pixelAspect)
 Transformation from world to screen coordinates.
bool World2Screen (lwpp::Point3d pt, double scoord[2], LWTime time)
 Transformation from world to screen coordinates.
void xyztohp (const double x, const double y, const double z, double &h, double &p)
double xztoh (const double x, const double z)

Variables

const char * fSeps = "\\/"
const char inFuncs [] = "NodeInputFuncs"
const char inFuncs2 [] = "NodeInputFuncs 2"
 LWPP_CUSTOMOBJECT_VERSION
 LWPP_DISPLACEMENT_VERSION
 LWPP_IMAGEFILTER_VERSION
 LWPP_LIGHT_VERSION
 LWPP_NODE_VERSION
 LWPP_PIXELFILTER_VERSION
 LWPP_SHADER_VERSION
 LWPP_TEXTURE_VERSION
 max
 min
GlobalFunc * SuperGlobal = 0
 Initialize and store superglobal GlobalFunc.

Detailed Description

contain Carbon specific code for the OSX XCode version platform_carbon.cpp lwpp

LightWrap++ related classes and functions.

contain Cocoa specific code for the OSX XCode version platform_cocoa.cpp lwpp

contain Carbon specific code for the OSX XCode version platform_cfm.cpp lwpp

Created by Michael Wolf on 7/5/09. Copyright 2009 db&w Bornemann und Wolf GbR. All rights reserved.

Contains all platform specific code for windows

LightWrap++ is fully contained within the lwpp namespace.


Typedef Documentation

typedef std::auto_ptr<LWNodeInput> lwpp::auto_NodeInput

Helper declaration for node member variables.

typedef std::auto_ptr<LWNodeOutput> lwpp::auto_NodeOutput

Helper declaration for node member variables.

typedef std::auto_ptr<VParm> lwpp::auto_VParm
typedef std::set<int> lwpp::BufferSet
typedef HandlerList::iterator lwpp::HandlerIterator
typedef std::vector<SimpleHandler *> lwpp::HandlerList

Color space functions.

Color spaces file references are save in the scene file if they are used, in the viewer, color space file defaults or in a LWO from the image viewer.

typedef void lwpp::LWPixelConversionAlphaFunc(struct st_lwimagelookup *, float *, float *)

Conversion function prototype.

typedef void lwpp::LWPixelConversionRGBFunc(struct st_lwimagelookup *, float *, float *)

struct st_lwimagelookup *

Is a forward reference to the internal lw instance structure ( defined internally ). This is used instead of a void * pointer. Conversion function prototype.

typedef Matrix4x4<double> lwpp::Matrix4x4d
typedef Matrix4x4<float> lwpp::Matrix4x4f
typedef pathList::const_iterator lwpp::pathCIterator
typedef pathList::iterator lwpp::pathIterator
typedef std::deque<std::string> lwpp::pathList
typedef PluginList::iterator lwpp::PluginIterator
typedef std::vector<ServerRecord> lwpp::PluginList
typedef Point3<double> lwpp::Point3d
typedef Point3<float> lwpp::Point3f
typedef void lwpp::SimpleHandler()
typedef Vector3< double > lwpp::Vector3d
typedef Vector3< float > lwpp::Vector3f

Enumeration Type Documentation

anonymous enum
Enumerator:
ID_PSEL 
ID_TYPE 
ID_TEST 
anonymous enum
Enumerator:
LW10PFF_MULTITHREADED 
LW10PFF_EVERYPIXEL 
LW10PFF_BEFOREVOLUME 
LW10PFF_RAYTRACE 
Enumerator:
lwcst_viewer 

Viewer color space.

lwcst_surface_color 

Surface color space.

lwcst_light_color 
lwcst_palette_files 

Palette files color space.

lwcst_8bit_files 

8 bit files color space.

lwcst_float_files 

Float files color space.

lwcst_alpha_files 

Alpha files color space.

lwcst_output 

Output files color space.

lwcst_output_alpha 

Alpha files color space.

lwcst_sizeof 
Enumerator:
lwcs_linear 

LightWave linear color space.

lwcs_sRGB 

Standard RGB color space.

lwcs_rec709 

Recommendation BT.709, HDTV.

lwcs_cineon 

Eastman Kodak Co.

lwcs_ciexyz 

CIE XYZ.

lwcs_sizeof 
Enumerator:
lwcsc_colorspaceToLinear 

Convert from non-linear to linear.

lwcsc_linearToColorspace 

Convert from linear to non-linear.

lwcsc_sizeof 
Enumerator:
lwcsl_RGB 

RGB Channel.

lwcsl_Alpha 

Alpha Channel.

lwcsl_sizeof 

Mutex ids. Use these since LW only provides us with 10 mutexes.

Enumerator:
MUTEX0 
MUTEX1 
MUTEX2 
MUTEX3 
MUTEX4 
MUTEX5 
MUTEX6 
MUTEX7 
MUTEX8 
MUTEX9 
Enumerator:
STRETCH_HORIZONTAL 
STRETCH_VERTICAL 

Function Documentation

template<class Type >
int lwpp::Ceil ( const Type  x)
template<class Type >
Type lwpp::Clamp ( const Type  value,
const Type  min,
const Type  max 
)

Clamp a value between min and max.

bool lwpp::cmpNoCase ( const std::string &  s1,
const std::string &  s2 
)
inline

Case independant string comparison.

template<typename T >
void lwpp::CoordinateSystem ( const Vector3< T > &  v1,
Vector3< T > *  v2,
Vector3< T > *  v3 
)
inline

Create a coordinate system out of one vector.

template<typename T >
void lwpp::CoordinateSystem ( const Vector3< T > &  view,
const Vector3< T > &  normal,
Vector3< T > *  right,
Vector3< T > *  forward 
)
inline

Create a coordinate system out of two vectors, one being the normal, the other the viewing ray.

template<typename T >
Vector3<T> lwpp::Cross ( Vector3< T >  a,
Vector3< T >  b 
)
inline

Cross product of two Vector3.

Parameters:
afirst Vector3
bsecond Vector3
Returns:
the cross product
template<class Type >
Type lwpp::Degrees ( const Type  rad)

Radians to degree conversion.

int lwpp::Double2Int ( double  val)
inline

Fast double to integer conversion.

template<class Type >
int lwpp::Floor ( const Type  x)
template<typename T >
T* lwpp::getEventHandler ( PanelControl &  control)

Helper function for callbacks.

LWFrame lwpp::GetFrame ( )
inline
std::string lwpp::getTempPath ( )

returns the current temp path, including a trailing separator

LWTime lwpp::GetTime ( )
inline
template<class T >
T* lwpp::getTransGlobal ( const char *  globalName)
Matrix4x4d lwpp::getWorld2Screen ( LWItem  cid,
LWTime  time 
)
Matrix4x4d lwpp::getWorld2Screen ( LWItemID  id,
LWTime  time 
)

Generate a world to screen transformation matrix.

Parameters:
[in]idLWItem of the camera
[in]timeThe time at which to generate the matrix
Returns:
A 4x4 transformation matrix
Matrix4x4d lwpp::getWorld2Screen ( LWTime  time)

Return the world to Screen transformation matrix for the current camera at the time specified.

int lwpp::IlluminationSampler ( void *  data,
LWItemID  light,
const LWDVector  dir,
const LWDVector  color 
)

Creates a callback to sample illumination.

Create a shading class derived from ShadingEvaluator Use the sampler:

ShadingEvaluator shading; // if needed set variables needed by the evaluator
na->illuminateSample(lightid, na->wPos, dir, IlluminationSampler, &shading);
lwpp::IMPLEMENT_GLOBAL ( LWColorSpaceFuncs  ,
LWPP_COLORSPACEFUNCS_GLOBAL   
)
template<class Type >
bool lwpp::inRange ( const Type  x,
const Type  min,
const Type  max 
)

return true if the value is within the range, including the bounds

bool lwpp::isDirectory ( const std::string  name)
bool lwpp::isDoubleClick ( unsigned int  milliseconds)

Check if the time in milliseconds is short enough to be registered as a double click.

template<class T >
T lwpp::Lerp ( const double  f,
const T  a,
const T  b 
)
template<class Type >
Type lwpp::log2 ( const Type  a)
template<typename T >
void lwpp::LWXPanelBtnClickFunc ( LWXPanelID  panel,
int  cid 
)
std::string lwpp::makeAbsoluteName ( pathList  basePath,
const std::string  relFileName 
)
std::string lwpp::makeAbsoluteName ( const std::string  basePath,
const std::string  relFileName 
)
void lwpp::makeAllDirectories ( const char *  path)
std::string lwpp::makeFullFileName ( const pathList &  path,
const std::string &  file,
const std::string &  ext 
)
std::string lwpp::makeFullPath ( const pathList &  path)
std::string lwpp::makeRelativeName ( pathList  basePath,
const std::string  absFileName 
)
std::string lwpp::makeRelativeName ( const std::string  basePath,
const std::string  absFileName 
)

Return the file name in relation to base.

template<class Type >
Type lwpp::Max ( Type  a,
Type  b 
)

Maximum.

template<class Type >
Type lwpp::Max ( const Type  v[3])
template<class Type >
Type lwpp::Min ( const Type  a,
const Type  b 
)

Minimum.

template<class Type >
Type lwpp::Min ( const Type  v[3])
template<class Type >
int lwpp::Mod ( const Type  a,
const Type  b 
)
bool lwpp::nocase_compare ( const char  c1,
const char  c2 
)
inline
template<class Type >
Type lwpp::Normalize ( const Type  x,
const Type  min,
const Type  max 
)
void lwpp::OpenURL ( const std::string  urlString)

Open a URL in the default application, usually a browser.

int lwpp::Pow2 ( const int  n)
inline
template<class Type >
Type lwpp::Radians ( const Type  deg)

Degrees to radians conversion.

template<class Type >
Type lwpp::Range ( const Type  x,
const Type  min,
const Type  max 
)
void lwpp::RegisterImageChangeComRing ( )
template<class Type >
int lwpp::Round ( const double  r)
int lwpp::Round2Int ( double  val)
inline

Fast rounding of a double to an integer.

int lwpp::SendCommand ( const char *  cmdname,
const char *  fmt,
  ... 
)
inline

Send a Command to layout during any context.

Warning:
This is based on an undocumented global and may fail
int lwpp::SendCommand ( const std::string  cmd)
inline
void lwpp::SetSuperGlobal ( GlobalFunc *  g)

Set Superglobal.

Initialize the SuperGlobal, this is just to keep it clean

template<class T >
T lwpp::SignOf ( const T  a)
template<class Type >
Type lwpp::SmoothStep ( const Type  value,
const Type  min,
const Type  max 
)
template<class Type >
Type lwpp::SmoothStep ( const Type  value)
pathList lwpp::splitFullPath ( std::string  sourcePath,
std::string &  fileName,
std::string &  ext 
)
pathList lwpp::splitPath ( std::string  sourcePath)
template<class Type >
Type lwpp::Sqr ( const Type  a)

Minimum.

std::string lwpp::stripExtension ( const char *  source)
template<class T >
void lwpp::Swap ( T &  a,
T &  b 
)
std::string& lwpp::toCapitalize ( std::string &  str)
inline

Capitalizes a string so the first character and every character after a space is in upper case.

std::string& lwpp::toLowercase ( std::string &  str)
inline

convert a string in-place to lower case

std::string lwpp::trim ( const std::string &  s,
const char *  ws 
)
void lwpp::trimTrail ( std::string &  path)
void lwpp::UnregisterImageChangeComRing ( )
bool lwpp::World2Screen ( lwpp::Point3d  pt,
double  scoord[2],
lwpp::Matrix4x4d CameraTransform,
double  frameAspect 
)

Transformation from world to screen coordinates.

bool lwpp::World2Screen ( lwpp::Vector3d  dir,
double  scoord[2],
lwpp::Matrix4x4d CameraTransform,
double  frameAspect 
)

Transformation from world to screen coordinates.

bool lwpp::World2Screen ( lwpp::Point3d  pt,
double  scoord[2],
LWItemID  camID,
LWTime  time,
double  pixelAspect 
)

Transformation from world to screen coordinates.

requires SceneInfo

Parameters:
[in]ptPoint in world coordinates
[out]scoordscreen coordinates in fractional pixels
[in]camIDID of the camera
[in]timeLWTime
[in]pixelAspectThe pixel aspect of the camera
Returns:
true if successfull, false if called from within Modeler
bool lwpp::World2Screen ( lwpp::Point3d  pt,
double  scoord[2],
LWTime  time 
)

Transformation from world to screen coordinates.

requires SceneInfo

Parameters:
[in]ptPoint in world coordinates
[out]scoordscreen coordinates ind fractional pixels
[in]timeLWTime
Returns:
true if successfull, false if called from within Modeler
void lwpp::xyztohp ( const double  x,
const double  y,
const double  z,
double &  h,
double &  p 
)
inline

Support function for doing spherical mapping

double lwpp::xztoh ( const double  x,
const double  z 
)
inline

Support function for doing cylindrical mapping

Todo:
insert atan2(x,y) function

Variable Documentation

const char * lwpp::fSeps = "\\/"
const char lwpp::inFuncs = "NodeInputFuncs"
const char lwpp::inFuncs2 = "NodeInputFuncs 2"
lwpp::LWPP_CUSTOMOBJECT_VERSION
lwpp::LWPP_DISPLACEMENT_VERSION
lwpp::LWPP_IMAGEFILTER_VERSION
lwpp::LWPP_LIGHT_VERSION
lwpp::LWPP_NODE_VERSION
lwpp::LWPP_PIXELFILTER_VERSION
lwpp::LWPP_SHADER_VERSION
lwpp::LWPP_TEXTURE_VERSION
lwpp::max
lwpp::min
GlobalFunc * lwpp::SuperGlobal = 0

Initialize and store superglobal GlobalFunc.

Superglobal storage for GlobalFunc.

This is shared by all plugins within the DLL, and should be initialized as soon as possible